This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 173261 - Build of EAR fails due to property not set
Summary: Build of EAR fails due to property not set
Status: RESOLVED WONTFIX
Alias: None
Product: javaee
Classification: Unclassified
Component: App Client (show other bugs)
Version: 6.x
Hardware: All All
: P4 blocker (vote)
Assignee: David Konecny
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-09-29 13:06 UTC by Jaroslav Pospisil
Modified: 2016-07-07 08:56 UTC (History)
2 users (show)

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Jaroslav Pospisil 2009-09-29 13:06:13 UTC
6.8 Beta candidate, JDK1.6.0_16, Win Vista

Download projects from this link (
http://kenai.com/projects/netbeans-samples/downloads/download/Samples/JEE/entappclient.zip ) and open them in the IDE.
Resolve missing server problems (point it to bundled Glassfish v3
) and Clean and Build each project. Build of EAR project will fail with this log:

pre-init:
init-private:
init-userdir:
init-user:
init-project:
do-init:
post-init:
init-check:
init:
undeploy-clean:
deps-clean:
C:\Users\JP154641\Downloads\entappclient\EnterpriseAppEE5\nbproject\build-impl.xml:495: The following error occurred
while executing this line:
C:\Users\JP154641\Downloads\entappclient\EnterpriseAppEE5\EnterpriseAppEE5-app-client\nbproject\build-impl.xml:358: The
libs.CopyLibs.classpath property is not set up.
This property must point to 
org-netbeans-modules-java-j2seproject-copylibstask.jar file which is part
of NetBeans IDE installation and is usually located at 
<netbeans_installation>/java<version>/ant/extra folder.
Either open the project in the IDE and make sure CopyLibs library
exists or setup the property manually. For example like this:
 ant -Dlibs.CopyLibs.classpath=a/path/to/org-netbeans-modules-java-j2seproject-copylibstask.jar
BUILD FAILED (total time: 0 seconds)

Problem is, that build still fails,even if I add this library to project manually and confirm, that requested jar exists
under described path.
Comment 1 Martin Schovanek 2009-09-29 13:17:19 UTC
This issue is considered as Nb 6.8 Beta stopper.

I was able to reproduce this on my box for a while but then magically disappeared but 100% reproducible on Jarda's box.
Comment 2 Martin Schovanek 2009-09-29 13:31:56 UTC
steps to reproduce:
-------------------
1) expand the entappclient.zip 
2) open all 3 projects at once
3) Clean and Build the EAR
ERROR: you got the: 'The libs.CopyLibs.classpath property is not set up' error
4) close the App Client and EJB projects
5) right click the EAR project node and choose Open Required Projects
6) Clean and Build the EAR
NOTE the build finish sucessfully
Comment 3 Vince Kraemer 2009-09-29 18:19:44 UTC
There are 5 projects in the zip file...

Which 'all 3' did you open?
Comment 4 David Konecny 2009-09-29 23:57:36 UTC
By 3 projects they mean 3 projects from root of the ZIP file.

I'm able to reproduce it but I disagree that it is a show stopper. That same problem was there probably since NB 5.0 and
nobody complained about it. The EAR project you opened and you are trying to build is using two other projects which
were previously never opened in the IDE and therefore nbproject/private/private.properties file is missing and therefore
none of the properties defined in userdir (classpath of all NetBeans global libraries) is available.

Workaround is to open EAR's module projects.

Possible solution (if this is an issue worth to fix at all) is to detect whether required project was ever opened in IDE
before building it and it was not force project opening to refresh build script and properties.

It should be possible to simulate the same problem with two J2SE projects: make two projects one using each other, put
some library on their classpath and use some class from the library on classpath in both of them; close them and delete
private and then open just one project and rebuild it.
Comment 5 Martin Balin 2016-07-07 08:56:52 UTC
This old bug may not be relevant anymore. If you can still reproduce it in 8.2 development builds please reopen this issue.

Thanks for your cooperation,
NetBeans IDE 8.2 Release Boss