aboutsummaryrefslogtreecommitdiff
path: root/libbuild2/cc/guess.hxx
diff options
context:
space:
mode:
authorBoris Kolpackov <boris@codesynthesis.com>2021-04-22 10:10:34 +0200
committerBoris Kolpackov <boris@codesynthesis.com>2021-04-22 10:10:34 +0200
commit40863a594372ede117533d5c0970a96d60e34371 (patch)
treece5b481ebb443c75161d5866dc6a4207df9a766c /libbuild2/cc/guess.hxx
parent1ac5458eede2b4b2d3bc98cde787348f70328361 (diff)
Incorporate project environment checksum into cc::compiler_info cache key
Diffstat (limited to 'libbuild2/cc/guess.hxx')
-rw-r--r--libbuild2/cc/guess.hxx4
1 files changed, 4 insertions, 0 deletions
diff --git a/libbuild2/cc/guess.hxx b/libbuild2/cc/guess.hxx
index 6bab649..0180c97 100644
--- a/libbuild2/cc/guess.hxx
+++ b/libbuild2/cc/guess.hxx
@@ -173,6 +173,9 @@ namespace build2
// search paths (similar to the PATH environment variable), in which case
// it will end with a directory separator but will not contain '*'.
//
+ // Watch out for the environment variables affecting any of the extracted
+ // information (like sys_*_dirs) since we cache it.
+ //
struct compiler_info
{
process_path path;
@@ -252,6 +255,7 @@ namespace build2
const compiler_info&
guess (const char* xm, // Module (for var names in diagnostics).
lang xl, // Language.
+ const string& ec, // Environment checksum.
const path& xc, // Compiler path.
const string* xi, // Compiler id (optional).
const string* xv, // Compiler version (optional).