Re: Building Frameworks in Java
Re: Building Frameworks in Java
- Subject: Re: Building Frameworks in Java
- From: Bradley Smith <email@hidden>
- Date: Tue, 3 Feb 2004 01:27:37 -0600
I finally figured out how to make this work that way - thanks for the
suggestion. By the way, in XCode (I don't know about PB) there is
another way. Once you have a jar file added as a framework, you can go
to the target properties and click on the Frameworks and Libraries and
tell it to merge the jar file. It will then create a jar file with the
project name in Resources/Java. Unfortunately, you still have to
manually set the classpath, but it's easier than creating a new build
phase.
I would still like a way to package the jar file and the headers into a
unit so my other developer could use both without having to manually
sync them.
Brad.
On Jan 31, 2004, at 19:06, Rams wrote:
I'm new to Obj-C, so this may be irrelevant for your needs, and I
haven't tried it XCode yet, but...
When I needed an outside/third party jar file to build anything in
Project Builder, the trick was to add a 'copy files build phase' to
the appropriate 'target'. Once you have it set to copy the jar to the
Java resources folder, you need to drag the jar file reference from
your 'groups & files' into the 'frameworks & libraries' list on your
target. Like I said, I haven't tried it in XCode, but that was the
way to include a third party .jar in a project for Project Builder.
Perhaps it still works?
Hope that helped, sorry for the wild goose chase if not.
On Jan 31, 2004, at 2:20 PM, Bradley Smith wrote:
I am trying to develop a Cocoa program with another developer and my
portion is written in Java, his is written in Objective-C. I build
all of my stuff with Ant and he builds his in XCode. I have been
trying to figure out how to share my code with his, and so far I have
encountered the following problems:
1 - I generated header files for my Java classes to help keep things
in sync, and I can't figure out how to get those header files into
XCode without having to set an explicit search path. My headers are
organized into directories that mimic the package structure of the
Java classes they document. This is done to create pseudo namespaces
to differentiate any classes with the same name. This isn't
mandatory, but I would like to keep it that way. The problem is that
XCode automatically flattens all the files into one directory so the
imports like "com/doodah/Class.h" don't work.
2 - I finally figured out how to include the jar file in the project
and the built application. I added the thing as a framework, then
under the target settings I told it to merge the contents with the
executable.
After futzing with this for a while, I thought that a better option
might be to create a framework with all the headers and jar files,
but I can't find any documentation on how to do this. I would like
to make it as simple as possible for me to relay my Java changes to
the other developer.
Has anyone done this before that might have some pointers? I have
exhausted all the documentation I know of and I would like to be able
to move on to bigger stuff.
Brad.
_______________________________________________
java-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/java-dev
Be sure to read the FAQ http://developer.apple.com/java/faq/ before
posting
Do not post admin requests to the list. They will be ignored.
--
"NT 5.0 is the last nail in the Unix coffin. Interestingly, Unix isn't
in the coffin... It's wondering what the heck is sealing itself into a
wooden box 6 feet underground..." --Jason McMullan
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.