summaryrefslogtreecommitdiff
path: root/meson.build
diff options
context:
space:
mode:
authorCarlos Soriano <csoriano@gnome.org>2018-06-09 17:58:46 +0200
committerCarlos Soriano <csoriano1618@gmail.com>2018-06-12 09:14:45 +0000
commit09f00407eb38d25f36204e4db8004cedbda102fd (patch)
tree9194f8d831e3a83140a66a915177d1c77c56fea9 /meson.build
parent41ab60dfa00c72fc787d8b09edf6679728ebb1d8 (diff)
downloadnautilus-09f00407eb38d25f36204e4db8004cedbda102fd.tar.gz
Meson: Make sure _GNU_SOURCE is set
_GNU_SOURCE is required to be able to use POSIX functions that are not available on non-Linux system. Specifically, we use sys/types for requesting user accounts with getpwent and similars. Usually systems seems to compile with this set, however some systems like RHEL doesn't assume it so. Since this is more correct to set it explicitly, this commit does that by passing an argument to meson project.
Diffstat (limited to 'meson.build')
-rw-r--r--meson.build4
1 files changed, 2 insertions, 2 deletions
diff --git a/meson.build b/meson.build
index 784a6f714..7bbf38b8f 100644
--- a/meson.build
+++ b/meson.build
@@ -40,6 +40,7 @@ add_project_arguments(
'-Werror=undef',
'-Werror=uninitialized',
]),
+ '-D_GNU_SOURCE',
language: 'c'
)
@@ -129,7 +130,6 @@ conf.set_quoted('NAME_SUFFIX', name_suffix)
#
# gnome-desktop macros for thumbnailer sandboxing.
####################################
-conf.set10('_GNU_SOURCE', true) # `man user_namespaces` /CLONE_NEWUSER
if is_linux
conf.set10('ENABLE_SECCOMP', true)
conf.set10('HAVE_BWRAP', true)
@@ -181,4 +181,4 @@ if get_option('extensions')
endif
# Compile GSettings schemas when installing from source.
-meson.add_install_script('build-aux/meson/postinstall.py')
+meson.add_install_script('build-aux/meson/postinstall.py') \ No newline at end of file