Repository navigation
ARM64 (aarch64) Linux host support - #10
Merged
Merged
Conversation
The custom command that bakes the build-mig wrapper script invoked
plain 'chmod 0755 ...' as a build COMMAND. CMake resolves bare command
names against existing targets and adds an implicit strong dependency
when one matches — and the Darling tree _does_ build a Darwin-targeted
'chmod' Mach-O executable from src/external/file_cmds/chmod. The
resulting graph closes a cycle:
migexe (UTILITY)
→ chmod (Mach-O EXECUTABLE; links libsystem_c, libsystem_kernel, ...)
→ system_kernel (SHARED_LIBRARY)
→ libsyscall_64 / libsyscall (OBJECT)
→ libsyscall_generate_mig_headers (UTILITY)
→ migexe
which CMake reports as 'Cyclic dependencies are allowed only among
static libraries' and refuses to regenerate.
Fix: invoke the host-side chmod via CMake's own builtin
'${CMAKE_COMMAND} -E chmod' (3.19+), which is parsed as a literal
program path, not as a target name. The added comment block in
bootstrap_cmds/CMakeLists.txt explains the trap so we don't regress.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Part of the ARM64 (aarch64) Linux host port, darlinghq/darling#1818. Please merge this before #1818, using a merge commit so the SHA that #1818's gitlink points at stays valid.
Commits
Testing
Built and smoke-tested as part of #1818 on an aarch64 host (Debian 13, clang 19, 48-bit VA). x86_64 has not been re-tested yet. The ARM-specific changes are meant to sit behind
__aarch64__/__arm64__guards, but this still needs an x86_64 build.Provenance
🤖 Generated with Claude Code