Project

General

Profile

Actions

Bug #2804

closed

On OSX clang <6.1.0 segfaults when compiling with precompiled headers and boost 1.58

Added by Alex Afanasyev over 9 years ago. Updated over 9 years ago.

Status:
Closed
Priority:
Normal
Category:
Build
Target version:
Start date:
Due date:
% Done:

100%

Estimated time:

Description

(originally reported by Vince Lehman: http://www.lists.cs.ucla.edu/pipermail/nfd-dev/2015-May/001065.html)

Example of the problem here: http://jenkins.named-data.net/job/NLSR/label=OSX-10.9-64bit/538/console:

Waf: Entering directory `/private/tmp/ndn-cxx/build'
[  2/119] Compiling src/common-pch.hpp
[ 29/119] Compiling tools/ndnsec/main.cpp
Stack dump:
0.  Program arguments: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang -cc1 -triple x86_64-apple-macosx10.9.0 -emit-obj -disable-free -disable-llvm-verifier -main-file-name main.cpp -mrelocation-model pic -pic-level 2 -mdisable-fp-elim -masm-verbose -munwind-tables -target-cpu core2 -target-linker-version 241.9 -gdwarf-2 -coverage-file /private/tmp/ndn-cxx/build/tools/ndnsec/main.cpp.4.o -resource-dir /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/../lib/clang/6.0 -include-pch /private/tmp/ndn-cxx/build/ndn-cxx.2.pch -D NDEBUG -I /private/tmp/ndn-cxx/build/tools/ndnsec -I /private/tmp/ndn-cxx/tools/ndnsec -I /private/tmp/ndn-cxx/build/src -I /private/tmp/ndn-cxx/src -I /usr/local/include -stdlib=libc++ -O2 -Wall -Wno-error=unneeded-internal-declaration -Wno-error=deprecated-register -pedantic -std=c++11 -fdeprecated-macro -fdebug-compilation-dir /private/tmp/ndn-cxx/build -ferror-limit 19 -fmessage-length 0 -stack-protector 1 -mstackrealign -fblocks -fobjc-runtime=macosx-10.9.0 -fencode-extended-block-signature -fcxx-exceptions -fexceptions -fdiagnostics-show-option -vectorize-loops -vectorize-slp -o /private/tmp/ndn-cxx/build/tools/ndnsec/main.cpp.4.o -x c++ ../tools/ndnsec/main.cpp 
1.  <eof> parser at end of file
2.  /usr/local/include/boost/date_time/date_parsing.hpp:104:5: instantiating function definition 'parse_date'
3.  /usr/local/include/boost/lexical_cast.hpp:37:19: instantiating function definition 'lexical_cast'
4.  /usr/local/include/boost/lexical_cast/try_lexical_convert.hpp:139:21: instantiating function definition 'try_lexical_convert'
5.  /usr/local/include/boost/lexical_cast/detail/converter_lexical.hpp:472:32: instantiating function definition 'try_convert'
clang: error: unable to execute command: Segmentation fault: 11
clang: error: clang frontend command failed due to signal (use -v to see invocation)
Apple LLVM version 6.0 (clang-600.0.54) (based on LLVM 3.5svn)
Target: x86_64-apple-darwin13.3.0
Thread model: posix
clang: note: diagnostic msg: PLEASE submit a bug report to http://developer.apple.com/bugreporter/ and include the crash backtrace, preprocessed source, and associated run script.
clang: note: diagnostic msg: 
********************

PLEASE ATTACH THE FOLLOWING FILES TO THE BUG REPORT:
Preprocessed source(s) and associated run script(s) are located at:
clang: note: diagnostic msg: /var/folders/dn/40ynwmgj3kvfpdtwhv5jlhc80000gn/T/main-23e6db.cpp
clang: note: diagnostic msg: /var/folders/dn/40ynwmgj3kvfpdtwhv5jlhc80000gn/T/main-23e6db.sh
clang: note: diagnostic msg: 

********************

After upgrading clang on OSX 10.10 to the latest version (6.1.0), the issue seem to disappear. Upgrade on earlier versions of OSX didn't solve the problem (the latest version available for OSX 10.9 is 6.0/clang-600.0.57).


As a temporary resolution, I will disable precompiled headers on OS X platform with clang that is older than 6.1.0

Actions #1

Updated by Alex Afanasyev over 9 years ago

  • Description updated (diff)
Actions #2

Updated by Alex Afanasyev over 9 years ago

  • Status changed from In Progress to Code review
Actions #3

Updated by Alex Afanasyev over 9 years ago

  • Status changed from Code review to Closed
  • % Done changed from 0 to 100
Actions

Also available in: Atom PDF