meson: Migrate tomlplusplus submodule to a subproject

This commit is contained in:
Matt Borgerson 2024-12-31 16:43:33 -07:00 committed by mborgerson
parent 824af3978f
commit 55118b4260
8 changed files with 13 additions and 15 deletions

3
.gitmodules vendored
View File

@ -79,9 +79,6 @@
[submodule "genconfig"]
path = genconfig
url = https://github.com/mborgerson/genconfig.git
[submodule "tomlplusplus"]
path = tomlplusplus
url = https://github.com/marzer/tomlplusplus
[submodule "ui/thirdparty/httplib"]
path = ui/thirdparty/httplib
url = https://github.com/yhirose/cpp-httplib

2
configure vendored
View File

@ -237,7 +237,7 @@ else
git_submodules_action="ignore"
fi
git_submodules="ui/keycodemapdb ui/thirdparty/imgui ui/thirdparty/implot ui/thirdparty/httplib util/xxHash tomlplusplus genconfig"
git_submodules="ui/keycodemapdb ui/thirdparty/imgui ui/thirdparty/implot ui/thirdparty/httplib util/xxHash genconfig"
git="git"
# Don't accept a target_list environment variable.

View File

@ -1244,12 +1244,6 @@ if (have_system or have_tools) and (virgl.found() or opengl.found())
endif
have_vhost_user_gpu = have_vhost_user_gpu and virgl.found() and opengl.found() and gbm.found()
tomllib = static_library('tomlpp', sources: files('toml.cpp'),
include_directories: 'tomlplusplus/include')
toml = declare_dependency(compile_args: ['-DTOML_HEADER_ONLY=0'],
include_directories: 'tomlplusplus/include',
link_with: tomllib)
genconfig = declare_dependency(include_directories: 'genconfig')
openssl = dependency('openssl', method: 'pkg-config', required: true,
@ -2901,6 +2895,9 @@ config_host_data.set('CONFIG_CAPSTONE', capstone.found())
config_host_data.set('CONFIG_FDT', fdt.found())
config_host_data.set('CONFIG_SLIRP', slirp.found())
tomlplusplus_proj = subproject('tomlplusplus')
tomlplusplus = tomlplusplus_proj.get_variable('tomlplusplus_dep')
#####################
# Generated sources #
#####################
@ -3253,7 +3250,7 @@ specific_ss.add(files('xemu-xbe.c', 'xemu-version.c'))
common_ss.add(files('cpus-common.c'))
common_ss.add(toml)
common_ss.add(tomlplusplus)
common_ss.add(genconfig)
subdir('softmmu')

View File

@ -30,9 +30,9 @@ submodules="dtc meson ui/keycodemapdb"
submodules="$submodules tests/fp/berkeley-softfloat-3 tests/fp/berkeley-testfloat-3"
# xemu extras
submodules="$submodules ui/thirdparty/imgui ui/thirdparty/implot ui/thirdparty/httplib util/xxHash tomlplusplus genconfig"
submodules="$submodules ui/thirdparty/imgui ui/thirdparty/implot ui/thirdparty/httplib util/xxHash genconfig"
subprojects="glslang SPIRV-Reflect volk VulkanMemoryAllocator nv2a_vsh_cpu"
subprojects="glslang SPIRV-Reflect volk VulkanMemoryAllocator nv2a_vsh_cpu tomlplusplus"
sub_deinit=""

View File

@ -218,7 +218,7 @@ Lib('stb_image', 'https://github.com/nothings/stb',
Lib('tomlplusplus', 'https://github.com/marzer/tomlplusplus',
mit, 'https://raw.githubusercontent.com/marzer/tomlplusplus/master/LICENSE',
ships_static=all_platforms,
submodule=Submodule('tomlplusplus')
submodule=Submodule('subprojects/tomlplusplus.wrap')
),
Lib('xxHash', 'https://github.com/Cyan4973/xxHash.git',

View File

@ -3,3 +3,4 @@ SPIRV-Reflect
volk
VulkanMemoryAllocator
nv2a_vsh_cpu
tomlplusplus

View File

@ -0,0 +1,4 @@
[wrap-git]
url=https://github.com/marzer/tomlplusplus
revision=c635f218c0aefc801d9748841930365e54fe3089
depth=1

@ -1 +0,0 @@
Subproject commit c635f218c0aefc801d9748841930365e54fe3089