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.
Steps to reproduce: - use New Project wizard and generatwe Java Desktop Application (Basic) project - build main project "Clean and Build" works. It fails only for a first time, next "Build" action is ok. Product Version: NetBeans IDE Dev (Build 200710211200) Java: 1.5.0_12; Java HotSpot(TM) Client VM 1.5.0_12-b04 System: Linux version 2.6.20-16-generic running on i386; UTF-8; en_US (nb)
Created attachment 51402 [details] output.txt
Seems "Build" does not work properly in some cases. "Clean and Build" always work. Here's another scenario to reproduce: - Create a Java Desktop Application (e.g. DesktopApplication1). - Do "Clean and Build". - Do some modification in the View class (DesktopApplication1View) - whatever change to make the file recompile. - Invoke "Build" - it fails on missing application class (DesktopApplication1) which is referred from the View class. Looking into build/classes, the DesktopApplication1.class is missing - was deleted, but not compiled again. Reassigning to java project for evaluation.
It seems that the projects created by the Swing app framework are using the wrong build-impl.xml! They are old. Please delete any build-impl.xml (and build.xml) from the ZIPs used for such project templates, and let them be generated by GeneratedFilesHelper. The first problem I can no longer reproduce after the fix of issue #119777 - this was independent of build-impl.xml. The second problem I can still reproduce but it likely caused by having the wrong build-impl.xml, unless you can reproduce the same in a regular j2seproject.
Fix of issue 119777 probably fixed the most visible problem - that the project could not be built/run just after created. This works in today build. But even with the latest build-impl.xml, or if I copy sources to a normal j2seproject, I can still see the problem with build - with slightly different steps: after the second step invoke "Clean" on the project before modifying the view class.
BTW as for using GeneratedFilesHelper, it needs to be given the stylesheet URL, which is inside the j2seproject module in this case. I don't like using a hardcoded string like "org/netbeans/modules/java/j2seproject/resources/build.xsl" and having hidden dependency on j2seproject internals. Or is there a better way?
Wrong component. I think you misunderstood about GFH. You do not need to call it. You do not need to do anything except _delete_ build.xml and build-impl.xml from your project template. These files should get created automatically when the project is opened anyway.
> These files should get created automatically when the project is opened anyway. That would never occur to me... Thanks.
Originally reported issue is a duplicate. Other issue reported by tpavek, either in its original form or in the modified form with the "2.5. Clean", I cannot reproduce in a dev build, now that the build-impl.xml issue was resolved in trunk (according to CVS logs; no accompanying issue # in the comment). If you can still reproduce, please file a fresh bug (java/j2seproject, jglick) with _exact_ steps to reproduce. *** This issue has been marked as a duplicate of 119777 ***
Verified Product Version: NetBeans IDE 6.0 RC2 (Build 200711191200) Java: 1.6.0_04; Java HotSpot(TM) Client VM 10.0-b19 System: Linux version 2.6.20-15-generic running on i386; UTF-8; en_US (nb)