aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/main/java/com/google/devtools/build/lib
diff options
context:
space:
mode:
authorGravatar Manuel Klimek <klimek@google.com>2015-03-20 16:52:31 +0000
committerGravatar Damien Martin-Guillerez <dmarting@google.com>2015-03-23 11:54:06 +0000
commitfde7137e9f6bc734a9cb9fad025a09e43ad5a2c2 (patch)
tree4156a4afb29293f16b0d28f6988fda735929dcaa /src/main/java/com/google/devtools/build/lib
parent5df6cb34827ae3773a27199b290980fb241e65a5 (diff)
Add C++ flags to C++ linkstamp compiles.
In the future, we will have linkstamp flags be generated by the crosstool feature configuration, just like normal compile actions. -- MOS_MIGRATED_REVID=89131127
Diffstat (limited to 'src/main/java/com/google/devtools/build/lib')
-rw-r--r--src/main/java/com/google/devtools/build/lib/rules/cpp/LinkCommandLine.java3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/main/java/com/google/devtools/build/lib/rules/cpp/LinkCommandLine.java b/src/main/java/com/google/devtools/build/lib/rules/cpp/LinkCommandLine.java
index 1dccafa8cc..99568c94a6 100644
--- a/src/main/java/com/google/devtools/build/lib/rules/cpp/LinkCommandLine.java
+++ b/src/main/java/com/google/devtools/build/lib/rules/cpp/LinkCommandLine.java
@@ -542,6 +542,9 @@ public final class LinkCommandLine extends CommandLine {
optionList.addAll(cppConfiguration.getCompilerOptions(features));
optionList.addAll(cppConfiguration.getCOptions());
optionList.addAll(cppConfiguration.getUnfilteredCompilerOptions(features));
+ if (CppFileTypes.CPP_SOURCE.matches(linkstamp.getKey().getExecPath())) {
+ optionList.addAll(cppConfiguration.getCxxOptions(features));
+ }
// For dynamic libraries, produce position independent code.
if (linkTargetType == LinkTargetType.DYNAMIC_LIBRARY