From 683d490074d93baa8a47db7ec43b7bd31145a12a Mon Sep 17 00:00:00 2001 From: Mark Donszelmann Date: Thu, 5 Nov 2009 23:00:15 +0100 Subject: Tar file expanded and committed --- .../cpptasks/compiler/CommandLineLinker.html | 920 +++++++++++++++++++++ 1 file changed, 920 insertions(+) create mode 100644 site/apidocs/net/sf/antcontrib/cpptasks/compiler/CommandLineLinker.html (limited to 'site/apidocs/net/sf/antcontrib/cpptasks/compiler/CommandLineLinker.html') diff --git a/site/apidocs/net/sf/antcontrib/cpptasks/compiler/CommandLineLinker.html b/site/apidocs/net/sf/antcontrib/cpptasks/compiler/CommandLineLinker.html new file mode 100644 index 0000000..0640e62 --- /dev/null +++ b/site/apidocs/net/sf/antcontrib/cpptasks/compiler/CommandLineLinker.html @@ -0,0 +1,920 @@ + + + + + + + +CommandLineLinker (cpptasks 1.0b5 API) + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + +
+ +

+ +net.sf.antcontrib.cpptasks.compiler +
+Class CommandLineLinker

+
+java.lang.Object
+  extended by net.sf.antcontrib.cpptasks.compiler.AbstractProcessor
+      extended by net.sf.antcontrib.cpptasks.compiler.AbstractLinker
+          extended by net.sf.antcontrib.cpptasks.compiler.CommandLineLinker
+
+
+
All Implemented Interfaces:
java.lang.Cloneable, Linker, Processor
+
+
+
Direct Known Subclasses:
AbstractArLibrarian, AbstractLdLinker, ADSLibrarian, ADSLinker, BorlandLibrarian, BorlandLinker, C89Linker, ClxxLibrarian, ClxxLinker, CompaqVisualFortranLibrarian, DevStudioCompatibleLibrarian, DevStudioCompatibleLinker, IccLinker, OpenWatcomLibrarian, OpenWatcomLinker, OS390Linker
+
+
+
+
public abstract class CommandLineLinker
extends AbstractLinker
+ + +

+An abstract Linker implementation that performs the link via an external + command. +

+ +

+

+
Author:
+
Adam Murdoch
+
+
+ +

+ + + + + + + +
+Field Summary
+ + + + + + + +
Fields inherited from class net.sf.antcontrib.cpptasks.compiler.AbstractProcessor
DEFAULT_DISCARD_BID, DEFAULT_PROCESS_BID
+  + + + + + + + + + + +
+Constructor Summary
CommandLineLinker(java.lang.String command, + java.lang.String identifierArg, + java.lang.String[] extensions, + java.lang.String[] ignoredExtensions, + java.lang.String outputSuffix, + boolean isLibtool, + CommandLineLinker libtoolLinker) + +
+          Creates a comand line linker invocation
+  + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+Method Summary
+protected abstract  voidaddBase(long base, + java.util.Vector args) + +
+           
+protected abstract  voidaddEntry(java.lang.String entry, + java.util.Vector args) + +
+           
+protected abstract  voidaddFixed(java.lang.Boolean fixed, + java.util.Vector args) + +
+           
+protected abstract  voidaddImpliedArgs(boolean debug, + LinkType linkType, + java.util.Vector args) + +
+           
+protected abstract  voidaddIncremental(boolean incremental, + java.util.Vector args) + +
+           
+protected  java.lang.String[]addLibrarySets(CCTask task, + LibrarySet[] libsets, + java.util.Vector preargs, + java.util.Vector midargs, + java.util.Vector endargs) + +
+           
+protected abstract  voidaddMap(boolean map, + java.util.Vector args) + +
+           
+protected abstract  voidaddStack(int stack, + java.util.Vector args) + +
+           
+protected  LinkerConfigurationcreateConfiguration(CCTask task, + LinkType linkType, + ProcessorDef[] baseDefs, + LinkerDef specificDef, + TargetDef targetPlatform, + VersionInfo versionInfo) + +
+           
+protected  java.lang.StringdecorateLinkerOption(java.lang.StringBuffer buf, + java.lang.String arg) + +
+          Allows drived linker to decorate linker option.
+protected  java.lang.StringgetCommand() + +
+           
+protected abstract  java.lang.StringgetCommandFileSwitch(java.lang.String commandFile) + +
+           
+ java.lang.StringgetIdentifier() + +
+          Retrieve an identifier that identifies the specific version of the + compiler.
+ CommandLineLinkergetLibtoolLinker() + +
+           
+protected abstract  intgetMaximumCommandLength() + +
+           
+ java.lang.String[]getOutputFileNames(java.lang.String baseName, + VersionInfo versionInfo) + +
+          Output file name (no path components) corresponding to source file
+protected  java.lang.String[]getOutputFileSwitch(CCTask task, + java.lang.String outputFile) + +
+           
+protected abstract  java.lang.String[]getOutputFileSwitch(java.lang.String outputFile) + +
+           
+protected  java.lang.StringgetStartupObject(LinkType linkType) + +
+           
+ voidlink(CCTask task, + java.io.File outputFile, + java.lang.String[] sourceFiles, + CommandLineLinkerConfiguration config) + +
+          Performs a link using a command line linker
+protected  java.lang.String[]prepareArguments(CCTask task, + java.lang.String outputDir, + java.lang.String outputFile, + java.lang.String[] sourceFiles, + CommandLineLinkerConfiguration config) + +
+          Prepares argument list for exec command.
+protected  java.lang.StringprepareFilename(java.lang.StringBuffer buf, + java.lang.String outputDir, + java.lang.String sourceFile) + +
+          Processes filename into argument form
+protected  java.lang.String[]prepareResponseFile(java.io.File outputFile, + java.lang.String[] args) + +
+          Prepares argument list to execute the linker using a + response file.
+protected  java.lang.StringquoteFilename(java.lang.StringBuffer buf, + java.lang.String filename) + +
+           
+protected  intrunCommand(CCTask task, + java.io.File workingDir, + java.lang.String[] cmdline) + +
+          This method is exposed so test classes can overload + and test the arguments without actually spawning the + compiler
+protected  voidsetCommand(java.lang.String command) + +
+           
+ + + + + + + +
Methods inherited from class net.sf.antcontrib.cpptasks.compiler.AbstractLinker
addVersionFiles, bid, changeEnvironment, createConfiguration, getLibraryKey
+ + + + + + + +
Methods inherited from class net.sf.antcontrib.cpptasks.compiler.AbstractProcessor
clone, getHeaderExtensions, getIdentifier, getOSArch, getOSName, getSourceExtensions, isDarwin, toString
+ + + + + + + +
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
+ + + + + + + +
Methods inherited from interface net.sf.antcontrib.cpptasks.compiler.Linker
getLibraryPath, getLibraryPatterns, getLinker, isCaseSensitive
+  +

+ + + + + + + + +
+Constructor Detail
+ +

+CommandLineLinker

+
+public CommandLineLinker(java.lang.String command,
+                         java.lang.String identifierArg,
+                         java.lang.String[] extensions,
+                         java.lang.String[] ignoredExtensions,
+                         java.lang.String outputSuffix,
+                         boolean isLibtool,
+                         CommandLineLinker libtoolLinker)
+
+
Creates a comand line linker invocation +

+

+ + + + + + + + +
+Method Detail
+ +

+addBase

+
+protected abstract void addBase(long base,
+                                java.util.Vector args)
+
+
+
+
+
+
+ +

+addFixed

+
+protected abstract void addFixed(java.lang.Boolean fixed,
+                                 java.util.Vector args)
+
+
+
+
+
+
+ +

+addImpliedArgs

+
+protected abstract void addImpliedArgs(boolean debug,
+                                       LinkType linkType,
+                                       java.util.Vector args)
+
+
+
+
+
+
+ +

+addIncremental

+
+protected abstract void addIncremental(boolean incremental,
+                                       java.util.Vector args)
+
+
+
+
+
+
+ +

+addLibrarySets

+
+protected java.lang.String[] addLibrarySets(CCTask task,
+                                            LibrarySet[] libsets,
+                                            java.util.Vector preargs,
+                                            java.util.Vector midargs,
+                                            java.util.Vector endargs)
+
+
+
+
+
+
+ +

+addMap

+
+protected abstract void addMap(boolean map,
+                               java.util.Vector args)
+
+
+
+
+
+
+ +

+addStack

+
+protected abstract void addStack(int stack,
+                                 java.util.Vector args)
+
+
+
+
+
+
+ +

+addEntry

+
+protected abstract void addEntry(java.lang.String entry,
+                                 java.util.Vector args)
+
+
+
+
+
+
+ +

+createConfiguration

+
+protected LinkerConfiguration createConfiguration(CCTask task,
+                                                  LinkType linkType,
+                                                  ProcessorDef[] baseDefs,
+                                                  LinkerDef specificDef,
+                                                  TargetDef targetPlatform,
+                                                  VersionInfo versionInfo)
+
+
+
Specified by:
createConfiguration in class AbstractLinker
+
+
+
+
+
+
+ +

+decorateLinkerOption

+
+protected java.lang.String decorateLinkerOption(java.lang.StringBuffer buf,
+                                                java.lang.String arg)
+
+
Allows drived linker to decorate linker option. + Override by GccLinker to prepend a "-Wl," to + pass option to through gcc to linker. +

+

+
Parameters:
buf - buffer that may be used and abused in the decoration process, + must not be null.
arg - linker argument
+
+
+
+ +

+getCommand

+
+protected final java.lang.String getCommand()
+
+
+
+
+
+
+ +

+getCommandFileSwitch

+
+protected abstract java.lang.String getCommandFileSwitch(java.lang.String commandFile)
+
+
+
+
+
+
+ +

+getIdentifier

+
+public java.lang.String getIdentifier()
+
+
Description copied from interface: Processor
+
Retrieve an identifier that identifies the specific version of the + compiler. Compilers with the same identifier should produce the same + output files for the same input files and command line switches. +

+

+
Specified by:
getIdentifier in interface Processor
Specified by:
getIdentifier in class AbstractProcessor
+
+
+
+
+
+
+ +

+getLibtoolLinker

+
+public final CommandLineLinker getLibtoolLinker()
+
+
+
+
+
+
+ +

+getMaximumCommandLength

+
+protected abstract int getMaximumCommandLength()
+
+
+
+
+
+
+ +

+getOutputFileNames

+
+public java.lang.String[] getOutputFileNames(java.lang.String baseName,
+                                             VersionInfo versionInfo)
+
+
Description copied from interface: Processor
+
Output file name (no path components) corresponding to source file +

+

+
Specified by:
getOutputFileNames in interface Processor
Specified by:
getOutputFileNames in class AbstractLinker
+
+
+
Parameters:
baseName - input file +
Returns:
output file name or null if no output file or name not + determined by input file
+
+
+
+ +

+getOutputFileSwitch

+
+protected java.lang.String[] getOutputFileSwitch(CCTask task,
+                                                 java.lang.String outputFile)
+
+
+
+
+
+
+ +

+getOutputFileSwitch

+
+protected abstract java.lang.String[] getOutputFileSwitch(java.lang.String outputFile)
+
+
+
+
+
+
+ +

+getStartupObject

+
+protected java.lang.String getStartupObject(LinkType linkType)
+
+
+
+
+
+
+ +

+link

+
+public void link(CCTask task,
+                 java.io.File outputFile,
+                 java.lang.String[] sourceFiles,
+                 CommandLineLinkerConfiguration config)
+          throws org.apache.tools.ant.BuildException
+
+
Performs a link using a command line linker +

+

+ +
Throws: +
org.apache.tools.ant.BuildException
+
+
+
+ +

+prepareArguments

+
+protected java.lang.String[] prepareArguments(CCTask task,
+                                              java.lang.String outputDir,
+                                              java.lang.String outputFile,
+                                              java.lang.String[] sourceFiles,
+                                              CommandLineLinkerConfiguration config)
+
+
Prepares argument list for exec command. Will return null + if command line would exceed allowable command line buffer. +

+

+
Parameters:
task - compilation task.
outputFile - linker output file
sourceFiles - linker input files (.obj, .o, .res)
config - linker configuration +
Returns:
arguments for runTask
+
+
+
+ +

+prepareFilename

+
+protected java.lang.String prepareFilename(java.lang.StringBuffer buf,
+                                           java.lang.String outputDir,
+                                           java.lang.String sourceFile)
+
+
Processes filename into argument form +

+

+
+
+
+
+ +

+prepareResponseFile

+
+protected java.lang.String[] prepareResponseFile(java.io.File outputFile,
+                                                 java.lang.String[] args)
+                                          throws java.io.IOException
+
+
Prepares argument list to execute the linker using a + response file. +

+

+
Parameters:
outputFile - linker output file
args - output of prepareArguments +
Returns:
arguments for runTask +
Throws: +
java.io.IOException
+
+
+
+ +

+quoteFilename

+
+protected java.lang.String quoteFilename(java.lang.StringBuffer buf,
+                                         java.lang.String filename)
+
+
+
+
+
+
+ +

+runCommand

+
+protected int runCommand(CCTask task,
+                         java.io.File workingDir,
+                         java.lang.String[] cmdline)
+                  throws org.apache.tools.ant.BuildException
+
+
This method is exposed so test classes can overload + and test the arguments without actually spawning the + compiler +

+

+ +
Throws: +
org.apache.tools.ant.BuildException
+
+
+
+ +

+setCommand

+
+protected final void setCommand(java.lang.String command)
+
+
+
+
+
+ +
+ + + + + + + + + + + + + + + + + + + +
+ +
+ + + +
+Copyright © 2001-2008 Ant-Contrib Project. All Rights Reserved. + + -- cgit v1.2.3