diff --git a/.gitmodules b/.gitmodules new file mode 100644 index 0000000..ff41384 --- /dev/null +++ b/.gitmodules @@ -0,0 +1,3 @@ +[submodule "subprojects/glaze"] + path = subprojects/glaze + url = https://github.com/stephenberry/glaze diff --git a/meson.build b/meson.build index 467546f..b7edf3d 100644 --- a/meson.build +++ b/meson.build @@ -9,6 +9,7 @@ project( 'default_library=static', 'warning_level=everything', 'buildtype=debugoptimized', + 'b_vscrt=mt', ], ) @@ -38,7 +39,10 @@ common_cpp_flags = { '-std=c++26', ], 'msvc': [ - '-DNOMINMAX', '/Zc:__cplusplus', + '-DNOMINMAX', + '/MT', + '/Zc:__cplusplus', + '/Zc:preprocessor', '/std:c++latest', ], 'unix_extra': [ @@ -98,7 +102,6 @@ common_deps = [ dependency('fmt', include_type: 'system', static: true), dependency('libcurl', include_type: 'system', static: true), dependency('tomlplusplus', include_type: 'system', static: true), - dependency('glaze', include_type: 'system'), dependency('openssl', include_type: 'system', static: true, required: false), ] @@ -151,8 +154,18 @@ if not ftxui_dep.found() ) endif +glaze_dep = dependency('glaze', include_type: 'system', required: false) + +if not glaze_dep.found() + cmake = import('cmake') + + glaze_proj = cmake.subproject('glaze') + + glaze_dep = glaze_proj.dependency('glaze_glaze', include_type: 'system') +endif + # Combine all dependencies -deps = common_deps + platform_deps + ftxui_dep +deps = common_deps + platform_deps + ftxui_dep + glaze_dep # ------------------------- # # Link/ObjC Configuration # diff --git a/subprojects/glaze b/subprojects/glaze new file mode 160000 index 0000000..cfa3c58 --- /dev/null +++ b/subprojects/glaze @@ -0,0 +1 @@ +Subproject commit cfa3c5838cc04e2f179faddf8e4757f90fa5fbe7