palm-osgarnet-oscodewarriorprc-tools

Can you link 68K code compiled with CodeWarrior for Palm OS with code compiled with PRC-Tools (GCC)?


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?


Solution

  • (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.