From aa29434a2feebc8925307372c27a5f56021620fc Mon Sep 17 00:00:00 2001 From: Boris Kolpackov Date: Thu, 14 Apr 2022 14:43:43 +0200 Subject: Add header cache to cc::compile_rule::enter_header() --- libbuild2/dyndep.cxx | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'libbuild2/dyndep.cxx') diff --git a/libbuild2/dyndep.cxx b/libbuild2/dyndep.cxx index 727a28c..55b02ed 100644 --- a/libbuild2/dyndep.cxx +++ b/libbuild2/dyndep.cxx @@ -389,6 +389,9 @@ namespace build2 const function& get_pfx_map, const dyndep_rule::srcout_map& so_map) { + // NOTE: see enter_header() caching logic if changing anyting here with + // regards to the target and base scope usage. + // Find or maybe insert the target. The directory is only moved from if // insert is true. Note that it must be normalized. // @@ -561,6 +564,9 @@ namespace build2 // Note: we now always use absolute path to the translation unit so this // no longer applies. But let's keep it for posterity. // + // Also note that we now assume (see cc::compile_rule::enter_header()) a + // relative path signifies a generated header. + // #if 0 if (f.relative () && rels.relative ()) { @@ -590,7 +596,7 @@ namespace build2 const file* pt (nullptr); bool remapped (false); - // If still relative then it does not exist. + // If relative then it does not exist. // if (fp.relative ()) { -- cgit v1.1