Re: project dependency problems in netbeans
Wade Chandler <[email protected]>
| Newsgroups | gmane.comp.java.netbeans.general |
|---|---|
| Message-ID | <[email protected]> |
--- imran aman <[email protected]> wrote: > Hi, > > I have a project created called proj-lib/lib which holds all jars required > for other projects like proj-server and proj-client. > > When i attach proj-lib to proj-server and proj-client, netbeans jars up the > project (proj-lib.jar) and adds it to the classpath. > > Then, when i clean and build proj-server or proj-client they dont seem to > recognize the library and hence do not compile. > > One project (in this case proj-server) should be able to reference other > project (proj-lib) without being jarred. > > Does there exist a workaround for this or is it an overlooked functionality. > Next time please use nbusers for general user questions. This list is about discussing the NB web site, source control, etc...the NB project infrastructure. On your issue, the projects should work as you describe. This is how I use them often. I'm not following exactly when you are having the problem. Do you mean, you have these 3 projects server, client, lib. Server and client depend on lib, and when you compile either one it is not finding the files for lib? If so, it sounds like what happened is you built lib, then went into the server and client projects and set the lib projects JAR file as a dependency instead of choosing to make the project the dependency. In that case it would work as you describe as the server and client projects think they should just use the JAR file and not force a rebuild. I think you need to go into server and client and remove the dependency on lib's JAR. You then need to click the Add Project button in your library/dependency management screen for those projects. Then choose the lib project versus a JAR file. Notice the different buttons and their use. If that is not it then write back and we'll try to figure something out. Wade ================== Wade Chandler, CCE Software Engineer and Developer, Certified Forensic Computer Examiner, NetBeans Dream Team Member, and NetBeans Board Member http://www.certified-computer-examiner.com http://wiki.netbeans.org/wiki/view/NetBeansDreamTeam http://www.netbeans.org