-
Notifications
You must be signed in to change notification settings - Fork 4.1k
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
Bazel should pass -no_warning_for_no_symbols
to libtool when using XCode toolchain
#5981
Comments
Makes sense, we should fix this. |
This involves updating the script that generates bazel/tools/osx/crosstool/CROSSTOOL.tpl - I've filed an internal bug for it. |
For future reference - internal bug is b/113576433 |
Any progress on this? Since #6478 merged, this is the one remaining source of needless spam in the output on Mac. |
Sorry, this fell through the cracks. I will try to fix. |
…sx CROSSTOOL. Reduces useless warning spam on osx, as reported in #5981. RELNOTES: None PiperOrigin-RevId: 229586053
Fixed by 81b59f0. |
…sx CROSSTOOL. Reduces useless warning spam on osx, as reported in bazelbuild#5981. RELNOTES: None PiperOrigin-RevId: 229586053
Looks like some of these are still sneaking through. Posted more in the (still open) #4057 (comment) |
can you file a new issue with a repro? should be an easy fix |
On it! Thanks, Keith. Amazed at your breadth |
(You're sure you don't want it in the other issue, still open and applicable?) |
either way |
I think this issue has reappeared now that C++ builds on macOS use the Unix toolchain by default (Bazel 7). I guess Bazel should pass the necessary flags for the Unix toolchain as well, at least if the macOS binaries (and not GNU ones installed via e.g. Homebrew) are used for compiling. |
Description of the problem / feature request:
I have a (proprietary) project that contains some C++ source code files which, on certain platforms, emit no symbols due to
#ifdef
s. When I build on macOS,bazel build
prints useless warnings like:Feature requests: what underlying problem are you trying to solve with this feature?
I'd like bazel to pass flags to suppress this useless warning.
Bugs: what's the simplest, easiest way to reproduce this bug? Please provide a minimal example if possible.
You can easily reproduce with a
cc_library
rule with empty .c file; I've uploaded a minimal test case here: https://gist.github.com/nelhage-stripe/df1374361be6daa938e6ec75f93daf7aWhat operating system are you running Bazel on?
macOS
What's the output of
bazel info release
?Any other information, logs, or outputs that you want to share?
I believe passing
no_warning_for_no_symbols
tolibtool
(which is$AR
on the xcode toolchain, as I understand it) will suppress this warning.The text was updated successfully, but these errors were encountered: