[fpc-pascal] Re: building universal binary

Ken G. Brown kbrown at mac.com
Tue Feb 3 23:07:48 CET 2009


Further:
it appears that lipo cannot handle app bundles, so if I run it on the executable itself, it says it is ok, has both i386 and ppc. So I guess I'm missing something that tells Finder it is a universal binary, but what?

Thx,
Ken G. Brown

At 12:21 PM -0700 2/3/09, Ken G. Brown apparently wrote:
>Mac OS X 10.5.6, fpc 2.2.2, Xcode 3.1.2
>
>Have a Pascal program calling some C code from a static library I build in a separate project so I can use the debugger.
>
>I've set Xcode to use gcc 4.0 targeting 10.4 for intel, and gcc 3.3 targetting 10.3.9 for PowerPC in both projects.
>
>So far I am basically using the fpc user defined options that came with the template for building for calling C functions.
>
>Do I need to add some fpc options in order to properly compile for a universal binary?
>
>I looked at my App using lipo -info fromTerminal and get the following error:
>lipo: Can't map input file: .../myapp/build/Release/myapp.app ((os/kern) invalid argument)
>
>As well, in Finder Get Info for my app, the 'open using Rosetta checkbox is greyed out and I cannot select it. Activity Monitor of course shows an intel program but i need to deploy to PowerPC running 10.3.9.
>
>If I look at my 'C' library project product with lipo, I get Architectures in the fat file: ...../libkbCarbonLib.a are: i386 ppc 
>
>What else do I need to do in order to generate a universal binary? Do I need to run the fpc ppc version somehow for the ppc side of tings? I suspect so but cannot find what to do.
>
>Any tips appreciated.
>
>Thx,
>Ken G. Brown




More information about the fpc-pascal mailing list