Skip to content

Fix HDRS_LIST building when paths in header inclusion tree include spaces - #3607

Merged
zcbenz merged 1 commit into
ml-explore:mainfrom
lancelotblanchard:main
Jun 2, 2026
Merged

zcbenz merged 1 commit into
ml-explore:mainfrom
lancelotblanchard:main

Conversation

@lancelotblanchard

Copy link
Copy Markdown
Contributor

Proposed changes

In mlx/backend/metal/make_compiled_preamble.sh, doing declare -a HDRS_LIST=($HDRS) breaks when the header inclusion tree $HDRS has paths with spaces. This manifests by headers not being properly linked, and a bunch of grep errors during build. This PR fixes header inclusion to support paths with spaces.

Checklist

Put an x in the boxes that apply.

  • I have read the CONTRIBUTING document
  • I have run pre-commit run --all-files to format my code / installed pre-commit prior to committing changes
  • I have added tests that prove my fix is effective or that my feature works
  • I have updated the necessary documentation (if needed)

@zcbenz zcbenz left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me, thanks!

@zcbenz
zcbenz merged commit e9e20fa into ml-explore:main Jun 2, 2026
16 checks passed
@BrewTestBot BrewTestBot mentioned this pull request Jul 7, 2026
1 task done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants