mirror of
https://github.com/ciphervance/supercell-wx.git
synced 2025-10-29 20:30:05 +00:00
Use debug conan profiles for debug configurations
This commit is contained in:
parent
76c6ac2ccd
commit
f684d62cb1
3 changed files with 74 additions and 30 deletions
|
|
@ -54,9 +54,7 @@
|
||||||
"inherits": "windows-x64-base",
|
"inherits": "windows-x64-base",
|
||||||
"hidden": true,
|
"hidden": true,
|
||||||
"cacheVariables": {
|
"cacheVariables": {
|
||||||
"CMAKE_PREFIX_PATH": "C:/Qt/6.8.3/msvc2022_64",
|
"CMAKE_PREFIX_PATH": "C:/Qt/6.8.3/msvc2022_64"
|
||||||
"CONAN_HOST_PROFILE": "scwx-windows_msvc2022_x64",
|
|
||||||
"CONAN_BUILD_PROFILE": "scwx-windows_msvc2022_x64"
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
@ -65,9 +63,7 @@
|
||||||
"hidden": true,
|
"hidden": true,
|
||||||
"generator": "Ninja",
|
"generator": "Ninja",
|
||||||
"cacheVariables": {
|
"cacheVariables": {
|
||||||
"CMAKE_PREFIX_PATH": "C:/Qt/6.8.3/msvc2022_64",
|
"CMAKE_PREFIX_PATH": "C:/Qt/6.8.3/msvc2022_64"
|
||||||
"CONAN_HOST_PROFILE": "scwx-windows_msvc2022_x64",
|
|
||||||
"CONAN_BUILD_PROFILE": "scwx-windows_msvc2022_x64"
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
@ -75,9 +71,7 @@
|
||||||
"inherits": "linux-base",
|
"inherits": "linux-base",
|
||||||
"hidden": true,
|
"hidden": true,
|
||||||
"cacheVariables": {
|
"cacheVariables": {
|
||||||
"CMAKE_PREFIX_PATH": "/opt/Qt/6.8.3/gcc_64",
|
"CMAKE_PREFIX_PATH": "/opt/Qt/6.8.3/gcc_64"
|
||||||
"CONAN_HOST_PROFILE": "scwx-linux_gcc-11",
|
|
||||||
"CONAN_BUILD_PROFILE": "scwx-linux_gcc-11"
|
|
||||||
},
|
},
|
||||||
"environment": {
|
"environment": {
|
||||||
"CC": "gcc-11",
|
"CC": "gcc-11",
|
||||||
|
|
@ -93,7 +87,9 @@
|
||||||
"strategy": "external"
|
"strategy": "external"
|
||||||
},
|
},
|
||||||
"cacheVariables": {
|
"cacheVariables": {
|
||||||
"CMAKE_BUILD_TYPE": "Debug"
|
"CMAKE_BUILD_TYPE": "Debug",
|
||||||
|
"CONAN_HOST_PROFILE": "scwx-windows_msvc2022_x64-debug",
|
||||||
|
"CONAN_BUILD_PROFILE": "scwx-windows_msvc2022_x64-debug"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
@ -105,7 +101,9 @@
|
||||||
"strategy": "external"
|
"strategy": "external"
|
||||||
},
|
},
|
||||||
"cacheVariables": {
|
"cacheVariables": {
|
||||||
"CMAKE_BUILD_TYPE": "Release"
|
"CMAKE_BUILD_TYPE": "Release",
|
||||||
|
"CONAN_HOST_PROFILE": "scwx-windows_msvc2022_x64",
|
||||||
|
"CONAN_BUILD_PROFILE": "scwx-windows_msvc2022_x64"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
@ -113,7 +111,9 @@
|
||||||
"inherits": "windows-msvc2022-x64-ninja-base",
|
"inherits": "windows-msvc2022-x64-ninja-base",
|
||||||
"displayName": "Windows MSVC 2022 x64 Ninja Debug",
|
"displayName": "Windows MSVC 2022 x64 Ninja Debug",
|
||||||
"cacheVariables": {
|
"cacheVariables": {
|
||||||
"CMAKE_BUILD_TYPE": "Debug"
|
"CMAKE_BUILD_TYPE": "Debug",
|
||||||
|
"CONAN_HOST_PROFILE": "scwx-windows_msvc2022_x64-debug",
|
||||||
|
"CONAN_BUILD_PROFILE": "scwx-windows_msvc2022_x64-debug"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
@ -121,7 +121,9 @@
|
||||||
"inherits": "windows-msvc2022-x64-ninja-base",
|
"inherits": "windows-msvc2022-x64-ninja-base",
|
||||||
"displayName": "Windows MSVC 2022 x64 Ninja Release",
|
"displayName": "Windows MSVC 2022 x64 Ninja Release",
|
||||||
"cacheVariables": {
|
"cacheVariables": {
|
||||||
"CMAKE_BUILD_TYPE": "Release"
|
"CMAKE_BUILD_TYPE": "Release",
|
||||||
|
"CONAN_HOST_PROFILE": "scwx-windows_msvc2022_x64",
|
||||||
|
"CONAN_BUILD_PROFILE": "scwx-windows_msvc2022_x64"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
@ -130,7 +132,9 @@
|
||||||
"displayName": "Linux GCC Debug",
|
"displayName": "Linux GCC Debug",
|
||||||
"cacheVariables": {
|
"cacheVariables": {
|
||||||
"CMAKE_BUILD_TYPE": "Debug",
|
"CMAKE_BUILD_TYPE": "Debug",
|
||||||
"CMAKE_INSTALL_PREFIX": "${sourceDir}/build/${presetName}/Debug/supercell-wx"
|
"CMAKE_INSTALL_PREFIX": "${sourceDir}/build/${presetName}/Debug/supercell-wx",
|
||||||
|
"CONAN_HOST_PROFILE": "scwx-linux_gcc-11-debug",
|
||||||
|
"CONAN_BUILD_PROFILE": "scwx-linux_gcc-11-debug"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
@ -139,7 +143,9 @@
|
||||||
"displayName": "Linux GCC Release",
|
"displayName": "Linux GCC Release",
|
||||||
"cacheVariables": {
|
"cacheVariables": {
|
||||||
"CMAKE_BUILD_TYPE": "Release",
|
"CMAKE_BUILD_TYPE": "Release",
|
||||||
"CMAKE_INSTALL_PREFIX": "${sourceDir}/build/${presetName}/Release/supercell-wx"
|
"CMAKE_INSTALL_PREFIX": "${sourceDir}/build/${presetName}/Release/supercell-wx",
|
||||||
|
"CONAN_HOST_PROFILE": "scwx-linux_gcc-11",
|
||||||
|
"CONAN_BUILD_PROFILE": "scwx-linux_gcc-11"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
@ -149,6 +155,8 @@
|
||||||
"cacheVariables": {
|
"cacheVariables": {
|
||||||
"CMAKE_BUILD_TYPE": "Debug",
|
"CMAKE_BUILD_TYPE": "Debug",
|
||||||
"CMAKE_INSTALL_PREFIX": "${sourceDir}/build/${presetName}/Debug/supercell-wx",
|
"CMAKE_INSTALL_PREFIX": "${sourceDir}/build/${presetName}/Debug/supercell-wx",
|
||||||
|
"CONAN_HOST_PROFILE": "scwx-linux_gcc-11-debug",
|
||||||
|
"CONAN_BUILD_PROFILE": "scwx-linux_gcc-11-debug",
|
||||||
"SCWX_ADDRESS_SANITIZER": {
|
"SCWX_ADDRESS_SANITIZER": {
|
||||||
"type": "BOOL",
|
"type": "BOOL",
|
||||||
"value": "ON"
|
"value": "ON"
|
||||||
|
|
@ -162,6 +170,8 @@
|
||||||
"cacheVariables": {
|
"cacheVariables": {
|
||||||
"CMAKE_BUILD_TYPE": "Release",
|
"CMAKE_BUILD_TYPE": "Release",
|
||||||
"CMAKE_INSTALL_PREFIX": "${sourceDir}/build/${presetName}/Release/supercell-wx",
|
"CMAKE_INSTALL_PREFIX": "${sourceDir}/build/${presetName}/Release/supercell-wx",
|
||||||
|
"CONAN_HOST_PROFILE": "scwx-linux_gcc-11",
|
||||||
|
"CONAN_BUILD_PROFILE": "scwx-linux_gcc-11",
|
||||||
"SCWX_ADDRESS_SANITIZER": {
|
"SCWX_ADDRESS_SANITIZER": {
|
||||||
"type": "BOOL",
|
"type": "BOOL",
|
||||||
"value": "ON"
|
"value": "ON"
|
||||||
|
|
@ -202,9 +212,9 @@
|
||||||
"displayName": "CI Linux GCC ARM64",
|
"displayName": "CI Linux GCC ARM64",
|
||||||
"cacheVariables": {
|
"cacheVariables": {
|
||||||
"CMAKE_BUILD_TYPE": "Release",
|
"CMAKE_BUILD_TYPE": "Release",
|
||||||
|
"CMAKE_PREFIX_PATH": "/opt/Qt/6.8.3/gcc_arm64",
|
||||||
"CONAN_HOST_PROFILE": "scwx-linux_gcc-11_armv8",
|
"CONAN_HOST_PROFILE": "scwx-linux_gcc-11_armv8",
|
||||||
"CONAN_BUILD_PROFILE": "scwx-linux_gcc-11_armv8",
|
"CONAN_BUILD_PROFILE": "scwx-linux_gcc-11_armv8"
|
||||||
"CMAKE_PREFIX_PATH": "/opt/Qt/6.8.3/gcc_arm64"
|
|
||||||
},
|
},
|
||||||
"environment": {
|
"environment": {
|
||||||
"CC": "gcc-11",
|
"CC": "gcc-11",
|
||||||
|
|
@ -233,10 +243,6 @@
|
||||||
"name": "macos-clang18-x64-base",
|
"name": "macos-clang18-x64-base",
|
||||||
"inherits": "macos-clang18-base",
|
"inherits": "macos-clang18-base",
|
||||||
"hidden": true,
|
"hidden": true,
|
||||||
"cacheVariables": {
|
|
||||||
"CONAN_HOST_PROFILE": "scwx-macos_clang-18",
|
|
||||||
"CONAN_BUILD_PROFILE": "scwx-macos_clang-18"
|
|
||||||
},
|
|
||||||
"environment": {
|
"environment": {
|
||||||
"CC": "/usr/local/opt/llvm@18/bin/clang",
|
"CC": "/usr/local/opt/llvm@18/bin/clang",
|
||||||
"CXX": "/usr/local/opt/llvm@18/bin/clang++",
|
"CXX": "/usr/local/opt/llvm@18/bin/clang++",
|
||||||
|
|
@ -249,10 +255,6 @@
|
||||||
"name": "macos-clang18-arm64-base",
|
"name": "macos-clang18-arm64-base",
|
||||||
"inherits": "macos-clang18-base",
|
"inherits": "macos-clang18-base",
|
||||||
"hidden": true,
|
"hidden": true,
|
||||||
"cacheVariables": {
|
|
||||||
"CONAN_HOST_PROFILE": "scwx-macos_clang-18_armv8",
|
|
||||||
"CONAN_BUILD_PROFILE": "scwx-macos_clang-18_armv8"
|
|
||||||
},
|
|
||||||
"environment": {
|
"environment": {
|
||||||
"CC": "/opt/homebrew/opt/llvm@18/bin/clang",
|
"CC": "/opt/homebrew/opt/llvm@18/bin/clang",
|
||||||
"CXX": "/opt/homebrew/opt/llvm@18/bin/clang++",
|
"CXX": "/opt/homebrew/opt/llvm@18/bin/clang++",
|
||||||
|
|
@ -266,7 +268,9 @@
|
||||||
"inherits": "macos-clang18-x64-base",
|
"inherits": "macos-clang18-x64-base",
|
||||||
"displayName": "macOS Clang 18 x64 Debug",
|
"displayName": "macOS Clang 18 x64 Debug",
|
||||||
"cacheVariables": {
|
"cacheVariables": {
|
||||||
"CMAKE_BUILD_TYPE": "Debug"
|
"CMAKE_BUILD_TYPE": "Debug",
|
||||||
|
"CONAN_HOST_PROFILE": "scwx-macos_clang-18-debug",
|
||||||
|
"CONAN_BUILD_PROFILE": "scwx-macos_clang-18-debug"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
@ -274,7 +278,9 @@
|
||||||
"inherits": "macos-clang18-x64-base",
|
"inherits": "macos-clang18-x64-base",
|
||||||
"displayName": "macOS Clang 18 x64 Release",
|
"displayName": "macOS Clang 18 x64 Release",
|
||||||
"cacheVariables": {
|
"cacheVariables": {
|
||||||
"CMAKE_BUILD_TYPE": "Release"
|
"CMAKE_BUILD_TYPE": "Release",
|
||||||
|
"CONAN_HOST_PROFILE": "scwx-macos_clang-18",
|
||||||
|
"CONAN_BUILD_PROFILE": "scwx-macos_clang-18"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
@ -282,7 +288,9 @@
|
||||||
"inherits": "macos-clang18-arm64-base",
|
"inherits": "macos-clang18-arm64-base",
|
||||||
"displayName": "macOS Clang 18 Arm64 Debug",
|
"displayName": "macOS Clang 18 Arm64 Debug",
|
||||||
"cacheVariables": {
|
"cacheVariables": {
|
||||||
"CMAKE_BUILD_TYPE": "Debug"
|
"CMAKE_BUILD_TYPE": "Debug",
|
||||||
|
"CONAN_HOST_PROFILE": "scwx-macos_clang-18_armv8-debug",
|
||||||
|
"CONAN_BUILD_PROFILE": "scwx-macos_clang-18_armv8-debug"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
@ -290,7 +298,9 @@
|
||||||
"inherits": "macos-clang18-arm64-base",
|
"inherits": "macos-clang18-arm64-base",
|
||||||
"displayName": "macOS Clang 18 Arm64 Release",
|
"displayName": "macOS Clang 18 Arm64 Release",
|
||||||
"cacheVariables": {
|
"cacheVariables": {
|
||||||
"CMAKE_BUILD_TYPE": "Release"
|
"CMAKE_BUILD_TYPE": "Release",
|
||||||
|
"CONAN_HOST_PROFILE": "scwx-macos_clang-18_armv8",
|
||||||
|
"CONAN_BUILD_PROFILE": "scwx-macos_clang-18_armv8"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
|
|
|
||||||
|
|
@ -33,8 +33,24 @@ pip install --upgrade -r "%script_dir%\..\requirements.txt"
|
||||||
|
|
||||||
:: Install Conan profiles
|
:: Install Conan profiles
|
||||||
@for /L %%i in (0,1,!last_profile!) do @(
|
@for /L %%i in (0,1,!last_profile!) do @(
|
||||||
|
:: Install the base profile
|
||||||
set "profile_name=!conan_profile[%%i]!"
|
set "profile_name=!conan_profile[%%i]!"
|
||||||
conan config install "%script_dir%\conan\profiles\!profile_name!" -tf profiles
|
set "profile_path=%script_dir%\conan\profiles\!profile_name!"
|
||||||
|
conan config install "!profile_path!" -tf profiles
|
||||||
|
|
||||||
|
:: Create debug profile in temp directory
|
||||||
|
set "debug_profile_name=!profile_name!-debug"
|
||||||
|
set "debug_profile_path=%TEMP%\!debug_profile_name!"
|
||||||
|
copy "!profile_path!" "!debug_profile_path!" >nul
|
||||||
|
|
||||||
|
:: Replace build_type=Release with build_type=Debug
|
||||||
|
powershell -Command "(Get-Content '!debug_profile_path!') -replace 'build_type=Release', 'build_type=Debug' | Set-Content '!debug_profile_path!'"
|
||||||
|
|
||||||
|
:: Install the debug profile
|
||||||
|
conan config install "!debug_profile_path!" -tf profiles
|
||||||
|
|
||||||
|
:: Remove temporary debug profile
|
||||||
|
del "!debug_profile_path!"
|
||||||
)
|
)
|
||||||
|
|
||||||
:: Deactivate Python Virtual Environment
|
:: Deactivate Python Virtual Environment
|
||||||
|
|
|
||||||
|
|
@ -71,7 +71,25 @@ fi
|
||||||
|
|
||||||
# Install Conan profiles
|
# Install Conan profiles
|
||||||
for profile_name in "${conan_profiles[@]}"; do
|
for profile_name in "${conan_profiles[@]}"; do
|
||||||
|
# Install original profile
|
||||||
conan config install "${script_dir}/conan/profiles/${profile_name}" -tf profiles
|
conan config install "${script_dir}/conan/profiles/${profile_name}" -tf profiles
|
||||||
|
|
||||||
|
# Create debug profile in temp directory
|
||||||
|
debug_profile="/tmp/${profile_name}-debug"
|
||||||
|
cp "${script_dir}/conan/profiles/${profile_name}" "${debug_profile}"
|
||||||
|
|
||||||
|
# Replace build_type=Release with build_type=Debug
|
||||||
|
if [[ "$(uname)" == "Darwin" ]]; then
|
||||||
|
sed -i '' 's/build_type=Release/build_type=Debug/g' "${debug_profile}"
|
||||||
|
else
|
||||||
|
sed -i 's/build_type=Release/build_type=Debug/g' "${debug_profile}"
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Install the debug profile
|
||||||
|
conan config install "${debug_profile}" -tf profiles
|
||||||
|
|
||||||
|
# Remove temporary debug profile
|
||||||
|
rm "${debug_profile}"
|
||||||
done
|
done
|
||||||
|
|
||||||
# Deactivate Python Virtual Environment
|
# Deactivate Python Virtual Environment
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue