summaryrefslogtreecommitdiffstats
path: root/src/main/java/net/sf/antcontrib/cpptasks/compiler/CommandLineLinker.java
diff options
context:
space:
mode:
authorSven Gothel <[email protected]>2019-12-10 18:40:13 +0100
committerSven Gothel <[email protected]>2019-12-10 18:40:13 +0100
commite1933c74b9c256332cd12c9a1094e4687b535112 (patch)
tree193b22c456bce70b91d48ac8a5815408c3ddb15b /src/main/java/net/sf/antcontrib/cpptasks/compiler/CommandLineLinker.java
parent6bdee37988009d3006ccf99bac1ccea497141afd (diff)
Bug 1417 Android clang support: Introduce clangLinkerOption '-target <abi>'
Also move isGCC and new isCLANG to CommandLineLinker
Diffstat (limited to 'src/main/java/net/sf/antcontrib/cpptasks/compiler/CommandLineLinker.java')
-rw-r--r--src/main/java/net/sf/antcontrib/cpptasks/compiler/CommandLineLinker.java14
1 files changed, 13 insertions, 1 deletions
diff --git a/src/main/java/net/sf/antcontrib/cpptasks/compiler/CommandLineLinker.java b/src/main/java/net/sf/antcontrib/cpptasks/compiler/CommandLineLinker.java
index 8b8ff89..321bd29 100644
--- a/src/main/java/net/sf/antcontrib/cpptasks/compiler/CommandLineLinker.java
+++ b/src/main/java/net/sf/antcontrib/cpptasks/compiler/CommandLineLinker.java
@@ -53,6 +53,8 @@ public abstract class CommandLineLinker extends AbstractLinker
private final CommandLineLinker libtoolLinker;
private final boolean newEnvironment = false;
private final String outputSuffix;
+ private final boolean isGCC;
+ private final boolean isCLANG;
/** Creates a comand line linker invocation
@@ -70,6 +72,8 @@ public abstract class CommandLineLinker extends AbstractLinker
this.isLibtool = isLibtool;
this.isXcoderun = isXCoderun;
this.libtoolLinker = libtoolLinker;
+ isGCC = "gcc".equals(command);
+ isCLANG = "clang".equals(command);
}
public CommandLineLinker(final CommandLineLinker ld, final boolean isXCoderun) {
super(ld);
@@ -79,6 +83,8 @@ public abstract class CommandLineLinker extends AbstractLinker
this.isLibtool = ld.isLibtool;
this.isXcoderun = isXCoderun;
this.libtoolLinker = ld.libtoolLinker;
+ isGCC = "gcc".equals(command);
+ isCLANG = "clang".equals(command);
}
protected abstract void addBase(long base, Vector args);
@@ -243,9 +249,15 @@ public abstract class CommandLineLinker extends AbstractLinker
protected final boolean getLibtool() {
return isLibtool;
}
- protected final boolean getXcodeRun() {
+ protected final boolean isXcodeRun() {
return isXcoderun;
}
+ protected final boolean isGCC() {
+ return isGCC;
+ }
+ protected final boolean isCLANG() {
+ return isCLANG;
+ }
/**
* Performs a link using a command line linker
*