home | O'Reilly's CD bookshelfs | FreeBSD | Linux | Cisco | Cisco Exam  


javac

javac [options ] files

Solaris only. Compile Java source code into Java bytecode, for execution with java . Java source files must have a .java suffix and must be named for the class whose code they contain. The generated bytecode files have a .class suffix. By default, class files are created in the same directory as the corresponding source files. Use the CLASSPATH variable to list directories and/or ZIP files that javac will search to find your classes.

Options

-classpath path

Use the colon-separated list of directories in path instead of CLASSPATH to find class files. It is usually a good idea to have the current directory (".") on the search path.

-d dir

Specify where to create generated class files.

-depend

Recompile missing or out-of-date class files referenced from other class files, not just from source code.

-deprecation

Warn about every use or override of a deprecated member or class, instead of warning at the end.

-encoding encoding

The source file is encoded using encoding . Without this option, the system's default converter is used.

-g

Generate debugging tables with line numbers. With -O , also generate information about local variables.

-J option

Pass option to java . option should not contain spaces; use multiple -J options if necessary.

-nowarn

Disable all warnings.

-O

Perform optimizations that may produce faster but larger class files. It may also slow down compilation. This option should be used with discretion.

-verbose

Print messages as files are compiled and loaded.


Previous: Reference: java_g UNIX in a Nutshell: System V Edition Next: Reference: javadoc
Reference: java_g Book Index Reference: javadoc

The UNIX CD Bookshelf NavigationThe UNIX CD BookshelfUNIX Power ToolsUNIX in a NutshellLearning the vi Editorsed & awkLearning the Korn ShellLearning the UNIX Operating System