Adjust env for bindgen compilation.#916
Merged
illicitonion merged 5 commits intobazelbuild:mainfrom Aug 31, 2021
Merged
Conversation
| } | ||
| cc_toolchain, feature_configuration = find_cc_toolchain(ctx) | ||
| _, _, linker_env = get_linker_and_args(ctx, ctx.attr, cc_toolchain, feature_configuration, None) | ||
| env.update(**linker_env) |
Collaborator
There was a problem hiding this comment.
Does this need any special handling in the case of clashes with things we explicitly set? e.g. should we be prepending/appending to the LD_LIBRARY_PATH rather than overwriting it?
Contributor
Author
There was a problem hiding this comment.
There's that issue, and whether the the system include directories from the cc_toolchain should be added. I'm inclined to leave it as I've written it, and adjust if people have problems with it, since this patch is clearly a step forward.
Collaborator
There was a problem hiding this comment.
Yeah, sounds reasonable - let's see how we go!
Collaborator
|
Can you push a rebase/merge-main, and I'll merge to main? :) |
Contributor
Author
|
We should have the user in #899 contribute their test repo as an example, to get some coverage on this. |
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.
This fixes #899 by putting
XCODE_VERSION_OVERRIDE,APPLE_SDK_VERSION_OVERRIDE,APPLE_SDK_PLATFORMin the env.