I've been digging the archives and the knowledge database for hours (if not
days),
and I haven't found any precise information about creating some CODE
resource
in CodeWarrior. The article in KB called "Shared Libraries and Other
Advanced Project Types"
gives some information but it's really vague and they don't go into details
or give any sample code.

I would like to create a CODE resource inside my application, and being able
to call some of
the functions defined in that resource from my application.
I don't want to create a standalone plugin prc file. I just want my resource
inside my application.

Can someone tell me precisely what needs to be done to achieve that ?
and what are the project settings I need to make it work.


Here is what I've done so far:

- I have created a new target within my application.
- I've put the code I want to be accessible as a resource in that target.
- I've changed the 68K target settings to PalmOS Code Resource, specified
the restype CODE and a ResID (3000)
 and I also changed the target settings for the Post Linker to none (instead
of Palm Rez Post Linker) 'cause I don't
want to generate another prc file for that resource.
- in that code, I've defined an entry point function as __Startup__
- I try to call that function from my app

My code compiles, but I get a linker error... I don't think it would be very
helpful
to write it down here, but here it is anyway :  << __RuntimeModule__:
'__segtable__' has illegal single segment 32-bit reference to
'__DummyStartup__'  >>

What would be wonderful is to see a sample code of a simple CODE resource,
to see what I'm missing.


Thanks !


-- 
For information on using the Palm Developer Forums, or to unsubscribe, please see 
http://www.palmos.com/dev/tech/support/forums/

Reply via email to