diff options
| author | gingerBill <bill@gingerbill.org> | 2024-07-09 14:56:03 +0100 |
|---|---|---|
| committer | gingerBill <bill@gingerbill.org> | 2024-07-09 14:56:12 +0100 |
| commit | 4c1754b1dc3e13b0c1bb66c3859c4f7b2012b8cd (patch) | |
| tree | 17c9667bd1095fdc4baa259a98ecfdd6c5983b75 /src/cached.cpp | |
| parent | 666703f4301353a8bd435ae88fb698a350ac8e00 (diff) | |
`environ` is only for Linux
Diffstat (limited to 'src/cached.cpp')
| -rw-r--r-- | src/cached.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/cached.cpp b/src/cached.cpp index 553ac039f..2e5f838ef 100644 --- a/src/cached.cpp +++ b/src/cached.cpp @@ -246,11 +246,13 @@ gb_internal bool try_cached_build(Checker *c, Array<String> const &args) { } array_add(&envs, str); } - #else + #elif defined(GB_SYSTEM_LINUX) char **curr_env = environ; while (curr_env && *curr_env) { array_add(&envs, make_string_c(*curr_env++)); } + #else + // TODO(bill): environment variables on all other platforms #endif } array_sort(envs, string_cmp); |