aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/main
diff options
context:
space:
mode:
authorGravatar Dmitry Shevchenko <dmishe@google.com>2016-11-29 18:52:25 +0000
committerGravatar Kristina Chodorow <kchodorow@google.com>2016-11-29 19:56:33 +0000
commit873c259abc01b84524cc4280f0f8ddd5a4e90e62 (patch)
treec16bb33457052ddaebcc0d5e2cf8f119f625c584 /src/main
parented7ced0018dc5c5ebd6fc8afc7158037ac1df00d (diff)
Remove private headers from modulemaps generated by objc_ targets
-- MOS_MIGRATED_REVID=140498934
Diffstat (limited to 'src/main')
-rw-r--r--src/main/java/com/google/devtools/build/lib/rules/objc/CompilationSupport.java12
1 files changed, 4 insertions, 8 deletions
diff --git a/src/main/java/com/google/devtools/build/lib/rules/objc/CompilationSupport.java b/src/main/java/com/google/devtools/build/lib/rules/objc/CompilationSupport.java
index efa6b1df2c..3722572f7f 100644
--- a/src/main/java/com/google/devtools/build/lib/rules/objc/CompilationSupport.java
+++ b/src/main/java/com/google/devtools/build/lib/rules/objc/CompilationSupport.java
@@ -452,15 +452,14 @@ public abstract class CompilationSupport {
Optional<CompilationArtifacts> compilationArtifacts) {
// TODO(bazel-team): Include textual headers in the module map when Xcode 6 support is
// dropped.
+ // TODO(b/32225593): Include private headers in the module map.
Iterable<Artifact> publicHeaders = attributes.hdrs();
- Iterable<Artifact> privateHeaders = ImmutableList.of();
if (compilationArtifacts.isPresent()) {
CompilationArtifacts artifacts = compilationArtifacts.get();
publicHeaders = Iterables.concat(publicHeaders, artifacts.getAdditionalHdrs());
- privateHeaders = Iterables.concat(privateHeaders, artifacts.getPrivateHdrs());
}
CppModuleMap moduleMap = intermediateArtifacts.moduleMap();
- registerGenerateModuleMapAction(moduleMap, publicHeaders, privateHeaders);
+ registerGenerateModuleMapAction(moduleMap, publicHeaders);
return this;
}
@@ -869,20 +868,17 @@ public abstract class CompilationSupport {
/**
* Registers an action that will generate a clang module map.
- *
* @param moduleMap the module map to generate
* @param publicHeaders the headers that should be directly accessible by dependers
- * @param privateHeaders the headers that should only be directly accessible by this module
*/
private void registerGenerateModuleMapAction(
- CppModuleMap moduleMap, Iterable<Artifact> publicHeaders, Iterable<Artifact> privateHeaders) {
+ CppModuleMap moduleMap, Iterable<Artifact> publicHeaders) {
publicHeaders = Iterables.filter(publicHeaders, MODULE_MAP_HEADER);
- privateHeaders = Iterables.filter(privateHeaders, MODULE_MAP_HEADER);
ruleContext.registerAction(
new CppModuleMapAction(
ruleContext.getActionOwner(),
moduleMap,
- privateHeaders,
+ ImmutableList.<Artifact>of(),
publicHeaders,
attributes.moduleMapsForDirectDeps(),
ImmutableList.<PathFragment>of(),