-
Notifications
You must be signed in to change notification settings - Fork 10.2k
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 build fails on FreeBSD with "undefined symbol: ceilf" #2190
Comments
cc @ngie-eign |
I should mention that this is FreeBSD 13.0-CURRENT amd64 with clang 8.0.0 |
|
Hmmm... the cmake build does link properly and it includes libm (however, cmake doesn't do this directly AFAICT):
Digging through the headers in /usr/include, it looks like @asomers: what libstdc++ are you linking with? Could you please run ldd on it to list its dependent libraries? |
Hmmm... bazelbuild/bazel@a89c7ef looks like an interesting feature to test. Could you please try running bazel like CC: @PiotrSikora. |
I actually don't even have a libstdc++ installed. It's surprising that I don't get an even worse link error. Perhaps clang internally translates -lstdc++ to -lc++ ? And using your |
What would be a correct fix for this? Linker flags for cc_binary targets within bazel's own source tree specify: "//src/conditions:freebsd": ["-lm"],
"//src/conditions:openbsd": ["-lm"], which I believe should fix this problem unless you have a better suggestion. |
Found the problem I think. Bazel is using |
The latest master fails to build on FreeBSD because bazel doesn't use
-lm
when building googletest-printers-test.cc:The text was updated successfully, but these errors were encountered: