diff options
Diffstat (limited to 'src/cmake')
-rw-r--r-- | src/cmake/syscall.cmake (renamed from src/cmake/memfd.cmake) | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/src/cmake/memfd.cmake b/src/cmake/syscall.cmake index ca499c459ab..1e0a559b5df 100644 --- a/src/cmake/memfd.cmake +++ b/src/cmake/syscall.cmake @@ -24,3 +24,13 @@ if (HAVE_MEMFD_CREATE) add_definitions(-DHAVE_MEMFD_CREATE) endif() +check_c_source_compiles(" + #define _GNU_SOURCE + #include <sched.h> + int main() { return getcpu (0, 0); } +" HAVE_GETCPU) + +if (HAVE_GETCPU) + add_definitions(-DHAVE_GETCPU) +endif() + |