diff options
author | Paul Cristian Sarbu <paul.cristian.sarbu@huawei.com> | 2024-11-11 13:27:06 +0100 |
---|---|---|
committer | Maksim Denisov <denisov.maksim@huawei.com> | 2024-11-14 14:23:06 +0100 |
commit | c2a3ec54434d9f428d8f775ecbcc85c8ab88fae8 (patch) | |
tree | a78ac10f2cdd0cfc881477b017d05d976b7f5f5e /src/buildtool/system/system.cpp | |
parent | 94ed1751bc3054c53a197ac041d11ce80a0cf688 (diff) | |
download | justbuild-c2a3ec54434d9f428d8f775ecbcc85c8ab88fae8.tar.gz |
system: Implement IWYU suggestions
Diffstat (limited to 'src/buildtool/system/system.cpp')
-rw-r--r-- | src/buildtool/system/system.cpp | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/src/buildtool/system/system.cpp b/src/buildtool/system/system.cpp index 228c7806..ff057d85 100644 --- a/src/buildtool/system/system.cpp +++ b/src/buildtool/system/system.cpp @@ -14,15 +14,17 @@ #include "src/buildtool/system/system.hpp" -#include <array> -#include <cstdlib> -#include <string> - +#ifdef VALGRIND_BUILD #ifdef __unix__ #include <unistd.h> #else #error "Non-unix is not supported yet" -#endif +#endif // __unix__ +#include <array> +#include <string> +#else +#include <cstdlib> +#endif // VALGRIND_BUILD void System::ExitWithoutCleanup(int exit_code) { #ifdef VALGRIND_BUILD @@ -37,5 +39,5 @@ void System::ExitWithoutCleanup(int exit_code) { ::execvpe(args[0], args.data(), nullptr); #else std::_Exit(exit_code); -#endif +#endif // VALGRIND_BUILD } |