net.sf.antcontrib.cpptasks.compiler
public abstract class CommandLineCompiler extends AbstractCompiler
Constructor Summary | |
---|---|
protected | CommandLineCompiler(String command, String identifierArg, String[] sourceExtensions, String[] headerExtensions, String outputSuffix, boolean libtool, CommandLineCompiler libtoolCompiler, boolean newEnvironment, Environment env) |
Method Summary | |
---|---|
protected abstract void | addImpliedArgs(Vector args, boolean debug, boolean multithreaded, boolean exceptions, LinkType linkType, Boolean rtti, OptimizationEnum optimization) |
protected void | addIncludes(String baseDirPath, File[] includeDirs, Vector args, Vector relativeArgs, StringBuffer includePathId)
Adds command-line arguments for include directories.
|
protected abstract void | addWarningSwitch(Vector args, int warnings) |
protected void | buildDefineArguments(CompilerDef[] defs, Vector args) |
void | compile(CCTask task, File outputDir, String[] sourceFiles, String[] args, String[] endArgs, boolean relentless, CommandLineCompilerConfiguration config, ProgressMonitor monitor)
Compiles a source file.
|
protected CompilerConfiguration | createConfiguration(CCTask task, LinkType linkType, ProcessorDef[] baseDefs, CompilerDef specificDef, TargetDef targetPlatform, VersionInfo versionInfo) |
protected int | getArgumentCountPerInputFile() |
protected String | getCommand() |
protected abstract void | getDefineSwitch(StringBuffer buffer, String define, String value) |
protected abstract File[] | getEnvironmentIncludePath() |
String | getIdentifier() |
protected abstract String | getIncludeDirSwitch(String source) |
protected String | getInputFileArgument(File outputDir, String filename, int index) |
protected boolean | getLibtool() |
CommandLineCompiler | getLibtoolCompiler()
Obtains the same compiler, but with libtool set
Default behavior is to ignore libtool |
abstract int | getMaximumCommandLength() |
protected int | getMaximumInputFilesPerCommand() |
protected int | getTotalArgumentLengthForInputFile(File outputDir, String inputFile) |
protected abstract void | getUndefineSwitch(StringBuffer buffer, String define) |
protected int | runCommand(CCTask task, File workingDir, String[] cmdline)
This method is exposed so test classes can overload and test the
arguments without actually spawning the compiler |
protected void | setCommand(String command) |
Parameters: baseDirPath Base directory path. includeDirs Array of include directory paths args Vector of command line arguments used to execute the task relativeArgs Vector of command line arguments used to build the configuration identifier