diff options
author | Thomas Haller <thaller@redhat.com> | 2018-01-11 12:34:40 +0100 |
---|---|---|
committer | Thomas Haller <thaller@redhat.com> | 2018-01-11 12:46:01 +0100 |
commit | 34cb6f9877a9b7a7032899dbccca1def88da4191 (patch) | |
tree | e36cd40bbde4ae06d9f4225d3fb7b3ec7f115c20 /libnm-glib | |
parent | 98b46537fa1a91941b5f7a8252b3fce85554a855 (diff) |
build/meson: use variables for ldflags and linker-script
Diffstat (limited to 'libnm-glib')
-rw-r--r-- | libnm-glib/meson.build | 26 |
1 files changed, 11 insertions, 15 deletions
diff --git a/libnm-glib/meson.build b/libnm-glib/meson.build index 9ec79ca72..68ffcec4b 100644 --- a/libnm-glib/meson.build +++ b/libnm-glib/meson.build @@ -100,11 +100,7 @@ libnm_glib_vpn_enum = gnome.mkenums( deps = common_deps + [libnm_util_dep] -symbol_map = join_paths(meson.current_source_dir(), 'libnm-glib-vpn.ver') - -ldflags = [ - '-Wl,--version-script,@0@'.format(symbol_map), -] +linker_script = join_paths(meson.current_source_dir(), 'libnm-glib-vpn.ver') libnm_glib_vpn = shared_library( 'nm-glib-vpn', @@ -112,8 +108,10 @@ libnm_glib_vpn = shared_library( version: libnm_glib_vpn_version, dependencies: deps, c_args: cflags, - link_args: ldflags, - link_depends: symbol_map, + link_args: [ + '-Wl,--version-script,@0@'.format(linker_script), + ], + link_depends: linker_script, install: true ) @@ -192,11 +190,7 @@ deps = common_deps + [ libudev_dep ] -symbol_map = join_paths(meson.current_source_dir(), 'libnm-glib.ver') - -ldflags = [ - '-Wl,--version-script,@0@'.format(symbol_map), -] +linker_script = join_paths(meson.current_source_dir(), 'libnm-glib.ver') libnm_glib = shared_library( 'nm-glib', @@ -207,8 +201,10 @@ libnm_glib = shared_library( '-DNMRUNDIR="@0@"'.format(nm_pkgrundir), ], link_with: libdeprecated_nm_glib, - link_args: ldflags, - link_depends: symbol_map, + link_args: [ + '-Wl,--version-script,@0@'.format(linker_script), + ], + link_depends: linker_script, install: true ) @@ -273,7 +269,7 @@ executable( run_target( 'check-local-exports-' + libnm_glib_name, - command: [check_exports, libnm_glib.full_path(), symbol_map], + command: [check_exports, libnm_glib.full_path(), linker_script], depends: libnm_glib ) |