11-03-2009 12:42 PM - last edited on 11-03-2009 01:37 PM
In this project X I have an imported jar(A.jar) file which is using RIM API as well. This jar file was created from blackberry project A by Eclipse plugin. Then project X import A.jar.
Now I build project X, it will generate a cod file, x.cod, which does not contain any information of A.jar file.
So how can I build A.jar and X project into one cod file?
I have checked the forum and there are couple of threads are talking about this issue. But there is no clear answer on this.
Does anyone know the answer? Yes....or No? Thanks a lot.
11-03-2009 01:23 PM
Can you not just build a cod from your jar, and so have two cod files?
11-03-2009 01:27 PM - last edited on 11-03-2009 01:29 PM
After I built, there is only one cod file named X.cod, but this one doesn't contain A.jar. I hope to build a X.cod with A.jar inside. Then without A.jar or A.cod, X.cod can work independently.
11-03-2009 03:11 PM
any idea about this?
11-03-2009 04:00 PM - last edited on 11-03-2009 04:01 PM
Here are two KB articles that might help you:
How To - Compile a MIDlet into a COD file
Article Number: DB-00055
http://www.blackberry.com/knowledgecenterpublic/li
How To - Use the RAPC compiler
Article Number: DB-00066
http://www.blackberry.com/knowledgecenterpublic/li
Using these you should be able to create an A.cod file as well as an X.cod file. Try this to see if you can get it working.
I appreciate it is not what you want (ideally you want a single cod file), but at least this works. Once you have this working, we can think about ways of you getting this into one cod file.
There are posts on this forum that discuss converting a jar to a cod, if the KB articles are not clear..
11-03-2009 04:15 PM - last edited on 11-03-2009 04:17 PM
Thanks perter. actually I was able to create seperate cod file, as A.cod and X.cod, then change alx file to make X.cod reference A.cod, it works.
Still, like what you said, I hope to make it as a single cod file.
Mark mentioned that there is a way to do this, but not that clear.
MSohm wrote:The library JAR file needs to be added to the project itself in order to be built into a COD file.
See here. In Eclipse plugin, how to add a library jar to the project itself? I know how to import, add dependencies, but how to add to itself?
11-03-2009 04:41 PM
Sorry, you will need someone more skilled in Eclipse than me to answer that question....
11-03-2009 04:48 PM - last edited on 11-03-2009 04:52 PM
Thanks Peter.
If anyone knows how to do this in Eclipse plugin, please help! Thanks.