diff options
author | Julian Büning <julian.buening@rwth-aachen.de> | 2018-06-16 17:05:24 +0200 |
---|---|---|
committer | MartinNowack <martin.nowack@gmail.com> | 2018-07-02 17:30:55 +0100 |
commit | 418184ca8e35d6ced451d97fdcdda5b42ad14194 (patch) | |
tree | f978b6bf5a27ad75345d7960407c36ccd54ebb4d /lib | |
parent | 4c15d279e4d92b204275e973f2cedb76f63b0ac3 (diff) | |
download | klee-418184ca8e35d6ced451d97fdcdda5b42ad14194.tar.gz |
CMake: check for ctype and mallinfo functions with CXX instead of C compiler
Diffstat (limited to 'lib')
-rw-r--r-- | lib/Support/MemoryUsage.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/Support/MemoryUsage.cpp b/lib/Support/MemoryUsage.cpp index f1757ad3..2f62dc80 100644 --- a/lib/Support/MemoryUsage.cpp +++ b/lib/Support/MemoryUsage.cpp @@ -18,7 +18,7 @@ #ifdef HAVE_MALLINFO #include <malloc.h> #endif -#ifdef HAVE_MALLOC_MALLOC_H +#ifdef HAVE_MALLOC_ZONE_STATISTICS #include <malloc/malloc.h> #endif @@ -95,7 +95,7 @@ size_t util::GetTotalMallocUsage() { MallocExtension::instance()->GetNumericProperty( "generic.current_allocated_bytes", &value); return value; -#elif HAVE_MALLINFO +#elif defined(HAVE_MALLINFO) struct mallinfo mi = ::mallinfo(); // The malloc implementation in glibc (pmalloc2) // does not include mmap()'ed memory in mi.uordblks @@ -106,7 +106,7 @@ size_t util::GetTotalMallocUsage() { return (unsigned)mi.uordblks; #endif -#elif defined(HAVE_MALLOC_ZONE_STATISTICS) && defined(HAVE_MALLOC_MALLOC_H) +#elif defined(HAVE_MALLOC_ZONE_STATISTICS) // Support memory usage on Darwin. malloc_statistics_t Stats; |