Apache Maven 1.x has reached its end of life, and is no longer supported. For more information, see the announcement. Users are encouraged to migrate to the current version of Apache Maven.

Compile Settings

PropertyOptional?Description
maven.compile.compilerargs Yes

Provides arguments to a compiler when maven.compile.fork is set to true

Corresponds to the nested compilerarg element for the ant javac task.

maven.compile.debug Yes Specifies wether to include debugging information in the compiled class files; the default value is on. Used by the "java:compile" goal.
maven.compile.debuglevel Yes

Keyword list to be appended to the -g command-line switch. This is only used if maven.compile.debug=on. Defaults to lines,vars,source.

Corresponds to the debuglevel attribute for the ant javac task.

maven.compile.deprecation Yes Specifies wether source should be compiled with deprecation information; the default value is on. Used by the "java:compile" goal.
maven.compile.encoding Yes

Sets the encoding of the .java files being compiled

Corresponds to the encoding attribute for the ant javac task.

maven.compile.executable Yes

Names the program to be invoked as the java compiler

Corresponds to the executable attribute for the ant javac task.

maven.compile.fork Yes

Runs the compiler in a separate process

Corresponds to the fork attribute for the ant javac task.

maven.compile.memoryInitialSize Yes

Sets the initial memory size value passed to the VM when fork is set to true. Has no effect if fork is false.

Corresponds to the memoryInitialSize attribute for the ant javac task.

maven.compile.memoryMaximumSize Yes

Sets the maximum memory size value passed to the VM when fork is set to true. Has no effect if fork is false.

Corresponds to the memoryMaximumSize attribute for the ant javac task.

maven.compile.optimize Yes Specifies whether source should be compiled with optimization; the default value is off. Used by the "java:compile" goal.
maven.compile.src.set Yes The source directories maven uses to compile java code.
maven.compile.source Yes

Specifies the source version for the Java compiler.

Corresponds to the source attribute for the ant javac task. This value defaults to 1.3 so that builds on JDK 1.4 or later stil work on earlier JVMs. Valid values are 1.3, 1.4, 1.5.

maven.compile.target Yes

Generate class files for a specific JVM version

Corresponds to the target attribute for the ant javac task. This value defaults to the Ant task default value.

maven.compile.verbose Yes

Asks the compiler for verbose output

Corresponds to the verbose attribute for the ant javac task.

maven.compile.log Yes

Where to save the output of the compiler. Only works when fork is true.

The default value for this property is ${maven.build.dir}/compile.log

pom.build.sourceModifications Yes This property is the list of the
<build>
  <sourceModifications>
    <sourceModification>
      <className></className>
      <excludes>
        <exclude></exclude>
      </excludes>
    </sourceModification>
  </sourceModifications>
</build>
source modifications in your project descriptor. This property is used during compilation to exclude or include classes from compilation depending on whether a named class is available
maven.compile.nowarn Yes

Indicates whether the -nowarn switch should be passed to the compiler; defaults to off.

Corresponds to the nowarn attribute for the ant javac task.

maven.compile.failonerror Yes

Indicates whether the build will continue even if there are compilation errors; defaults to true.

Corresponds to the failonerror attribute for the ant javac task.

Other Settings

PropertyOptional?Description
maven.build.dest Yes The directory for compiled classes
maven.dependency.classpath Yes This property holds the Ant path of all the dependent jar files listed in the dependencies block of your project descriptor