views:

194

answers:

2

I've got a Palm OS/Garnet 68K application that uses a third-party static library built with CodeWarrior. Can I rebuilt the application using PRC-Tools, the port of GCC for the Palm OS platform and still link with the third-party library?

+2  A: 

No, CodeWarrior uses a different object file format than PRC-Tools. Also, the compiler support libraries are different, so even if the code could be linked together, it may use symbols in a different way.

However, if you can wrap the third-party library into a shared library using CodeWarrior, then you should be able to call it from PRC-Tools applications. The shared library interface works across tools, but shared libraries have limited system support, so you'll need to be sure the original code doesn't use global variables for this to work.

Ben Combee
+4  A: 

(Expanding on Ben's original answer... not sure of the exact etiquette for that but I can't edit yet so I'll re-post)

No, CodeWarrior uses a different object file format than PRC-Tools. Also, the compiler support libraries are different, so even if the code could be statically linked together, it may use symbols in a different way.

However, if you can wrap the third-party static library into a Palm OS shared library using CodeWarrior, then you should be able to call it from PRC-Tools applications. The Palm OS shared library interface works across tools, but shared libraries have limited system support so you'll need to be sure the original code doesn't use global variables for this to work.

For more information on shared libraries, see Shared libraries on the Palm Pilot.

Steve Lemke
I'd just remove all the quoted text and include your addition.
Ben Combee