[llvm-bugs] [Bug 24864] New: compiler-rt config-ix.cmake missing link flag for iOS simulator
via llvm-bugs
llvm-bugs at lists.llvm.org
Thu Sep 17 11:08:59 PDT 2015
https://llvm.org/bugs/show_bug.cgi?id=24864
Bug ID: 24864
Summary: compiler-rt config-ix.cmake missing link flag for iOS
simulator
Product: Build scripts
Version: trunk
Hardware: Macintosh
OS: MacOS X
Status: NEW
Severity: normal
Priority: P
Component: cmake
Assignee: unassignedbugs at nondot.org
Reporter: aw1621107 at gmail.com
CC: llvm-bugs at lists.llvm.org
Classification: Unclassified
On OS X 10.11, Xcode/CLT 7.1, trunk build through homebrew using "brew install
llvm --with-clang --with-lldb --HEAD --debug --verbose" and this formula:
https://gist.github.com/aw1621107/dccde531d91349d3eaee
During this build, ld refuses to link libclang_rt.asan_iossim_dynamic.dylib
when compiling the address sanitizer. Instead of looking in the iOS simulator
SDK, it goes straight to /usr/lib, resulting in the build failing with the
message "building for iOS simulator, but linking against dylib built for OS X
(architecture x86_64)"
Turns out that setting -sysroot during the link step did not seem to set the
sysroot for the ld call. I fixed this issue by adding a ld-specific sysroot
flag to projects/compiler-rt/cmake/config-ix.cmake under line 343:
-Wl,-syslibroot ${IOSSIM_SDK_DIR}
While this works on my machine, I'm not 100% sure that this will work for
everyone, as the build fails at a later point with a different error message.
In addition, it appears that this problem does not affect every OS X machine,
as some users on IRC were able to build trunk just fine.
If more information is required, I'll be happy to provide it.
--
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20150917/4b652e4d/attachment.html>
More information about the llvm-bugs
mailing list