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.
When I tried the 6.0-200708211200 daily build, it complained of not being able to find one of my classes in our free-form project. This class is generated by our custom ant script at build time, so we don't include it in the source package folder of our project. We *do* include it in the source classpath folder (even this was unnecessary in NB5.5). However, it still cannot find the class. This is a regression from 6.0m10, which works for us. To reproduce this, unzip the attached directory and load the "j3d-core" project. You will notice the red "error" icon. When you navigate to the javax.media.j3d.VirtualUniverse class, you will see that VersionInfo cannot be found. The object code for this class is in j3dcore.jar, which is one of the output targets of the project. The source code is in j3d-core/build/default/debug/gen/classes which is included in the source classpath.
Since the project is too big to attach (10 Mbytes compressed), here is a pointer to it: http://download.java.net/media/java3d/bugs/nb-bugs/113765.zip
As a workaround, if we put the source directory containing the auto-generated VersionInfo.java file into the "source package folders" then it works.
The workaround is the right solution, the reported behavior is a fix. You cannot have java source files on the classpath, the java compiler does not list the source file in the classpath, you have to have them in the source path. See: https://openjdk.dev.java.net/source/browse/openjdk/jdk/trunk/j2se/src/share/classes/com/sun/tools/javac/jvm/ClassReader.java?rev=247&view=markup fillIn(PackageSymbol p) where the completer lists only classfiles from classpath if there is at least one source folder given on source path. I will also add an test containing src folder with Main class which imports Library stored in lib folder, the lib folder is on the classpath. The project is uncompilable (ant compile) if there is no class file of Library.java in the lib root. NetBeans reports the same errors as the java compiler. When you add the folder to source path it works fine, in the current build there is some problem with freeform project causing several errors to appear after this change until ide restart, I've reported it in issue #113953.
Created attachment 47602 [details] Test project