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.
With a J2SE project, there's no way to specify extra javac options. Especially setting -Xlint:unchecked should be possible, but probably other options should be made possible as well. The tab Project Properties/Build/Compiling Sources seems to be the proper location for setting these options, since the -g and -deprecation are controlled there as well. If not to be controlled by the UI, then at least manual modifications to project.properties should be supported, e.g. with the javac.options property
Desirable though not clear if it will be straightforward with Ant to add arbitrary options from a single property (or set of properties). Probably <compilerarg line="..."/> will work. In the meantime, can override -init-macrodef-javac in build.xml to the same effect. See also #43395 for -Xlint:unchecked specifically.
The tip from #43395 works like a charm. Though I would not recommend to let a new netBeans user to poke around in build.xml, it would require knowledge of both XML and Ant. Although generics are somewhat more advanced language features, any programmer that uses the java.util from JDK 1.5 will run into the Note sooner or later. A generics newbee should see the warnings, an advanced programmer can turn them off and will settle for the Note.
Yes, generally agreed. I think too late to change for 4.0 due to feature freeze but will try to do it for 4.1, along with a general expansion of the things that are configurable in the GUI for j2seproject's.
*** Issue 43395 has been marked as a duplicate of this issue. ***
I added new property "javac.compilerarg" which can hold these optional arguments. Empty property with description comment is generated to project.properties. You do not have to override the target in build-impl.xml anymore and can instead just set this property. Changed files: src/org/netbeans/modules/java/j2seproject/Bundle.properties; new revision: 1.15; previous revision: 1.14 src/org/netbeans/modules/java/j2seproject/J2SEProjectGenerator.java; new revision: 1.26; previous revision: 1.25 src/org/netbeans/modules/java/j2seproject/resources/build-impl.xsl; new revision: 1.32; previous revision: 1.31
Sorry, one more change: I renamed "javac.compilerarg" to "javac.compilerargs" to make it consistent with other properties.
*** Issue 47904 has been marked as a duplicate of this issue. ***
Checking in j2seproject/src/org/netbeans/modules/java/j2seproject/ui/customizer/Bundle.properties; /cvs/java/j2seproject/src/org/netbeans/modules/java/j2seproject/ui/customizer/Bundle.properties,v <-- Bundle.properties new revision: 1.33; previous revision: 1.32 done Checking in j2seproject/src/org/netbeans/modules/java/j2seproject/ui/customizer/CustomizerCompile.form; /cvs/java/j2seproject/src/org/netbeans/modules/java/j2seproject/ui/customizer/CustomizerCompile.form,v <-- CustomizerCompile.form new revision: 1.8; previous revision: 1.7 done Checking in j2seproject/src/org/netbeans/modules/java/j2seproject/ui/customizer/CustomizerCompile.java; /cvs/java/j2seproject/src/org/netbeans/modules/java/j2seproject/ui/customizer/CustomizerCompile.java,v <-- CustomizerCompile.java new revision: 1.11; previous revision: 1.10 done Checking in j2seproject/src/org/netbeans/modules/java/j2seproject/ui/customizer/J2SEProjectProperties.java; /cvs/java/j2seproject/src/org/netbeans/modules/java/j2seproject/ui/customizer/J2SEProjectProperties.java,v <-- J2SEProjectProperties.java new revision: 1.24; previous revision: 1.23 done
*** Issue 46284 has been marked as a duplicate of this issue. ***
*** Issue 48127 has been marked as a duplicate of this issue. ***
*** Issue 48176 has been marked as a duplicate of this issue. ***
Verified in custom 20040901.