aboutsummaryrefslogtreecommitdiff
path: root/meson.build
diff options
context:
space:
mode:
authorsghctoma <sghctoma@gmail.com>2018-09-26 18:13:28 +0200
committersghctoma <sghctoma@gmail.com>2018-09-26 18:13:28 +0200
commit57ce89668864ddad881de84e2780b5db301d12f2 (patch)
treedc280fa13d998a10a705fa064f8d3fcc20a8d32b /meson.build
parente47b8cd629f9378c74673cb577cc268667a71d1e (diff)
Add b_lundef=false Meson option on FreeBSD
The Meson option "b_lundef" need to be set to false on FreeBSD, because the symbol "environ" is in crt1.o, which is not linked with shared libraries. With Meson >=0.48.0 it is possible to set this option only for FreeBSD. This patch changes meson.build to do that.
Diffstat (limited to 'meson.build')
-rw-r--r--meson.build7
1 files changed, 7 insertions, 0 deletions
diff --git a/meson.build b/meson.build
index ff4e5e5f..bd6f1891 100644
--- a/meson.build
+++ b/meson.build
@@ -111,6 +111,12 @@ wlr_deps += [
math,
]
+if host_machine.system().startswith('freebsd')
+ override_options = ['b_lundef=false']
+else
+ override_options = []
+endif
+
symbols_file = 'wlroots.syms'
symbols_flag = '-Wl,--version-script,@0@/@1@'.format(meson.current_source_dir(), symbols_file)
lib_wlr = library(
@@ -122,6 +128,7 @@ lib_wlr = library(
install: true,
link_args : symbols_flag,
link_depends: symbols_file,
+ override_options: override_options,
)
wlroots = declare_dependency(