File tree Expand file tree Collapse file tree 3 files changed +4
-5
lines changed Expand file tree Collapse file tree 3 files changed +4
-5
lines changed Original file line number Diff line number Diff line change @@ -21,7 +21,6 @@ if (ANDROID OR CYGWIN OR CMAKE_SYSTEM_NAME MATCHES "AIX|DragonFly|FreeBSD|Haiku|
2121 set (HAVE_MACH_MACH_H 0)
2222 set (HAVE_MALLOC_MALLOC_H 0)
2323 set (HAVE_PTHREAD_H 1)
24- set (HAVE_SYS_AUXV_H 1)
2524 set (HAVE_SYS_MMAN_H 1)
2625 set (HAVE_SYSEXITS_H 1)
2726 set (HAVE_UNISTD_H 1)
5352 check_include_file(mach/mach.h HAVE_MACH_MACH_H)
5453 check_include_file(malloc/malloc.h HAVE_MALLOC_MALLOC_H)
5554 check_include_file(pthread.h HAVE_PTHREAD_H)
56- check_include_file(sys/auxv.h HAVE_SYS_AUXV_H)
5755 check_include_file(sys/mman.h HAVE_SYS_MMAN_H)
5856 check_include_file(sysexits.h HAVE_SYSEXITS_H)
5957 check_include_file(unistd.h HAVE_UNISTD_H)
@@ -321,6 +319,7 @@ check_symbol_exists(getrusage sys/resource.h HAVE_GETRUSAGE)
321319check_symbol_exists(isatty unistd.h HAVE_ISATTY)
322320check_symbol_exists(futimens sys/stat.h HAVE_FUTIMENS)
323321check_symbol_exists(futimes sys/time.h HAVE_FUTIMES)
322+ check_symbol_exists(getauxval sys/auxv.h HAVE_GETAUXVAL)
324323# AddressSanitizer conflicts with lib/Support/Unix/Signals.inc
325324# Avoid sigaltstack on Apple platforms, where backtrace() cannot handle it
326325# (rdar://7089625) and _Unwind_Backtrace is unusable because it cannot unwind
Original file line number Diff line number Diff line change 295295
296296#cmakedefine HAVE_BUILTIN_THREAD_POINTER ${HAVE_BUILTIN_THREAD_POINTER}
297297
298- #cmakedefine HAVE_SYS_AUXV_H ${HAVE_SYS_AUXV_H }
298+ #cmakedefine HAVE_GETAUXVAL ${HAVE_GETAUXVAL }
299299
300300#endif
Original file line number Diff line number Diff line change 3131#ifdef HAVE_MALLOC_MALLOC_H
3232#include < malloc/malloc.h>
3333#endif
34- #ifdef HAVE_SYS_AUXV_H
34+ #ifdef HAVE_GETAUXVAL
3535#include < sys/auxv.h>
3636#endif
3737
@@ -66,7 +66,7 @@ Process::Pid Process::getProcessId() {
6666// On Cygwin, getpagesize() returns 64k(AllocationGranularity) and
6767// offset in mmap(3) should be aligned to the AllocationGranularity.
6868Expected<unsigned > Process::getPageSize () {
69- #if defined(HAVE_SYS_AUXV_H )
69+ #if defined(HAVE_GETAUXVAL )
7070 static const int page_size = ::getauxval (AT_PAGESZ);
7171#elif defined(HAVE_GETPAGESIZE)
7272 static const int page_size = ::getpagesize ();
You can’t perform that action at this time.
0 commit comments