Re: Javac settings
Jan Pokorsky <[email protected]>
| Newsgroups | gmane.comp.java.netbeans.modules.projects.devel |
|---|---|
| Message-ID | <[email protected]> |
Hi Jano, see my comments below. Jan Rojcek wrote: > Hi Svata, > > thank you for your feedback. Inline... > > Svata Dedic wrote: > >> Jan Rojcek wrote: >> >>> Hello team, >>> >>> I am proposing the following javac customizer pane for use in Figures >>> 2, 49 and 53 (in the space for rent) of java project spec. The >>> components are in default state: >>> >>> +------------------------------------------------- + >>> | [ ] Enable JDK 1.4 Sources | >>> | [x] Generate All Debugging Info | >>> | [ ] Report No Warnings | >>> | [ ] Report Usage of Deprecated Members | >>> | | >>> | Additional javac Options: | >>> | +--------------------------------------------+ | >>> | | | | >>> | +--------------------------------------------+ | >>> +--------------------------------------------------+ >>> >> >> [snip] >> >>> Note: >>> "Optimize" is an option shown in the current (NB3.5) external >>> compiler options. I haven't found such option listed between javac >>> options. Was this option used with different external compilers? >> >> >> >> Try "javac -?". The option for optimize is "-O". >> > > I found it but not in JDK1.4.1. Was it removed? It isn't documented in > manual pages of javac, either. > >> Missing options: >> -encoding >> See "javac -?" output + documentation for more details. >> > > I would leave the encoding option for the additional options text field. > Do you find it an important option? > >> -J-Xmx for the javac's virtual machine: if large project is compiled, >> the compiler may run out of memory with the standard heap size. This >> option is adopted by other IDEs in the GUI. >> > > Fine, this should be exposed in the gui. > >> Possibly missing: >> - way to generate NO debugging info at all (if you do not pass >> -g:none, the javac will assume -g:lines,source). Having to type such >> obscure syntax into the free-text area is clumsy, IMHO >> > > I think usage of no debugging info is rare. OTOH, the name "Generate All > Debugging Info" doesn't say what info is generated when unchecked. So > probably a checkbox "Generate Debugging Info:" with combobox containing > two choices: "Sources, Lines, Vars", "Sources, Lines" would be better. > >> Possibly overstrict: >> "Enable JDK 1.4 Sources" -- this one appeared first time with JDK-1.4, >> but according to what is already known about the projected JDK-1.5, >> the language will change again. At that time, the checkbox should be >> replaced by a drop-down chooser of language flavours. >> If the checkbox should remain there, then maybe we could make the name >> more "user-friendly": the only real thing it controls is whether the >> compiler accepts "assert" as keyword (defined in JDK 1.4). So maybe >> "Enable asserts". >> > > I am for keeping the specific checkbox for 1.4, and renaming it. > >> Note: while "target platform" specifies tools, and libraries, >> "-target" switch specifically affects the version number of generated >> .class files, inner class translation etc. I am almost sure that the >> "target" option would be always set to the value of the selected >> target platform, but I would be glad if someone verifies the assumption. >> > > I hope this can be left for the free-options area. > > So, the javac customizer would look like this: > > +---------------------------------------------------------+ > | | > | [ ] Enable Asserts +--------------------+---+ | > | [x] Generate Debugging Info: |Sources, Lines, Vars| v | | > | [x] Report Warnings +--------------------+---+ | > | [ ] Report Deprecations | > | | > | +------------------+ | > | Maximum Heap Size (MBytes): | | | > | +------------------+ | > | | > | Additional Javac Options: | > | +----------------------------------------------------+ | > | | | | > | +----------------------------------------------------+ | > +---------------------------------------------------------+ > > Would that work? > > Thank you, > Jano > 1.) What about to use checkboxes for the debugging info like Generate Debugging Info: [x]Sources [x]Lines []Vars 2.) This customizer is suitable just for the platform 1.4 and maybe above. Older platforms do not support assertions (-source option). Are you going to provide different customizers for older platforms? 3.) You have not answered yet my previous mail where I asked how to handle output folder. Is it possible to customize compiled classes' output folder just via Additional Javac Options (-d option)? 4.) How to solve conflicts between Additional Javac Options and ui components? Thanks, Jan