Details
Description
The ninja tool looks at any output with a header file as generated source. However install edges have outputs with header files, and they get labeled as generated source. This can cause circular dependencies in a few edge cases, and should be a general improvement.
Possible fix is just checking for the "INSTALL" rule when determining if a file is generated source:
diff --git a/site_scons/site_tools/ninja.py b/site_scons/site_tools/ninja.py
|
index 5826be827f4..d621bb3ada0 100644 |
--- a/site_scons/site_tools/ninja.py
|
+++ b/site_scons/site_tools/ninja.py
|
@@ -664,7 +664,7 @@ class NinjaState: |
output
|
# First find builds which have header files in their outputs.
|
for build in self.builds.values() |
- if self.has_generated_sources(build["outputs"]) |
+ if build['rule'] != 'INSTALL' and self.has_generated_sources(build["outputs"]) |
for output in build["outputs"] |
# Collect only the header files from the builds with them
|
# in their output. We do this because is_generated_source |
Attachments
Issue Links
- is duplicated by
-
SERVER-44731 Make definition of generated sources configurable
-
- Closed
-
- is related to
-
SERVER-54914 Add Copy function action handler to ninja
-
- Closed
-