Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add fake dependency roots for all transitive proc-macros #2749

Merged
merged 1 commit into from
Aug 1, 2024

Conversation

illicitonion
Copy link
Collaborator

@illicitonion illicitonion commented Jul 18, 2024

See the extensive comment for details, but tl;dr: when cross-compiling,
just doing top-level resolves of direct dependencies can miss resolving
platform-specific features for proc-macros which are only used on
certain platforms.

@illicitonion illicitonion changed the title Add proc macro example to cross-compiling example Add fake dependency roots for all transitive proc-macros Jul 30, 2024
@illicitonion illicitonion force-pushed the musl-proc-macros branch 5 times, most recently from 73da7e3 to 0acf6a4 Compare July 30, 2024 15:43
@illicitonion illicitonion marked this pull request as draft July 31, 2024 10:38
@illicitonion illicitonion force-pushed the musl-proc-macros branch 3 times, most recently from 4f2de2c to b1ae794 Compare August 1, 2024 13:58
@illicitonion illicitonion marked this pull request as ready for review August 1, 2024 13:59
@illicitonion illicitonion force-pushed the musl-proc-macros branch 3 times, most recently from ff901d3 to 066dc8a Compare August 1, 2024 15:11
See the extensive comment for details, but tl;dr: when cross-compiling,
just doing top-level resolves of direct dependencies can miss resolving
platform-specific features for proc-macros which are only used on
certain platforms.

Also, reliably pass require options to cargo metadata

We should always pass -Zbindeps if nightly.

All callers should also pass a manifest path and a working directory -
ensure they are set.
Copy link
Collaborator

@UebelAndre UebelAndre left a comment

Choose a reason for hiding this comment

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

Nice! Thank you!

@illicitonion illicitonion added this pull request to the merge queue Aug 1, 2024
Merged via the queue into bazelbuild:main with commit 3b65db8 Aug 1, 2024
3 checks passed
@illicitonion illicitonion deleted the musl-proc-macros branch August 2, 2024 12:33
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