summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThibault Saunier <thibault.saunier@osg.samsung.com>2017-06-23 12:36:38 -0400
committerMatthias Clasen <mclasen@redhat.com>2017-07-13 19:03:39 -0400
commit0689231bd61f86190688cc262fcc3058cb672557 (patch)
tree818059bbb865dc74043862bf62337e9019f77db7
parenteb2196e89d1700941b35c604bf6b657660b3b2c8 (diff)
downloadglib-0689231bd61f86190688cc262fcc3058cb672557.tar.gz
meson: Fix the build defining HAVE_RTLD_X
Otherwise RTLD_XXX get redefined. https://bugzilla.gnome.org/show_bug.cgi?id=784133
-rw-r--r--config.h.meson3
-rw-r--r--meson.build12
2 files changed, 15 insertions, 0 deletions
diff --git a/config.h.meson b/config.h.meson
index 7346b9254..a3d090e7b 100644
--- a/config.h.meson
+++ b/config.h.meson
@@ -796,3 +796,6 @@
#mesondefine MAJOR_IN_MKDEV
#mesondefine MAJOR_IN_SYSMACROS
+#mesondefine HAVE_RTLD_LAZY
+#mesondefine HAVE_RTLD_NOW
+#mesondefine HAVE_RTLD_GLOBAL
diff --git a/meson.build b/meson.build
index 892a7ce6a..993899113 100644
--- a/meson.build
+++ b/meson.build
@@ -369,6 +369,18 @@ elif cc.has_header_symbol('sys/mkdev.h', 'major')
glib_conf.set('MAJOR_IN_MKDEV', 1)
endif
+if cc.has_header_symbol('dlfcn.h', 'RTLD_LAZY')
+ glib_conf.set('HAVE_RTLD_LAZY', 1)
+endif
+
+if cc.has_header_symbol('dlfcn.h', 'RTLD_NOW')
+ glib_conf.set('HAVE_RTLD_NOW', 1)
+endif
+
+if cc.has_header_symbol('dlfcn.h', 'RTLD_GLOBAL')
+ glib_conf.set('HAVE_RTLD_GLOBAL', 1)
+endif
+
# Check whether to use statfs or statvfs
# Some systems have both statfs and statvfs, pick the most "native" for these
if have_func_statfs and have_func_statvfs