[argyllcms] Re: Universal binary for mac OS X
- From: Graeme Gill <graeme@xxxxxxxxxxxxx>
- To: argyllcms@xxxxxxxxxxxxx
- Date: Thu, 06 Jul 2006 01:38:39 +1000
Stefan Heinsen wrote:
Ive been trying to hack the build-system to produce a universal
binary (both intel and ppc-code in one executable) on os x.
As far as i can tell the build-system uses ar to create some
libraries (librspl.a for example) and this failes, because
"The library archive utility, ar(1), cannot work with libraries
containing code for more than one architecture (or single-architecture
libraries generated with lipo(1)) after ranlib has added a table of
contents to them. Thus, if you need to add additional object files to a
library, you must keep a separate copy without a TOC."
(from
http://developer.apple.com/documentation/Porting/Conceptual/PortingUnix/compiling/chapter_4_section_3.html
)
Im not very familiar with neither autotools nor jam, but i can set up
a xcode project if you like.
Unfortunately I don't have an intel based OSX system at present (just my
lowly
600 MHz G4 laptop).
Actually its quite easy to build a universal binary, just set the CFLAGS
to CFLAGS="-isysroot /Developer/SDKs/MacOSX10.4u.sdk -arch ppc -arch
i386" and LDFLAGS to the same, the only problem for me is to get arround
ar.
I'm not quite clear on what the problem is. If I run jam -d2 on my
current system, I see the sequence of tools looks like:
cc -c ....
libtool -o lib.a files.o
Rez ... executables ...
and in the Jambase, ranlib is turned off. So what exactly are you doing
when building Argyll ?
Graeme Gill.
- References:
- [argyllcms] Universal binary for mac OS X
- From: Stefan Heinsen
Other related posts:
- » [argyllcms] Universal binary for mac OS X
- » [argyllcms] Re: Universal binary for mac OS X
Ive been trying to hack the build-system to produce a universal binary (both intel and ppc-code in one executable) on os x. As far as i can tell the build-system uses ar to create some libraries (librspl.a for example) and this failes, because
"The library archive utility, ar(1), cannot work with libraries containing code for more than one architecture (or single-architecture libraries generated with lipo(1)) after ranlib has added a table of contents to them. Thus, if you need to add additional object files to a library, you must keep a separate copy without a TOC."
(from http://developer.apple.com/documentation/Porting/Conceptual/PortingUnix/compiling/chapter_4_section_3.html )
Im not very familiar with neither autotools nor jam, but i can set up a xcode project if you like.
Unfortunately I don't have an intel based OSX system at present (just my lowly 600 MHz G4 laptop).
Actually its quite easy to build a universal binary, just set the CFLAGS to CFLAGS="-isysroot /Developer/SDKs/MacOSX10.4u.sdk -arch ppc -arch i386" and LDFLAGS to the same, the only problem for me is to get arround ar.
I'm not quite clear on what the problem is. If I run jam -d2 on my current system, I see the sequence of tools looks like:
- [argyllcms] Universal binary for mac OS X
- From: Stefan Heinsen