Skip to content

When adding conditionally included compiler flags, dont use the CFLAGS section #483

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

Merged
merged 1 commit into from
May 16, 2019

Conversation

spevans
Copy link
Contributor

@spevans spevans commented May 16, 2019

  • cmake/modules/SwiftSupport.cmake prepends each flag with '-Xcc' but
    if the flag evaluates to empty then an extra -Xcc is added to the
    compiler options.

  • Explicitly add the option with a conditional '-Xcc' before it as well.

  • This fixes the "warning: argument unused during compilation: '-Xcc'"
    seen in the error logs.

…S section.

- cmake/modules/SwiftSupport.cmake prepends each flag with '-Xcc' but
  if the flag evaluates to empty then an extra -Xcc is added to the
  compiler options.

- Explicitly add the option with a conditional '-Xcc' before it as well.

- This fixes the "warning: argument unused during compilation: '-Xcc'"
  seen in the error logs.
@spevans
Copy link
Contributor Author

spevans commented May 16, 2019

@compnerd I cant actually test this on windows, does it look correct to you?

@spevans
Copy link
Contributor Author

spevans commented May 16, 2019

@swift-ci test

@compnerd
Copy link
Member

Yeah, this seems reasonable - though its all going to go away soon.

@compnerd
Copy link
Member

CC: @ktopley-apple

@ktopley-apple ktopley-apple merged commit 251dba4 into swiftlang:master May 16, 2019
rokhinip pushed a commit that referenced this pull request Nov 5, 2021
When adding conditionally included compiler flags, dont use the CFLAGS section

Signed-off-by: Kim Topley <ktopley@apple.com>
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.

3 participants