[llvm] 3d54619 - [gn build] Fix D126415 to only set `llvm_have_mallinfo2 = true` on linux
Arthur Eubanks via llvm-commits
llvm-commits at lists.llvm.org
Wed May 25 14:49:05 PDT 2022
Author: Arthur Eubanks
Date: 2022-05-25T14:48:56-07:00
New Revision: 3d546191ad9d7d2ad2c7928204b9de51deafa675
URL: https://github.com/llvm/llvm-project/commit/3d546191ad9d7d2ad2c7928204b9de51deafa675
DIFF: https://github.com/llvm/llvm-project/commit/3d546191ad9d7d2ad2c7928204b9de51deafa675.diff
LOG: [gn build] Fix D126415 to only set `llvm_have_mallinfo2 = true` on linux
Otherwise mac builds are broken, e.g. http://45.33.8.238/macm1/36056/step_4.txt
../../llvm/lib/Support/Unix/Process.inc:35:10: fatal error: 'malloc.h' file not found
#include <malloc.h>
Added:
Modified:
llvm/utils/gn/secondary/llvm/include/llvm/Config/BUILD.gn
Removed:
################################################################################
diff --git a/llvm/utils/gn/secondary/llvm/include/llvm/Config/BUILD.gn b/llvm/utils/gn/secondary/llvm/include/llvm/Config/BUILD.gn
index 82eba6b7e552..c60044b03049 100644
--- a/llvm/utils/gn/secondary/llvm/include/llvm/Config/BUILD.gn
+++ b/llvm/utils/gn/secondary/llvm/include/llvm/Config/BUILD.gn
@@ -50,7 +50,7 @@ declare_args() {
# glibc is at least 2.33 which has mallinfo2.
# TODO: remove this once nobody using the gn build is building against an old glibc.
- llvm_have_mallinfo2 = true
+ llvm_have_mallinfo2 = current_os == "linux"
}
write_cmake_config("abi-breaking") {
More information about the llvm-commits
mailing list