Oh, wait -- I must correct myself.

As part of the LibcxxOnOlderSystems instructions, you can (must) build cctools 
against newer llvm headers, but forcing the build with clang-3.4:

cctools @895_7+llvm39+universal-llvm34 (active) platform='darwin 10' 
archs='i386 x86_64' date='2018-08-19T19:49:33-0700'


Best,

Ken


On 2018-09-02, at 7:55 AM, Ken Cunningham wrote:

> > usr/bin/gcc-4.2 -Os -std=gnu99 -Os -DLTO_SUPPORT -g -I../../include -Wall 
> > -D_MACH_I386_THREAD_STATUS_FPSTATE_LEGACY_FIELD_NAMES_ 
> > -D_ARCHITECTURE_I386_FPU_FPSTATE_LEGACY_FIELD_NAMES_ -I/opt/local/include 
> > -I/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_devel_cctools/cctools/work/cctools-895/../ld64-274.1/src/abstraction
> >  
> > -I/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_devel_cctools/cctools/work/cctools-895/../ld64-274.1/src/other
> >  
> > -I/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_devel_cctools/cctools/work/cctools-895/include
> >  -arch x86_64 -arch i386 -I/opt/local/libexec/llvm-3.9/include -pipe -Os 
> > -fPIC -Wall -W -Wno-unused-parameter -Wwrite-strings 
> > -Wmissing-field-initializers -pedantic -Wno-long-long 
> > -Wcovered-switch-default -Wdelete-non-virtual-dtor -Werror=date-time 
> > -DNDEBUG -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS 
> > -D__STDC_LIMIT_MACROS   -c -o ./allocate.o ../allocate.c
> 
> 
> I just rebuilt cctools on a vanilla 10.6.8 VM, and it built fine.
> 
> Your build error occurred because you're trying to force a build against the 
> llvm-3.9 headers with the ancient gcc-4.2, and it just can't. 
> 
> gcc-4.2 can build against the llvm-3.4 headers (as it is set up to do by 
> default), but I don't know if it can build against any other headers. My 
> guess is no, but only Jeremy might have tried others.
> 
> If you really want to build cctools against the llvm-3.9 headers on 10.6.8 
> (not sure why, but just sayin'), you can do that if you force a newer 
> compiler like clang-3.9.
> 
> You would type something like this:
> 
> sudo port -v install cctools +llvm39 configure.compiler=macports-clang-3.9
> 
> Note - you would probably then be the only person on Earth with this 
> configuration of cctools on 10.6.8. Who knows what kind of problems you might 
> run into that nobody could figure out?
> 
> Best,
> 
> Ken

Reply via email to