diff --git a/src/gallium/auxiliary/meson.build b/src/gallium/auxiliary/meson.build index cc9f592894b..35ad5247b4c 100644 --- a/src/gallium/auxiliary/meson.build +++ b/src/gallium/auxiliary/meson.build @@ -548,7 +548,7 @@ if with_tests ) endif -libgalliumvl_stub = static_library( +_libgalliumvl_stub = static_library( 'galliumvl_stub', 'vl/vl_stubs.c', c_args : [c_msvc_compat_args], @@ -570,6 +570,15 @@ libgalliumvl = static_library( build_by_default : false, ) +# some drivers export their screen creation function globally, so all frontends have to contain the +# full libgalliumvl. So we'll handle this here globally for everybody. +if (with_gallium_va or with_gallium_vdpau or with_gallium_omx != 'disabled' or + with_dri or with_gallium_radeonsi) + libgalliumvl_stub = libgalliumvl +else + libgalliumvl_stub = _libgalliumvl_stub +endif + # XXX: The dependencies here may be off... libgalliumvlwinsys = static_library( 'galliumvlwinsys', diff --git a/src/gallium/targets/d3dadapter9/meson.build b/src/gallium/targets/d3dadapter9/meson.build index 5f2ea8b0631..88df4708644 100644 --- a/src/gallium/targets/d3dadapter9/meson.build +++ b/src/gallium/targets/d3dadapter9/meson.build @@ -12,7 +12,7 @@ gallium_nine_link_depends = [] gallium_nine_link_with = [ libgallium, libnine_st, libpipe_loader_static, libws_null, libwsw, libswdri, - libswkmsdri, + libswkmsdri, libgalliumvl_stub, ] if with_ld_version_script @@ -20,13 +20,6 @@ if with_ld_version_script gallium_nine_link_depends += files('d3dadapter9.sym') endif -if (with_gallium_va or with_gallium_vdpau or with_gallium_omx != 'disabled' or - with_dri) - gallium_nine_link_with += libgalliumvl -else - gallium_nine_link_with += libgalliumvl_stub -endif - libgallium_nine = shared_library( 'd3dadapter9', files('description.c', 'getproc.c', 'drm.c'), diff --git a/src/gallium/targets/pipe-loader/meson.build b/src/gallium/targets/pipe-loader/meson.build index 943faec469d..48497fa9feb 100644 --- a/src/gallium/targets/pipe-loader/meson.build +++ b/src/gallium/targets/pipe-loader/meson.build @@ -20,19 +20,13 @@ pipe_loader_link_args = [ld_args_gc_sections, ld_args_build_id] pipe_loader_link_deps = [] -pipe_loader_link_with = [libgallium] +pipe_loader_link_with = [libgallium, libgalliumvl_stub] pipe_loader_comp_args = [] pipe_loader_incs = [ inc_include, inc_src, inc_util, inc_gallium, inc_gallium_drivers, inc_gallium_winsys, inc_gallium_aux, ] -if (with_gallium_va or with_gallium_vdpau or with_gallium_omx != 'disabled' or - with_dri or with_gallium_radeonsi) - pipe_loader_link_with += libgalliumvl -else - pipe_loader_link_with += libgalliumvl_stub -endif if (with_gallium_va or with_gallium_vdpau or with_gallium_omx != 'disabled') pipe_loader_link_with += libgalliumvlwinsys endif