-
Notifications
You must be signed in to change notification settings - Fork 109
The isysroot Issue
You are here: Home → Documentation → Mac information page → Coin3D/Mac FAQ → Universal Binaries → The isysroot Issue
To create UBs on a PPC machine, the Universal Binary SDK needs to be specified by passing the -isysroot option to gcc. This is taken care of by our configure script, however there is one small issue: As this option changes the root directory of where system libraries and frameworks are expected to reside, any frameworks located in /Library/Frameworks will not be found!
Consider this scenario:
- You configure Coin as a Universal Binary, using the --enable-universal configure flag.
- This flag causes "-isysroot /Developer/SDKs/MacOSX10.4u.sdk" to be added to the CFLAGS variable, which means that the instead of /System/Library/Frameworks/OpenGL.framework, the path /Developer/SDKs/MacOSX10.4u.sdk/System/Library/Frameworks/OpenGL.framework will be used instead. This is intentional, and fine so far.
- Everything goes well, Coin ends up being installed in /Library/Frameworks/Inventor.framework
- You configure SoQt as a Universal Binary, using the --enable-universal configure flag.
- This flag causes "-isysroot /Developer/SDKs/MacOSX10.4u.sdk" to be added to the CFLAGS variable, which means that the instead of /System/Library/Frameworks/OpenGL.framework, the system looks for /Developer/SDKs/MacOSX10.4u.sdk/System/Library/Frameworks/OpenGL.framework instead. This is intentional, and fine so far.
- However, this also means that instead of /Library/Frameworks/Inventor.framework, the system looks for /Developer/SDKs/MacOSX10.4u.sdk/Library/Frameworks/Inventor.framework instead. This is obviously a problem.
The solution is simple: Create a symbolic link in the 10.4u SDK...
sudo mkdir -p /Developer/SDKs/MacOSX10.4u.sdk/Library/Frameworks
sudo ln -s /Library/Frameworks/Inventor.framework \
/Developer/SDKs/MacOSX10.4u.sdk/Library/Frameworks/
... after installing Coin (but before running SoQt-configure).
If you are using the framework installation of Qt-4, you will need to do
the same for the Qt frameworks. Something like this should
do the trick:
cd /Library/Frameworks
for i in Qt*.framework; do sudo ln -s /Library/Frameworks/$i \
/Developer/SDKs/MacOSX10.4u.sdk/Library/Frameworks/ ; done
Finally, you have to also take this into consideration when you build a Universal Binary application, so do not forget to also create a symlink for Sc21 (or SoQt, as appropriate) in /Developer/SDKs/MacOSX10.4u.sdk/Library/Frameworks/