Question

I am migrating from a Snow Leopard (10.6.8) MAC to a Lion MAC (10.7.5). I haven't changed anything in the code or the build scripts, but once I try to build my project using SCONS on OSX Lion, I get the following errors:

gcc -arch i386 -o build/osx/objs/installer/Controller.o -c -isysroot /Developer/SDKs/MacOSX10.5.sdk -mmacosx-version-min=10.5 -x objective-c++ -Oz -m32 -Wall -fno-common -fvisibility=hidden -fno-strict-aliasing -Wall -fno-common -fvisibility=hidden -DMACOSX_DEPLOYMENT_TARGET=10.5 -g -DOS_OSX=1 -D_OS_NAME=osx -D_PRODUCT_VERSION=1.1.0 -D_PRODUCT_NAME=Aspen -D_GLOBAL_NS_VARNAME=Aspen -D_CONFIG_FILENAME=Aspen.config -D_BOOT_RUNTIME_FLAG= -D_BOOT_HOME_FLAG= -D_DISTRIBUTION_URL=smithmicro.com -D_CRASH_REPORT_URL=smithmicro.com/p/v1/app-crash-report -DOS_32=1 -DDEBUG=1 -I. -Ikroll -Ibuild/osx/sdk/include -Ikroll/libkroll -Ikroll/libkroll/utils installer/osx/Controller.mm
In file included from kroll/libkroll/utils/../base.h:10,
                 from kroll/libkroll/utils/utils.h:8,
                 from installer/osx/Controller.h:8,
                 from installer/osx/Controller.mm:6:
/Developer/SDKs/MacOSX10.5.sdk/usr/include/c++/4.2.1/string:44:28: error: bits/c++config.h: No such file or directory

I have the 10.5 sdk here: /Developer/SDKs/MacOSX10.5.sdk. When I compare the 10.5 SDK on my Snow Leopard to Lion MAC, they look they the same.

Any help would be greatly appreciated. Thanks in advance.


EDIT

After turning on verbose information I can see this on the 10.7 machine for include paths:

 /usr/llvm-gcc-4.2/bin/../lib/gcc/i686-apple-darwin11/4.2.1/include
 /Developer/SDKs/MacOSX10.5.sdk/usr/include/c++/4.2.1
 /Developer/SDKs/MacOSX10.5.sdk/usr/include/c++/4.2.1/backward
 /Developer/SDKs/MacOSX10.5.sdk/usr/include
 /Developer/SDKs/MacOSX10.5.sdk/System/Library/Frameworks (framework directory)
 /Developer/SDKs/MacOSX10.5.sdk/Library/Frameworks (framework directory)

When I look at the 10.6 machine it has

/Developer/SDKs/MacOSX10.5.sdk/usr/include/c++/4.2.1/i686-apple-darwin10

That is the missing include, but I'm not sure how that gets included on 10.6 and not 10.7, its not explicitly added anywhere in the build scripts. I believe its based off the BaseSDK of the build, and they are the same.

Was it helpful?

Solution

So I ended up creating my own alias folder called

/Developer/SDKs/MacOSX10.5.sdk/usr/include/c++/4.2.1/i686-apple-darwin11

on my 10.7 machine and now everything compiles. I wonder why the Xcode/SDK installation didn't create this folder for me, like it does on 10.6

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top