Where do you configure Eclipse Java compiler (java

2019-01-11 23:24发布

问题:

Ex.

javac -g ButtMonkey.java

Where do you configure the -g flag when Eclipse compiles Java source? (Using Ganymede but I doubt that has changed in later versions so any answer probably helps.)

What I need is:

-g

Generate all debugging information, including local variables. By default, only line number and source file information is generated.

回答1:

Select the menu: Window > Preferences > Java > Compiler

There you will find several check boxes under the heading "Classfile Generation".