Skip to content

native libc detection: respect spaces in CC env var - #9043

Merged
andrewrk merged 1 commit into
masterfrom
cc-env-var-tokenization
Jun 9, 2021
Merged

andrewrk merged 1 commit into
masterfrom
cc-env-var-tokenization

Conversation

@andrewrk

@andrewrk andrewrk commented Jun 8, 2021

Copy link
Copy Markdown
Member

Zig has detection for when it is accidentally being called recursively
when trying to find the native libc installation. However it was not
working, resulting in a cryptic failure, because zig tried to execute
a command which had spaces in it rather than tokenizing it.

This improves the user experience of zig cc for systems that Zig
does not support cross-compiling for.

Closes #8960

Zig has detection for when it is accidentally being called recursively
when trying to find the native libc installation. However it was not
working, resulting in a cryptic failure, because zig tried to execute
a command which had spaces in it rather than tokenizing it.

This improves the user experience of `zig cc` for systems that Zig
does not support cross-compiling for.

Closes #8960
@andrewrk

andrewrk commented Jun 8, 2021

Copy link
Copy Markdown
Member Author

cc @lun-4 this solves 1 of the issues from ziglang/zig-bootstrap#60

@andrewrk
andrewrk merged commit d128ec3 into master Jun 9, 2021
@andrewrk
andrewrk deleted the cc-env-var-tokenization branch June 9, 2021 21:27
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.

when CC environment variable is set to zig and zig cannot provide libc, error: unable to create compilation: UnableToSpawnCCompiler

1 participant