terp - the ANT Tasks
v1.3.304

com.codemesh.terp.ant.compiler.cpp
Interface CppCompilerOptions

All Known Subinterfaces:
CppCompiler
All Known Implementing Classes:
Acc.Impl, CppCompilerImpl, CppCompilerOptionsImpl, Gcc.Impl, Icc.Impl, Msvc.Impl, Qcc.Impl, Suncc.Impl, Xlc.Impl

public interface CppCompilerOptions

An interface that aggregates C++ compiler options for reuse.


Method Summary
 BoundsCheckOption createBoundsCheck()
          Creates a BoundsChecker option.
 CompileOnlyOption createCompileOnly()
          Creates a compile-only option (/c or -c).
 DebugOption createDebug()
          Creates a debug option.
 DefineOption createDefine()
          Creates a preprocessor definition.
 ExceptionsOption createExceptions()
          Creates an option that can be used to en/disable exception support.
 IncludeOption createInclude()
          Creates an option that adds one or more directories to the preprocessor search path.
 LibpathOption createLibpath()
          Creates an option that adds one or more directories to the library search path.
 LibraryOption createLibrary()
          Creates an option that specifies one or more libraries to link with.
 ManifestOption createManifest()
          Not used yet.
 MultithreadedOption createMultithreaded()
          Creates an option that governs whether or not multithreading is enabled.
 OptimizeOption createOptimize()
          Creates an option that controls compiler optimizations.
 GenericOption createOption()
          Creates a generic option.
 QuietOption createQuiet()
          Creates an option that controls compiler verbosity.
 RelocatableOption createRelocatable()
          Creates an option that controls whether or not the generated modules are relocatable in memory.
 RttiOption createRtti()
          Creates an option that can be used to en/disable RTTI support.
 RunpathOption createRunpath()
          Creates an option that can be used to embed a runpath in a module.
 RuntimeOption createRuntime()
          Creates an option that specifies the type of C++ runtime library to use.
 UndefineOption createUndefine()
          Creates an option that undefines a preprocessor definition.
 WarningsOption createWarning()
          Creates an option that adjusts the warning level or specific warnings.
 CompilerOptionSet<CppCompiler> getOptions()
          Returns the options configured for this instance.
 

Method Detail

getOptions

CompilerOptionSet<CppCompiler> getOptions()
Returns the options configured for this instance.

Returns:
the options.

createBoundsCheck

BoundsCheckOption createBoundsCheck()
Creates a BoundsChecker option. A BoundsChecker option is only useful for MSVC++ builds and instructs the compiler task to instrument the compiled code for use by BoundsChecker. Obviously, for this to work, BoundsChecker needs to be installed and locatable.

Returns:
a newly created BoundscheckOption.

createCompileOnly

CompileOnlyOption createCompileOnly()
Creates a compile-only option (/c or -c). You should only have one enabled instance of this type in your compiler task.

Returns:
a newly created CompileOnlyOption.

createDebug

DebugOption createDebug()
Creates a debug option. The debug option allows you to specify whether you wish to include debug information in the build result or not.

You should only have one enabled instance of this type in your compiler task. The debug option interacts with a number of other options (for example the RuntimeOption).

Returns:
a newly created DebugOption.

createDefine

DefineOption createDefine()
Creates a preprocessor definition.

Returns:
a newly created DefineOption.

createExceptions

ExceptionsOption createExceptions()
Creates an option that can be used to en/disable exception support. Not all compilers support programmatic control of exception support, so take care with this option. Don't use it unless you're sure you know what you're doing.

Returns:
a newly created ExceptionsOption.

createInclude

IncludeOption createInclude()
Creates an option that adds one or more directories to the preprocessor search path.

Returns:
a newly created IncludeOption.

createLibpath

LibpathOption createLibpath()
Creates an option that adds one or more directories to the library search path.

Returns:
a newly created LibpathOption.

createLibrary

LibraryOption createLibrary()
Creates an option that specifies one or more libraries to link with. The option supports more than one library via a comma- or semicolon- separated list. Don't use directory names here. Don't use file extensions; they are automatically added.

Returns:
a newly created LibraryOption.

createManifest

ManifestOption createManifest()
Not used yet.

Returns:
a newly created ManifestOption.

createMultithreaded

MultithreadedOption createMultithreaded()
Creates an option that governs whether or not multithreading is enabled. This is a simple boolean option that influences several other options, for example RuntimeOption. It can result in several different switches being added to the compiler invocation in multiple phases. Don't use more than one enabled option of this type.

Returns:
a newly created MultithreadedOption.

createOptimize

OptimizeOption createOptimize()
Creates an option that controls compiler optimizations.

Returns:
a newly created OptimizeOption.

createOption

GenericOption createOption()
Creates a generic option. A generic option does not have any smarts about its interaction with other options or with the compiler. You specify to which compiler it applies, you specify to which compiler phase it applies, you're in charge of resolving conflicts with other options. GenericOptions are teh escape hatch of the C++ compiler. They allow you to pass any compiler switch you want but you're completely on your own in managing them and figuring them out.

Returns:
a newly created GenericOption.

createQuiet

QuietOption createQuiet()
Creates an option that controls compiler verbosity.

Returns:
a newly created QuietOption.

createRelocatable

RelocatableOption createRelocatable()
Creates an option that controls whether or not the generated modules are relocatable in memory. For most Unix compilers, this is equivalent to the -KPIC or -fPIC option.

Returns:
a newly created RelocatableOption.

createRtti

RttiOption createRtti()
Creates an option that can be used to en/disable RTTI support. Not all compilers support programmatic control of RTTI support, so take care with this option. Don't use it unless you're sure you know what you're doing.

Returns:
a newly created RttiOption.

createRunpath

RunpathOption createRunpath()
Creates an option that can be used to embed a runpath in a module. This is only relevant on Unix/Linux platforms where a runtime searchpath can be used to modify the default searchpaths configured in the execution environment.

Returns:
a newly created RunpathOption.

createRuntime

RuntimeOption createRuntime()
Creates an option that specifies the type of C++ runtime library to use. This is only relevant when using the Microsoft compiler.

Returns:
a newly created RuntimeOption.

createUndefine

UndefineOption createUndefine()
Creates an option that undefines a preprocessor definition.

Returns:
a newly created UndefineOption.

createWarning

WarningsOption createWarning()
Creates an option that adjusts the warning level or specific warnings.

Returns:
a newly created WarningsOption.

terp - the ANT Tasks
v1.3.304

Copyright © 2008-2012 by Codemesh, Inc. All Rights Reserved.