[futurebasic] [FB3] 68k shared libraries

Message: < previous - next > : Reply : Subscribe : Cleanse
Home   : November 2000 : Group Archive : Group : All Groups

From: Heather Donahue <HeatherDonahue@...>
Date: Thu, 16 Nov 2000 14:02:53 -0800
I'm not sure if this has been discussed at any point or if anyone is 
interested but it is something I came across recently.

While FB^3 supports PPC shared libraries, I've always wondered if it 
is still possible to use 68k shared libraries.

I was looking over a Carbon porting guide and found mention of 
something that has been available for some time.  I have never tried 
to manually load a plug-in or shared library so I wasn't aware.

Normal pre-Carbon applications link mainly to InterfaceLib.  Carbon 
applications link to CarbonLib.  The two are, generally speaking, 
mutually exclusive.  If you link to InterfaceLib you can't just 
simply load a Carbon based shared library.  A FB^3 PPC application 
can't use a Carbon linked shared library.

The guide I was reading mentioned Carbon applications occasionally 
needing to link to pre-Carbon libraries.  It talks about using 
GetSharedLibrary to load a fragment.  While it doesn't fully explain 
how this is done, especially in FB^3, I have some idea, after looking 
through IM:Code Fragment Manager.

It looks like you use GetSharedLIbrary to load the code fragment. 
Then use FindSymbol to get the address of the symbol.  At this point 
it gets fuzzy, mostly because I'm not sure what the returned address 
is.

Ok, so anyone know how to access a function like this?

I would guess Universal FN, Universal Proc or Call if it's a 68k app.

-- 
Heather