mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2025-12-25 19:30:11 +01:00
meson: replace vk_wsi_args with dependencies to let meson take care of transitivity
Signed-off-by: Eric Engestrom <eric@igalia.com> Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com> Reviewed-by: Yonggang Luo <luoyonggang@gmail.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/19497>
This commit is contained in:
parent
f059213f5d
commit
fbd644c59d
19 changed files with 23 additions and 24 deletions
|
|
@ -196,7 +196,7 @@ libvulkan_radeon = shared_library(
|
|||
idep_vulkan_runtime, idep_amdgfxregs_h, idep_xmlconfig,
|
||||
idep_vulkan_common_entrypoints_h, idep_vulkan_wsi_entrypoints_h
|
||||
],
|
||||
c_args : [no_override_init_args, vk_wsi_args, radv_flags, c_msvc_compat_args],
|
||||
c_args : [no_override_init_args, radv_flags, c_msvc_compat_args],
|
||||
cpp_args : [radv_flags, cpp_msvc_compat_args],
|
||||
link_args : [
|
||||
ld_args_build_id, ld_args_bsymbolic, ld_args_gc_sections, libvulkan_radeon_ld_args,
|
||||
|
|
|
|||
|
|
@ -95,6 +95,7 @@ if with_dri2
|
|||
)
|
||||
files_egl += sha1_h
|
||||
deps_for_egl += idep_xmlconfig
|
||||
deps_for_egl += idep_vulkan_wsi_defines
|
||||
link_for_egl += libloader
|
||||
incs_for_egl += inc_loader
|
||||
incs_for_egl += inc_gallium
|
||||
|
|
@ -107,9 +108,6 @@ if with_dri2
|
|||
'drivers/dri2/platform_surfaceless.c',
|
||||
)
|
||||
|
||||
c_args_for_egl += vk_wsi_args
|
||||
cpp_args_for_egl += vk_wsi_args
|
||||
|
||||
if with_platform_x11
|
||||
files_egl += files('drivers/dri2/platform_x11.c')
|
||||
if with_dri3
|
||||
|
|
|
|||
|
|
@ -127,7 +127,7 @@ libvulkan_freedreno = shared_library(
|
|||
idep_vulkan_wsi,
|
||||
idep_mesautil,
|
||||
],
|
||||
c_args : [no_override_init_args, tu_flags, vk_wsi_args],
|
||||
c_args : [no_override_init_args, tu_flags],
|
||||
gnu_symbol_visibility : 'hidden',
|
||||
link_args : [ld_args_bsymbolic, ld_args_gc_sections, ld_args_build_id],
|
||||
install : true,
|
||||
|
|
|
|||
|
|
@ -98,9 +98,9 @@ libzink = static_library(
|
|||
link_args : [ld_args_build_id],
|
||||
dependencies: [
|
||||
idep_nir_headers, idep_mesautil, idep_vulkan_util_headers,
|
||||
idep_vulkan_util, dep_libdrm
|
||||
idep_vulkan_wsi_defines, idep_vulkan_util, dep_libdrm
|
||||
],
|
||||
c_args: [zink_c_args, vk_wsi_args],
|
||||
c_args: zink_c_args,
|
||||
)
|
||||
|
||||
driver_zink = declare_dependency(
|
||||
|
|
|
|||
|
|
@ -19,6 +19,7 @@
|
|||
# SOFTWARE.
|
||||
|
||||
inc_st_dri = include_directories('.')
|
||||
deps_for_libdri = []
|
||||
|
||||
files_libdri = files(
|
||||
'dri_context.c',
|
||||
|
|
@ -51,7 +52,7 @@ if with_gallium_zink and not with_platform_android
|
|||
libdri_c_args += '-DKOPPER_LIB_NAMES="libEGL and libGLX"'
|
||||
endif
|
||||
files_libdri += files('kopper.c')
|
||||
libdri_c_args += vk_wsi_args
|
||||
deps_for_libdri += idep_vulkan_wsi_defines
|
||||
endif
|
||||
|
||||
if with_gallium_softpipe
|
||||
|
|
@ -70,6 +71,7 @@ libdri = static_library(
|
|||
dependencies : [
|
||||
dep_libdrm,
|
||||
idep_mesautil,
|
||||
deps_for_libdri,
|
||||
],
|
||||
)
|
||||
|
||||
|
|
|
|||
|
|
@ -42,7 +42,7 @@ endif
|
|||
liblavapipe_st = static_library(
|
||||
'lavapipe_st',
|
||||
[liblvp_files, lvp_entrypoints, sha1_h],
|
||||
c_args : [ c_msvc_compat_args, lvp_flags, vk_wsi_args],
|
||||
c_args : [ c_msvc_compat_args, lvp_flags],
|
||||
gnu_symbol_visibility : 'hidden',
|
||||
include_directories : [ inc_include, inc_src, inc_util, inc_gallium, inc_compiler, inc_gallium_aux ],
|
||||
dependencies : [ dep_llvm, idep_nir, idep_mesautil, idep_vulkan_util, idep_vulkan_wsi,
|
||||
|
|
|
|||
|
|
@ -25,8 +25,9 @@ if not with_shared_glapi
|
|||
_c_args_wgl += '-D_GLAPI_NO_EXPORTS'
|
||||
endif
|
||||
|
||||
_wgl_deps = [idep_xmlconfig, driver_zink]
|
||||
if with_gallium_zink
|
||||
_c_args_wgl += vk_wsi_args
|
||||
_wgl_deps += idep_vulkan_wsi_defines
|
||||
endif
|
||||
|
||||
files_libwgl = files(
|
||||
|
|
@ -63,5 +64,5 @@ libwgl = static_library(
|
|||
include_directories : [
|
||||
inc_include, inc_src, inc_gallium, inc_gallium_aux, inc_mapi, inc_mesa,
|
||||
],
|
||||
dependencies : [idep_xmlconfig, driver_zink],
|
||||
dependencies : _wgl_deps,
|
||||
)
|
||||
|
|
|
|||
|
|
@ -39,6 +39,7 @@ incs_gbm = [
|
|||
if with_dri2
|
||||
files_gbm += files('backends/dri/gbm_dri.c', 'backends/dri/gbm_driint.h')
|
||||
deps_gbm += dep_libdrm # TODO: pthread-stubs
|
||||
deps_gbm += idep_vulkan_wsi_defines
|
||||
endif
|
||||
if with_platform_wayland
|
||||
deps_gbm += dep_wayland_server
|
||||
|
|
|
|||
|
|
@ -128,7 +128,6 @@ libglx = static_library(
|
|||
include_directories : [inc_include, inc_src, inc_mapi, inc_mesa, inc_gallium, inc_gallium_aux, inc_glapi, inc_loader],
|
||||
c_args : [
|
||||
'-DGL_LIB_NAME="lib@0@.so.@1@"'.format(gl_lib_name, gl_lib_version.split('.')[0]),
|
||||
vk_wsi_args
|
||||
],
|
||||
gnu_symbol_visibility : 'hidden',
|
||||
link_with : [
|
||||
|
|
@ -136,7 +135,7 @@ libglx = static_library(
|
|||
extra_libs_libglx,
|
||||
],
|
||||
dependencies : [
|
||||
idep_mesautil, idep_xmlconfig,
|
||||
idep_mesautil, idep_xmlconfig, idep_vulkan_wsi_defines,
|
||||
dep_libdrm, dep_dri2proto, dep_glproto, dep_x11, dep_glvnd, dep_xxf86vm, dep_xshmfence
|
||||
],
|
||||
)
|
||||
|
|
|
|||
|
|
@ -83,7 +83,6 @@ pvr_deps = [
|
|||
|
||||
pvr_flags = [
|
||||
no_override_init_args,
|
||||
vk_wsi_args,
|
||||
]
|
||||
|
||||
if with_imagination_srv
|
||||
|
|
|
|||
|
|
@ -25,7 +25,6 @@ inc_anv = include_directories('.')
|
|||
anv_flags = [
|
||||
no_override_init_args,
|
||||
c_sse2_args,
|
||||
vk_wsi_args,
|
||||
]
|
||||
|
||||
anv_cpp_flags = []
|
||||
|
|
|
|||
|
|
@ -139,7 +139,6 @@ anv_deps = [
|
|||
anv_flags = [
|
||||
no_override_init_args,
|
||||
c_sse2_args,
|
||||
vk_wsi_args,
|
||||
]
|
||||
|
||||
anv_cpp_flags = []
|
||||
|
|
|
|||
|
|
@ -85,7 +85,7 @@ libvulkan_dzn = shared_library(
|
|||
inc_compiler, inc_util
|
||||
],
|
||||
dependencies : [dzn_deps, idep_vulkan_wsi, idep_xmlconfig],
|
||||
c_args : [dzn_flags, vk_wsi_args],
|
||||
c_args : dzn_flags,
|
||||
cpp_args : dzn_cpp_flags,
|
||||
gnu_symbol_visibility : 'hidden',
|
||||
link_args : [ld_args_bsymbolic, ld_args_gc_sections],
|
||||
|
|
|
|||
|
|
@ -134,7 +134,7 @@ libvulkan_panfrost = shared_library(
|
|||
idep_vulkan_wsi,
|
||||
idep_mesautil,
|
||||
],
|
||||
c_args : [no_override_init_args, panvk_flags, vk_wsi_args],
|
||||
c_args : [no_override_init_args, panvk_flags],
|
||||
link_args : [ld_args_bsymbolic, ld_args_gc_sections],
|
||||
install : true,
|
||||
)
|
||||
|
|
|
|||
|
|
@ -82,7 +82,6 @@ vn_deps = [
|
|||
|
||||
vn_flags = [
|
||||
no_override_init_args,
|
||||
vk_wsi_args,
|
||||
]
|
||||
|
||||
vn_libs = []
|
||||
|
|
|
|||
|
|
@ -39,7 +39,7 @@ endif
|
|||
vklayer_mesa_device_select = shared_library(
|
||||
'VkLayer_MESA_device_select',
|
||||
vklayer_files,
|
||||
c_args : [no_override_init_args, vklayer_flags, vk_wsi_args],
|
||||
c_args : [no_override_init_args, vklayer_flags],
|
||||
gnu_symbol_visibility : 'hidden',
|
||||
dependencies : [
|
||||
idep_vulkan_util, idep_vulkan_wsi_headers, idep_mesautil, vklayer_deps,
|
||||
|
|
|
|||
|
|
@ -71,7 +71,10 @@ if host_machine.system() == 'darwin'
|
|||
vulkan_wsi_list += '-DVK_USE_PLATFORM_METAL_EXT'
|
||||
endif
|
||||
|
||||
vk_wsi_args = vulkan_wsi_list
|
||||
idep_vulkan_wsi_defines = declare_dependency(
|
||||
compile_args : vulkan_wsi_list,
|
||||
)
|
||||
vulkan_wsi_deps += idep_vulkan_wsi_defines
|
||||
|
||||
subdir('util')
|
||||
subdir('runtime')
|
||||
|
|
|
|||
|
|
@ -189,7 +189,7 @@ libvulkan_runtime = static_library(
|
|||
dependencies : vulkan_runtime_deps,
|
||||
# For glsl_type_singleton
|
||||
link_with : libcompiler,
|
||||
c_args : [c_msvc_compat_args, vk_wsi_args],
|
||||
c_args : c_msvc_compat_args,
|
||||
gnu_symbol_visibility : 'hidden',
|
||||
build_by_default : false,
|
||||
)
|
||||
|
|
|
|||
|
|
@ -60,8 +60,6 @@ wsi_entrypoints = custom_target(
|
|||
libvulkan_wsi = static_library(
|
||||
'vulkan_wsi',
|
||||
[files_vulkan_wsi, wsi_entrypoints],
|
||||
c_args: [vk_wsi_args],
|
||||
cpp_args: [vk_wsi_args],
|
||||
include_directories : [inc_include, inc_src, inc_gallium],
|
||||
dependencies : [
|
||||
vulkan_wsi_deps, dep_libdrm, dep_libudev, idep_vulkan_util_headers,
|
||||
|
|
@ -72,6 +70,7 @@ libvulkan_wsi = static_library(
|
|||
)
|
||||
|
||||
idep_vulkan_wsi_headers = declare_dependency(
|
||||
dependencies : idep_vulkan_wsi_defines,
|
||||
include_directories : include_directories('.')
|
||||
)
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue