meson: Migrate genconfig submodule to subproject

This commit is contained in:
Matt Borgerson 2025-01-06 15:57:16 -07:00
parent fcf5eb84a1
commit 21a3ee89ba
6 changed files with 11 additions and 14 deletions

3
.gitmodules vendored
View File

@ -43,6 +43,3 @@
[submodule "tests/lcitool/libvirt-ci"]
path = tests/lcitool/libvirt-ci
url = https://gitlab.com/libvirt/libvirt-ci.git
[submodule "genconfig"]
path = genconfig
url = https://github.com/mborgerson/genconfig.git

@ -1 +0,0 @@
Subproject commit 44bab849ce87fceafd74703bfcf2b61a1a1b738f

View File

@ -2336,8 +2336,6 @@ if vulkan.found()
dependencies: vulkan)
endif
genconfig = declare_dependency(include_directories: 'genconfig')
openssl = dependency('openssl', method: 'pkg-config', required: true)
if host_os == 'windows'
@ -2375,6 +2373,9 @@ implot_proj = subproject('implot', required: true,
default_options: ['default_library=static'])
implot = implot_proj.get_variable('implot_dep')
genconfig_proj = subproject('genconfig', required: true)
genconfig = genconfig_proj.get_variable('cnode_dep')
subdir('thirdparty')
#################
@ -3627,16 +3628,11 @@ qemu_version = custom_target('qemu-version.h',
build_by_default: true,
build_always_stale: true)
genconfig_cmd = [
python, files('genconfig/gen_config.py'),
meson.current_source_dir() / 'config_spec.yml', 'xemu-config.h'
]
xemu_config = custom_target('xemu-config.h',
output: 'xemu-config.h',
input: [ files('config_spec.yml') ],
command: genconfig_cmd,
depend_files: files('config_spec.yml'))
command : [python, genconfig_proj.get_variable('gen_config_script_path'), '@INPUT@', '@OUTPUT@'],
)
genh += qemu_version
genh += xemu_version

View File

@ -35,7 +35,7 @@ sub_deinit=""
# xemu extras
subprojects="$subprojects glslang SPIRV-Reflect volk VulkanMemoryAllocator
nv2a_vsh_cpu tomlplusplus cpp-httplib xxhash imgui implot"
nv2a_vsh_cpu tomlplusplus cpp-httplib xxhash imgui implot genconfig"
function cleanup() {
local status=$?

View File

@ -28,3 +28,4 @@ cpp-httplib
xxHash-*
imgui
implot
genconfig

View File

@ -0,0 +1,4 @@
[wrap-git]
url=https://github.com/mborgerson/genconfig.git
revision=42f85f9a2457e61d7e32542c07723565a284fcd6
depth=1