diff options
author | Víctor Manuel Jáquez Leal <vjaquez@igalia.com> | 2019-01-25 12:24:47 +0100 |
---|---|---|
committer | XinfengZhang <carl.zhang@intel.com> | 2019-03-04 23:02:01 -0800 |
commit | a99bab12713b67a3f9281b2945df53e7b23c830f (patch) | |
tree | d0c039a6c2821af6bc7de84b53923adc05693cee | |
parent | 16d32656d62132cb54969340d375c5e3ca51bd4f (diff) | |
download | libva-a99bab12713b67a3f9281b2945df53e7b23c830f.tar.gz |
build: meson: enables va messaging and visibility
This patch syncs with the defined compiler flags in autotools: the
enable of VA messaging and the compiler's support to visibility
attribute.
Fixes: #275
-rw-r--r-- | meson.build | 9 | ||||
-rw-r--r-- | meson_options.txt | 1 | ||||
-rw-r--r-- | va/meson.build | 2 |
3 files changed, 11 insertions, 1 deletions
diff --git a/meson.build b/meson.build index 1407354..b3270dd 100644 --- a/meson.build +++ b/meson.build @@ -108,6 +108,15 @@ if get_option('with_wayland') != 'no' WITH_WAYLAND = wayland_dep.found() endif +va_c_args = [] +if get_option('enable_va_messaging') + va_c_args += ['-DENABLE_VA_MESSAGING=1'] +endif + +# Symbol visibility +if cc.has_argument('-fvisibility=hidden') + va_c_args += ['-DHAVE_GNUC_VISIBILITY_ATTRIBUTE'] +endif if (not WITH_DRM and not WITH_X11 and not WITH_WAYLAND) error('Please install at least one backend dev files (DRM, X11, Wayland)') diff --git a/meson_options.txt b/meson_options.txt index 0f7261a..1f9a96f 100644 --- a/meson_options.txt +++ b/meson_options.txt @@ -4,3 +4,4 @@ option('with_x11', type : 'combo', choices : ['yes', 'no', 'auto'], value : 'aut option('with_glx', type : 'combo', choices : ['yes', 'no', 'auto'], value : 'auto') option('with_wayland', type : 'combo', choices : ['yes', 'no', 'auto'], value : 'auto') option('enable_docs', type : 'boolean', value : false) +option('enable_va_messaging', type : 'boolean', value : true) diff --git a/va/meson.build b/va/meson.build index b1dddd4..8c9d036 100644 --- a/va/meson.build +++ b/va/meson.build @@ -62,7 +62,7 @@ libva = shared_library( libva_headers_priv, soversion : libva_lt_current, version : libva_lt_version, - c_args : '-DVA_DRIVERS_PATH="' + driverdir + '"', + c_args : ['-DVA_DRIVERS_PATH="' + driverdir + '"'] + va_c_args, include_directories : configinc, link_args : '-Wl,-version-script,' + libva_sym_path, link_depends : libva_sym, |