aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/main/java/com/google/devtools/build/lib/rules/cpp/CcBinary.java
diff options
context:
space:
mode:
authorGravatar Manuel Klimek <klimek@google.com>2015-02-18 16:32:44 +0000
committerGravatar Han-Wen Nienhuys <hanwen@google.com>2015-02-18 16:32:44 +0000
commitcbe004a0f76e60081b9fd0112e325a2f9d3d86cc (patch)
tree329c4e45ff16f203df617c12e31345e1a33e7f78 /src/main/java/com/google/devtools/build/lib/rules/cpp/CcBinary.java
parentc2d48bec0d025d1aedf2c1f8d8f042eb14cabc52 (diff)
Fix layering_check with cc_fake_binary / no-compile tests.
A cc_fake_binary needs all additional artifacts referenced in the compile command line in its runfiles tree. RELNOTES: Fix layering_check with cc_fake_binary. -- MOS_MIGRATED_REVID=86596049
Diffstat (limited to 'src/main/java/com/google/devtools/build/lib/rules/cpp/CcBinary.java')
-rw-r--r--src/main/java/com/google/devtools/build/lib/rules/cpp/CcBinary.java3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/main/java/com/google/devtools/build/lib/rules/cpp/CcBinary.java b/src/main/java/com/google/devtools/build/lib/rules/cpp/CcBinary.java
index 6efcd9daeb..b0882c677d 100644
--- a/src/main/java/com/google/devtools/build/lib/rules/cpp/CcBinary.java
+++ b/src/main/java/com/google/devtools/build/lib/rules/cpp/CcBinary.java
@@ -137,6 +137,9 @@ public abstract class CcBinary implements RuleConfiguredTargetFactory {
builder.addSymlinksToArtifacts(
Iterables.transform(common.getCAndCppSources(), Pair.<Artifact, Label>firstFunction()));
builder.addSymlinksToArtifacts(cppCompilationContext.getDeclaredIncludeSrcs());
+ // Add additional files that are referenced from the compile command, like module maps
+ // or header modules.
+ builder.addSymlinksToArtifacts(cppCompilationContext.getAdditionalInputs());
}
return builder.build();
}