meson: update header file to detect memfd_create()
authorYu Watanabe <watanabe.yu+github@gmail.com>
Sat, 25 Nov 2017 17:17:06 +0000 (02:17 +0900)
committerYu Watanabe <watanabe.yu+github@gmail.com>
Sat, 25 Nov 2017 17:17:06 +0000 (02:17 +0900)
meson.build

index fd38923..af7a914 100644 (file)
@@ -442,7 +442,8 @@ foreach ident : ['secure_getenv', '__secure_getenv']
 endforeach
 
 foreach ident : [
-        ['memfd_create',      '''#include <sys/memfd.h>'''],
+        ['memfd_create',      '''#define _GNU_SOURCE
+                                 #include <sys/mman.h>'''],
         ['gettid',            '''#include <sys/types.h>'''],
         ['pivot_root',        '''#include <stdlib.h>'''],     # no known header declares pivot_root
         ['name_to_handle_at', '''#define _GNU_SOURCE