On 26/11/01 15:37 -0500, Robert Mah wrote:
> Hi,
>
> I'm trying to use some MacOS X framework based libraries in an Inline::C
> module. However, I've been unable to get any framework to link with the
> module properly.
Fortunately I use OS X daily on my trusty laptop. :)
> For example, the simple code below should link with the CoreServices
> framework and give me access to the Gestalt() system call.
Thanks for a very good description of the problem and for some (almost)
working code. I get the same results as you on my laptop.
I was able to track this down and provide a solution:
use Inline C => Config =>
LDDLFLAGS => '-bundle -undefined suppress -framework CoreServices',
INC => '-I/Developer/Headers/FlatCarbon';
use Inline C => <<'END_OF_C_CODE';
....
There are two little buglets with Inline. The first is that multiple
'Config' calls seem to clobber each other. (So use one :) The second
is that LDDLFLAGS clobbers the system defaults rather than append to
them. For now you'll need to specify them manually. I'll fix this in
the next release.
Cheers, Brian