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.
[ JDK VERSION : J2SE 1.5.0 ] I get the following error when building my project. This is a simple two file / two class project that involves a callback. I tried a couple of things and everything I do continues to work under 3.6 but fails with this same error under 4.0. I have no idea how to troubleshoot/debug a preverify error. Do you think it's a bug? If so, what do you need from me in the way of files? Created dir: C:\Documents and Settings\Owner\ImportedProject-Directions\build\preverified Preverifying 12 file(s) into C:\Documents and Settings\Owner\ImportedProject-Directions\build\preverified directory. Error preverifying class httpConnectionHelper$Callback Class loading error: Wrong name C:\Documents and Settings\Owner\ImportedProject-Directions\nbproject\build-impl.xml:198: Preverification failed with error code 1. BUILD FAILED (total time: 9 seconds)
could you attach/send us the application? Also, if you set Tools | Options | Building | Ant Settings | Verbosity Level, to Verbose you will be able to see the command line used for compilation and preverification.
Hi, I cut the guts out of the main midlet (mapMagic) as it is one I'm about to go commercial with and didn't want the source to get out. Even in the gutted state, it compiles, preverifies and executes (at least the emulator comes up to the launch point) in 3.6. Still get the same preverify error in 4.0. Even with verbose on in Ant, I can't tell what it's upset about. Perhaps something has tightened up in 4.0 that 3.6 used to let me get away with. I'm not a Java guru, so I certainly could be doing something wrong, but I don't think so. Anyway, attached are the two java src files. Let me know if you need anything else. Robin PS: I could not get the attachment screen to work. It's mostly blank with very few options to choose from and it complains no matter what I try. I even disable Norton to see if it was mucking with the screen and still mo luck. Tell me another way to get the source to you and I will try.
Created attachment 17030 [details] Complete Java source for one of two classes in package
Created attachment 17031 [details] Stub version of java source for midlet - Most guts removed
Created attachment 17032 [details] Build.xml output with Use Obfuscation ON
Created attachment 17033 [details] Build.xml output with Use Obfuscation OFF
Thanks, now it is clear. Your "ImportedProject-Test\src" folder should contain the only sources and resources that you want to include in application jar. I see that your "ImportedProject-Test\src" contains even some classes and other files. These classes override the compiled ones during build process and makes the preverification to fail. So the reult is: 1. we should avoid to import classes and other possible problematic files 2. build process should filter classes and may be other possible problematic files and do not treat them as resources 3. you can manually clean your "ImportedProject-Test\src" folder and let there just sources and resources (no compiled classes, no distribution jars, etc...)
Can you be more specific??? I went back thru the imports and there was only one that definitely wasn't required (java.lang.System) Are you saying that I shouldn't wildcard them (as in java.io.*)? With regards to other files in the project directories, all I imported in were the two java src files. All other were placed there by nb 4.0. Are you saying this is user error or bug? If user, will this level of manual intervention always be required?
This is not about imports in your source files, but about importing source files to the project. The problem is that Project created from existing sources copies everything from your old place to the newly created project. Have look at it with some file browser. You will see that src folder in newly created project contains not only *.java files and that's the problem, which preverifier cannot handle. You have to remove all *.class and other unnecessary files from src folder. Mobility has to be more careful when importing existing sources.
fixed, the fix will be available in a next release following files are now filtered during copy from existing sources when new project created: *.class *.addContent *.jad .nbattrs *~ #*# .#* %*% ._* CVS/** .cvsignore SCCS/** vssver.scc .svn/** .DS_Store following files are now filtered during copy from "src" to "build/compiled" folder in build process: *.java *.form *.class
closing