Opened 9 years ago
Closed 9 years ago
#48403 closed defect (fixed)
clang-3.7 asan_iossim dylib fails to build with Xcode 4.x due to sim SDK predating x86_64 support
Reported by: | h.rayflood@… | Owned by: | jeremyhu (Jeremy Huddleston Sequoia) |
---|---|---|---|
Priority: | Normal | Milestone: | |
Component: | ports | Version: | 2.3.3 |
Keywords: | haspatch | Cc: | |
Port: | clang-3.7 |
Description (last modified by ryandesign (Ryan Carsten Schmidt))
Thank you for landing my patch #47729
I tried to build r241984, and I got following error on mountain lion using xcode-4.x.
:info:build COMPILE: clang_darwin/asan_iossim_dynamic/x86_64: /s/macports_build/osx-10.8_xcode-4.4/_opt_llvm-mp_var_macports_sources_rsync.macports.org_release_tarballs_ports_lang_llvm-3.7/clang-3.7/work/trunk/projects/compiler-rt/lib/sanitizer_common/sanitizer_mac.cc :info:build /s/macports_build/osx-10.8_xcode-4.4/_opt_llvm-mp_var_macports_sources_rsync.macports.org_release_tarballs_ports_lang_llvm-3.7/clang-3.7/work/build/Release+Debug+Asserts/bin/clang -std=c++11 -fno-exceptions -fPIC -funwind-tables -I/s/macports_build/osx-10.8_xcode-4.4/_opt_llvm-mp_var_macports_sources_rsync.macports.org_release_tarballs_ports_lang_llvm-3.7/clang-3.7/work/trunk/projects/compiler-rt/lib -I/s/macports_build/osx-10.8_xcode-4.4/_opt_llvm-mp_var_macports_sources_rsync.macports.org_release_tarballs_ports_lang_llvm-3.7/clang-3.7/work/trunk/projects/compiler-rt/include -arch x86_64 -fvisibility=hidden -DVISIBILITY_HIDDEN -Wall -Werror -O3 -fomit-frame-pointer -mios-simulator-version-min=7.0 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.1.sdk -fno-builtin -gline-tables-only -stdlib=libc++ -DMAC_INTERPOSE_FUNCTIONS=1 -DASAN_DYNAMIC=1 -c -o /s/macports_build/osx-10.8_xcode-4.4/_opt_llvm-mp_var_macports_sources_rsync.macports.org_release_tarballs_ports_lang_llvm-3.7/clang-3.7/work/build/tools/clang/runtime/compiler-rt/clang_darwin/asan_iossim_dynamic/x86_64/SubDir.lib__sanitizer_common/sanitizer_mac.o /s/macports_build/osx-10.8_xcode-4.4/_opt_llvm-mp_var_macports_sources_rsync.macports.org_release_tarballs_ports_lang_llvm-3.7/clang-3.7/work/trunk/projects/compiler-rt/lib/sanitizer_common/sanitizer_mac.cc :info:build In file included from /s/macports_build/osx-10.8_xcode-4.4/_opt_llvm-mp_var_macports_sources_rsync.macports.org_release_tarballs_ports_lang_llvm-3.7/clang-3.7/work/trunk/projects/compiler-rt/lib/sanitizer_common/sanitizer_mac.cc:43: :info:build In file included from /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.1.sdk/usr/include/mach/mach.h:67: :info:build In file included from /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.1.sdk/usr/include/mach/mach_interface.h:49: :info:build /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.1.sdk/usr/include/mach/task.h:31:10: fatal error: 'mach/x86_64/task.h' file not found :info:build #include <mach/x86_64/task.h> :info:build ^ :info:build 1 error generated. :info:build make[4]: *** [/s/macports_build/osx-10.8_xcode-4.4/_opt_llvm-mp_var_macports_sources_rsync.macports.org_release_tarballs_ports_lang_llvm-3.7/clang-3.7/work/build/tools/clang/runtime/compiler-rt/clang_darwin/asan_iossim_dynamic/x86_64/SubDir.lib__sanitizer_common/sanitizer_mac.o] Error 1 :info:build make[4]: *** Waiting for unfinished jobs.... :info:build make[4]: Leaving directory `/s/macports_build/osx-10.8_xcode-4.4/_opt_llvm-mp_var_macports_sources_rsync.macports.org_release_tarballs_ports_lang_llvm-3.7/clang-3.7/work/trunk/projects/compiler-rt' :info:build make[3]: *** [BuildRuntimeLibraries] Error 2
Attachments (4)
Change History (11)
Changed 9 years ago by h.rayflood@…
Attachment: | osx-10.8_xcode-4.4_main.log.gz added |
---|
Changed 9 years ago by h.rayflood@…
Attachment: | osx-10.8_xcode-4.5_main.log.gz added |
---|
Changed 9 years ago by h.rayflood@…
Attachment: | osx-10.8_xcode-4.6_main.log.gz added |
---|
comment:1 Changed 9 years ago by h.rayflood@…
Changed 9 years ago by h.rayflood@…
Attachment: | clang-3.7-mtlion-xcode4.diff added |
---|
comment:2 Changed 9 years ago by ryandesign (Ryan Carsten Schmidt)
Cc: | jeremyhu@… removed |
---|---|
Description: | modified (diff) |
Owner: | changed from macports-tickets@… to jeremyhu@… |
comment:3 Changed 9 years ago by jeremyhu (Jeremy Huddleston Sequoia)
I know it's dependent on xcodeversion, but I decided to be *MORE* restrictive since I didn't want people with Xcode 4.2 on SL to use it, so I just did "<= SL" instead of "< Xcode 4"
The issue you're hitting is different than the earlier issue.
comment:4 Changed 9 years ago by jeremyhu (Jeremy Huddleston Sequoia)
The issue here is that your iOS Simulator SDK doesn't support x86_64 (because we added support for x86_64 in iOS 7).
The real thing we want to check is if your iOS Simulator SDK supportx x86_64 and if not, restrict the iossim asan dylib to i386.
comment:5 Changed 9 years ago by jeremyhu (Jeremy Huddleston Sequoia)
Summary: | clang-3.7 3.7-r241984: build failed fatal error: 'mach/x86_64/task.h' file not found when xcode-4.x on mountain lion → clang-3.7 asan_iossim dylib fails to build with Xcode 4.x due to sim SDK predating x86_64 support |
---|
comment:6 Changed 9 years ago by jeremyhu (Jeremy Huddleston Sequoia)
The provided patch doesn't really fix the problem in the build system. It just disables support for earlier SDKs, but I don't really care about supporting asan on such old configs anyways. If someone on ML wants it, they should update to the supported toolchain instead of sticking on Xcode 4.x, so I'll commit it.
comment:7 Changed 9 years ago by jeremyhu (Jeremy Huddleston Sequoia)
Resolution: | → fixed |
---|---|
Status: | new → closed |
If someone wants to actually fix the bug, please reopen with a patch.
xcode-4.x don't have <mach/x86_64/task.h>. but iossim is targeting to x86_64.
so we should avoid to build iossim when xcode-4.x on mountain lion.
in r138590:
this probrem depends on xcodeversion, not os.major.