01-13-2011 11:24 PM
That could be the one catch, nearly all my libraries are projects that I have loaded into Eclipse so I make dependencies. I have not found a library that I needed that isn't included in the RIM SDK. If there was one, it didn't have the features I was looking for so I made (and am still working on) my own. (That would be my PDF Renderer library I mentioned elseware in this forum).
01-14-2011 05:06 AM
I suspect we are getting off the subject here.
For clarification, there should be no need to rebuild a Library for every OS release. You may be forced to do so because of the way you use the Library. However I use Library files as external jars in the JDE and I assume (from what people have said on this Thread) that the same is possible in Eclipse. Since it is external, the project should not force you to recompile the external jar when you change the project. Or use a different level.
As an example, I have library jar files that I create using the JDE. Other projects use these Libraries as external jars. I typically have only one compiled version of the jar (i.e. one cod file), this is compiled using OS 4.2 currently. This runs on all devices up to and including OS 6.0.
But one of the issues with using this approach is that the build of the project does not copy the cod file into the Simulator, You have to do that manually yourself.
And I am confident it is this step that is missing in this case.
There are two options.
1) If this jar was actually supplied from a third party, then you might have to create a separate project for this jar only and build it into a cod. then manually copy this code into the Simulator. There are various Threads on the forum that talk about this.
2) However in this case, you will have built the cod in the OS 4.7 Simulator, So you just need to copy it into the Simulator.
That should get over the problem.
As a final point, I really like the external jar approach to creating Libraries. This makes the Library and the project completely independent. And you can upgrade one (i.e. replace the cod file) without updating the other. If you use project dependencies, then whenever you change a library, you have to rebuild the entire project.
01-14-2011 10:42 AM
Apologies for the slight deviation from the original question, but since this thread is rapidly becoming a treatise on all things "library" I wonder if you could clarify a few points.
"I typically have only one compiled version of the jar (i.e. one cod file)"
Firstly, and sorry if this is a stupid question, but are you saying you somehow add the cod file to the libraries section of the project, or do you link the jar?
Secondly, does the packager include the library jar in the application cod file, or do you need to deploy as a separate cod file and add the dependency in the jad?
Finally, if the library cod files are deployed separately, are there any issues when loading multiple apps that use the same library cod.
01-14-2011 12:11 PM
Good questions. And I don't mind going off topic, as long we actually answer the original poster's question!
1. "are you saying you somehow add the cod file to the libraries section of the project, or do you link the jar?"
I use the JDE, and add the jar as an imported jar File - see the Project properties Build tab. I am sure there is a similar way to link to an external jar in Eclipse.
2.a. "does the packager include the library jar in the application cod file"
No, you need to manage this relationship manually - the Library is a separate cod for installation on the Simulator and device.
2.b " do you need to deploy as a separate cod file"
2.c "do you ... add the dependency in the jad"
It is put in there automatically.
3. "are there any issues when loading multiple apps"
Absolutely. There are a number of Threads that talk about this and the issues that this brings. And there are curve balls. For example, assume you install Project A that uses Library Z and Project B that also uses Library Z. If you then delete Project A, whether Z is deleted or not seems to be inconsistent.