At 17:41 2003-2-3 -0800, you wrote:
The shared library project type is only available with the Palm OS 68K linker, not the Mac OS 68K linker. However, it is just a specialization of the "code resource" type, with suitable default settings for making a shared library.> Ben Combee: > Palm OS shared libraries are done using the "Palm OS code resource" type > (in V7/V8) and the Palm OS shared library type in V9/PalmOS68K > linker.I don't see a "Palm OS shared library" 68k Type in V9 -- just "Code Resource", "Static Library", and "Application". For my ExgLib, should I just create a "Code Resource" and give it a type of "exgl" (since Matt found that "libr" is not used by ExgMgr)?
Have you tried making a simple shared library and trying that? When a shared library is loaded, its 'libr' 0 resource is locked into memory, and the beginning of the libr segment is called to get the address of the dispatch table. Once you see how that mechanism work with a simple shared library, then the HostXFer code should be clearer.If so, how is __Startup__ used? Again, the HostXfer isn't a great example as it has that function commented out. I presume that I simply get rid of StartupCode.lib from my project and have my own __Startup__ function that calls my DispatchInstaller and then something in the OS will automatically call that function at the appropriate time (like after the lib is first sync'd onto the device)? When I tried this, I couldn't debug the library in CW -- it gives an error: "Can't debug the executable because no appropriate debugger nub can be found".
HostXFer isn't convoluted. It is of the necessary complexity to solve this problem -- I don't think you could have a project that was much simpler that would still be an exchange library along with installation code.I appreciate the tips, but if anyone could provide a CWproject or description of a plain ExgLib in canonical form (not like the convoluted HostXfer example or plain appl with exg entry points), on or offline (freundj at pacbell dot net), I'd certainly appreciate it.
I don't think you'll see that project, as I've seen very little development effort in making exchange libraries so far.
--
Ben Combee <[EMAIL PROTECTED]>
CodeWarrior for Palm OS technical lead
Palm OS programming help @ www.palmoswerks.com
--
For information on using the Palm Developer Forums, or to unsubscribe, please see http://www.palmos.com/dev/support/forums/