Community
Participate
Working Groups
I am experiencing an odd failure occasionally and seemingly randomly when using the default Java Builder to compile source. All non .java files in source tree are copied to 'default output folder'and the entire directory structure is also recreated. However, absolutely no .java files are compiled into the output folder (ie. no .class files appear). The log shows no errors. Ive found no consistent way to produce this problem. It gives every appearance of being annoyingly random. Ive found no consistent way to fix this other than deleting and recreating the entire project. Log header: eclipse.buildId=I20050401-1645 java.version=1.5.0-beta java.vendor=Sun Microsystems Inc. BootLoader constants: OS=win32, ARCH=x86, WS=win32, NL=en_US Command-line arguments: -os win32 -ws win32 -arch x86
First time I hear about such an issue. Does it occur when running Eclipse on a 1.4 JRE ? 1.5 JREs are still somewhat unstable (e.g. our batch compiler runs fine on 1.4 VM, but crashes 1.5 runtimes).
So can you reproduce by repeating choosing 'Project->Clean...' ? How many full builds do you need to do before it fails? Are there any major errors attached to any of your projects? Or does your project dependency graph have cycles in it?
Upon further investigation, there was an error in a class file. Apparently failure occurs in a specific situation: It fails to compile if one of your classes extends a class that has a dependency that is not in the classpath. I had one class X that extends another class Y that needs a dependency Z that was not in the classpath. I added the needed jar containing the class Z and compilation started working again. Compilation works with any other sort of existing error.
But in the case you had, we intentionally report a major build error against the project to avoid creating hundreds, if not thousands of errors. In numerous cases, its not just 1 class that is missing but quite a few from the same jar file. Fixing the classpath is a straight forward thing for the user to do and needs to be done for the code to compile. By only creating 1 error in this case, we focus the user on what needs to be fixed so the project can be built. You should always double check the errors on your project if the build does not succeed.