Skip to content

Make CMake builds independent of checkout name - #22292

Draft
rascani wants to merge 1 commit into
pytorch:mainfrom
rascani:codex/worktree-cmake
Draft

Make CMake builds independent of checkout name#22292
rascani wants to merge 1 commit into
pytorch:mainfrom
rascani:codex/worktree-cmake

Conversation

@rascani

@rascani rascani commented Aug 28, 2026

Copy link
Copy Markdown
Contributor

Summary

Remove the requirement that the repository directory itself be named executorch. Generate a checkout-local include root in the build tree, route build-time include paths through it, and retain the public executorch/... include namespace and installed layout.

Review this commit by starting with tools/cmake/Utils.cmake and the top-level CMakeLists.txt, then checking the standalone backend and example entrypoints, and finally test/test_worktree_build.sh.

Authored with assistance from Codex.

Fixes #6475

cc @digantdesai @freddan80 @per @zingo @oscarandersson8218 @mansnils @Sebastian-Larsson @robell

@pytorch-bot

pytorch-bot Bot commented Aug 28, 2026

Copy link
Copy Markdown

🔗 Helpful Links

🧪 See artifacts and rendered test results at hud.pytorch.org/pr/pytorch/executorch/22292

Note: Links to docs will display an error until the docs builds have been completed.

❌ 1 New Failure, 2 Cancelled Jobs, 1 Unrelated Failure, 7 Unclassified Failures

As of commit 7a690f8 with merge base 80f7005 (image):

NEW FAILURE - The following job has failed:

UNCLASSIFIED FAILURES - DrCI could not classify the following jobs because the workflow did not run on the merge base. The failures may be pre-existing on trunk or introduced by this PR:

  • Build macOS Wheels / pytorch/executorch / build-wheel-py3_10-cpu (gh) (this job did not run on the merge base, so DrCI cannot tell whether the failure is pre-existing)
  • Build macOS Wheels / pytorch/executorch / upload / upload-wheel-py3_10-cpu (gh) (this job did not run on the merge base, so DrCI cannot tell whether the failure is pre-existing)
    Unable to download artifact(s): Artifact not found
  • MLX / test-mlx / test-mlx (gh) (this job did not run on the merge base, so DrCI cannot tell whether the failure is pre-existing)
    AssertionError: Slot for getitem already set to Slot(id_type=<IdType.Tensor: 1>, id_space=<IdSpace.Output: 3>, idx=0), trying to set to Slot(id_type=<IdType.Tensor: 1>, id_space=<IdSpace.Input: 2>, idx=3)
  • MLX / test-mlx-dflash / test-mlx-dflash (gh) (this job did not run on the merge base, so DrCI cannot tell whether the failure is pre-existing)
    AssertionError: Slot for getitem already set to Slot(id_type=<IdType.Tensor: 1>, id_space=<IdSpace.Output: 3>, idx=0), trying to set to Slot(id_type=<IdType.Tensor: 1>, id_space=<IdSpace.Input: 2>, idx=2)
  • MLX / test-mlx-qwen35-moe / test-mlx-qwen35-moe (gh) (this job did not run on the merge base, so DrCI cannot tell whether the failure is pre-existing)
    AssertionError: Slot for getitem_8 already set to Slot(id_type=<IdType.Tensor: 1>, id_space=<IdSpace.Output: 3>, idx=2), trying to set to Slot(id_type=<IdType.Tensor: 1>, id_space=<IdSpace.Input: 2>, idx=4)
  • MLX / test-mlx-stories110m / test-mlx-stories110m (gh) (this job did not run on the merge base, so DrCI cannot tell whether the failure is pre-existing)
    AssertionError: Slot for getitem already set to Slot(id_type=<IdType.Tensor: 1>, id_space=<IdSpace.Output: 3>, idx=0), trying to set to Slot(id_type=<IdType.Tensor: 1>, id_space=<IdSpace.Input: 2>, idx=2)
  • trunk / test-llama-runner-mac (fp32, coreml) / macos-job (gh) (this job did not run on the merge base, so DrCI cannot tell whether the failure is pre-existing)
    AttributeError: 'BackendConfig' object has no attribute 'mps'

CANCELLED JOBS - The following jobs were cancelled. Please retry:

FLAKY - The following job failed but was likely due to flakiness present on trunk:

This comment was automatically generated by Dr. CI and updates every 15 minutes.

@meta-cla meta-cla Bot added the CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. label Aug 28, 2026
@github-actions github-actions Bot added ciflow/trunk module: arm Issues related to arm backend labels Aug 28, 2026
@github-actions

Copy link
Copy Markdown

This PR needs a release notes: label

If your change should be included in the release notes (i.e. would users of this library care about this change?), please use a label starting with release notes:. This helps us keep track and include your important work in the next release notes.

To add a label, you can comment to pytorchbot, for example
@pytorchbot label "release notes: none"

For more information, see
https://github.com/pytorch/pytorch/wiki/PyTorch-AutoLabel-Bot#why-categorize-for-release-notes-and-how-does-it-work.

Remove the requirement that the repository directory itself be named
executorch. Generate a checkout-local include root in the build tree,
route build-time include paths through it, and retain the public
executorch/... include namespace and installed layout.

Review this commit by starting with tools/cmake/Utils.cmake and the
top-level CMakeLists.txt, then checking the standalone backend and
example entrypoints, and finally test/test_worktree_build.sh.

Authored with assistance from Codex.
@rascani
rascani force-pushed the codex/worktree-cmake branch from 15e3323 to 7a690f8 Compare August 29, 2026 00:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ciflow/trunk CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. module: arm Issues related to arm backend

Projects

None yet

Development

Successfully merging this pull request may close these issues.

C++ includes require that the repo lives in a directory named exactly executorch

1 participant