Windows: Generate launch.vs.json via CMake template

This commit is contained in:
Tim Wojtulewicz 2025-09-05 20:23:01 -07:00
parent a58323c367
commit 8143634a4c
2 changed files with 25 additions and 0 deletions

View file

@ -560,6 +560,8 @@ if (MSVC)
# paths are stored in the output file.
configure_file(cmake_templates/zeek-path-dev.bat.in
${CMAKE_CURRENT_BINARY_DIR}/zeek-path-dev.bat)
configure_file(cmake_templates/launch.vs.json.in
${CMAKE_CURRENT_SOURCE_DIR}/.vs/launch.vs.json)
string(REGEX REPLACE "^([A-Za-z]):/(.*)" "/\\1/\\2" cmake_binary_dir "${cmake_binary_dir}")
string(REGEX REPLACE "^([A-Za-z]):/(.*)" "/\\1/\\2" cmake_current_binary_dir

View file

@ -0,0 +1,23 @@
{
"version": "0.2.1",
"defaults": {},
"configurations": [
{
"type": "default",
"project": "CMakeLists.txt",
"projectTarget": "zeek.exe (src\\zeek.exe)",
"name": "zeek.exe (src\\zeek.exe)",
"currentDir": "${cmake_source_dir}",
"args": [
"-C",
"-r",
"${cmake_source_dir}/testing/btest/Traces/http/get.trace",
"local"
],
"env": {
"ZEEKPATH": ".;${cmake_source_dir}/scripts;${cmake_source_dir}/scripts/policy;${cmake_source_dir}/scripts/site;${cmake_binary_dir}/scripts;${cmake_binary_dir}/scripts/builtin-plugins",
"ZEEK_PLUGIN_PATH": "${cmake_binary_dir}/src",
}
}
]
}