Skip to content

Commit

Permalink
meson.build: add vulkan dependency
Browse files Browse the repository at this point in the history
  • Loading branch information
sinsanction committed Mar 24, 2024
1 parent 74b8ae3 commit 4048e6b
Showing 1 changed file with 23 additions and 2 deletions.
25 changes: 23 additions & 2 deletions meson.build
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,21 @@ project('vs-placebo', ['c', 'cpp'],

win32 = host_machine.system() == 'windows' or host_machine.system() == 'cygwin'

placebo = dependency('libplacebo', required: true, version: '>=5.229.0', static: win32)
libplacebo_default_options = [
'default_library=static',
'vulkan=enabled',
'opengl=disabled',
'd3d11=disabled',
'glslang=enabled',
'shaderc=enabled',
'lcms=enabled',
'demos=false',
]
if win32
libplacebo_default_options += ['shaderc=enabled']
endif

placebo = dependency('libplacebo', default_options: libplacebo_default_options, required: true, version: '>=5.229.0', static: win32)
dovi = dependency('dovi', required: false)

use_dovi = dovi.found()
Expand All @@ -25,8 +39,15 @@ sources = []

subdir('src')

if win32
subdir('vulkan')
vulkan = declare_dependency(link_args: 'vulkan/libvulkan-1.a')
else
vulkan = declare_dependency()
endif

shared_module('vs_placebo', sources,
dependencies: [placebo, dovi],
dependencies: [placebo, vulkan, dovi],
link_with: [p2p],
name_prefix: 'lib',
install: true
Expand Down

0 comments on commit 4048e6b

Please sign in to comment.