- Upgraded CMake minimum version requirement to 3.16 and updated project version to 0.3.0. - Introduced new CMake presets for build configurations, including default, debug, and release options. - Added CI/CD workflows for continuous integration and release management, enhancing automated testing and deployment processes. - Integrated Asar assembler support with new wrapper classes and CLI commands for patching ROMs. - Implemented comprehensive tests for Asar integration, ensuring robust functionality and error handling. - Enhanced packaging configuration for cross-platform support, including Windows, macOS, and Linux. - Updated documentation and added test assets for improved clarity and usability.
337 lines
7.9 KiB
JSON
337 lines
7.9 KiB
JSON
{
|
|
"version": 6,
|
|
"cmakeMinimumRequired": {
|
|
"major": 3,
|
|
"minor": 16,
|
|
"patch": 0
|
|
},
|
|
"configurePresets": [
|
|
{
|
|
"name": "default",
|
|
"displayName": "Default Config",
|
|
"description": "Default build configuration",
|
|
"generator": "Ninja",
|
|
"binaryDir": "${sourceDir}/build",
|
|
"cacheVariables": {
|
|
"CMAKE_BUILD_TYPE": "RelWithDebInfo",
|
|
"YAZE_BUILD_TESTS": "ON",
|
|
"YAZE_BUILD_APP": "ON",
|
|
"YAZE_BUILD_LIB": "ON",
|
|
"YAZE_BUILD_EMU": "ON",
|
|
"YAZE_BUILD_Z3ED": "ON"
|
|
}
|
|
},
|
|
{
|
|
"name": "debug",
|
|
"displayName": "Debug",
|
|
"description": "Debug build with full debugging symbols",
|
|
"inherits": "default",
|
|
"cacheVariables": {
|
|
"CMAKE_BUILD_TYPE": "Debug",
|
|
"CMAKE_CXX_FLAGS_DEBUG": "-g -O0 -DDEBUG",
|
|
"CMAKE_C_FLAGS_DEBUG": "-g -O0 -DDEBUG"
|
|
}
|
|
},
|
|
{
|
|
"name": "release",
|
|
"displayName": "Release",
|
|
"description": "Optimized release build",
|
|
"inherits": "default",
|
|
"cacheVariables": {
|
|
"CMAKE_BUILD_TYPE": "Release",
|
|
"YAZE_BUILD_TESTS": "OFF"
|
|
}
|
|
},
|
|
{
|
|
"name": "dev",
|
|
"displayName": "Development",
|
|
"description": "Development build with ROM testing enabled",
|
|
"inherits": "debug",
|
|
"cacheVariables": {
|
|
"YAZE_ENABLE_ROM_TESTS": "ON",
|
|
"YAZE_TEST_ROM_PATH": "${sourceDir}/build/bin/zelda3.sfc"
|
|
}
|
|
},
|
|
{
|
|
"name": "ci",
|
|
"displayName": "Continuous Integration",
|
|
"description": "CI build without ROM-dependent tests",
|
|
"inherits": "default",
|
|
"cacheVariables": {
|
|
"YAZE_ENABLE_ROM_TESTS": "OFF",
|
|
"YAZE_BUILD_TESTS": "ON"
|
|
}
|
|
},
|
|
{
|
|
"name": "macos-debug",
|
|
"displayName": "macOS Debug",
|
|
"description": "macOS-specific debug configuration",
|
|
"inherits": "debug",
|
|
"condition": {
|
|
"type": "equals",
|
|
"lhs": "${hostSystemName}",
|
|
"rhs": "Darwin"
|
|
},
|
|
"cacheVariables": {
|
|
"CMAKE_OSX_DEPLOYMENT_TARGET": "10.15",
|
|
"CMAKE_OSX_ARCHITECTURES": "x86_64;arm64"
|
|
}
|
|
},
|
|
{
|
|
"name": "macos-release",
|
|
"displayName": "macOS Release",
|
|
"description": "macOS-specific release configuration",
|
|
"inherits": "release",
|
|
"condition": {
|
|
"type": "equals",
|
|
"lhs": "${hostSystemName}",
|
|
"rhs": "Darwin"
|
|
},
|
|
"cacheVariables": {
|
|
"CMAKE_OSX_DEPLOYMENT_TARGET": "10.15",
|
|
"CMAKE_OSX_ARCHITECTURES": "x86_64;arm64"
|
|
}
|
|
},
|
|
{
|
|
"name": "linux-debug",
|
|
"displayName": "Linux Debug",
|
|
"description": "Linux-specific debug configuration",
|
|
"inherits": "debug",
|
|
"condition": {
|
|
"type": "equals",
|
|
"lhs": "${hostSystemName}",
|
|
"rhs": "Linux"
|
|
},
|
|
"cacheVariables": {
|
|
"CMAKE_CXX_COMPILER": "g++",
|
|
"CMAKE_C_COMPILER": "gcc"
|
|
}
|
|
},
|
|
{
|
|
"name": "linux-clang",
|
|
"displayName": "Linux Clang",
|
|
"description": "Linux build with Clang",
|
|
"inherits": "debug",
|
|
"condition": {
|
|
"type": "equals",
|
|
"lhs": "${hostSystemName}",
|
|
"rhs": "Linux"
|
|
},
|
|
"cacheVariables": {
|
|
"CMAKE_CXX_COMPILER": "clang++",
|
|
"CMAKE_C_COMPILER": "clang"
|
|
}
|
|
},
|
|
{
|
|
"name": "windows-debug",
|
|
"displayName": "Windows Debug",
|
|
"description": "Windows-specific debug configuration",
|
|
"inherits": "debug",
|
|
"condition": {
|
|
"type": "equals",
|
|
"lhs": "${hostSystemName}",
|
|
"rhs": "Windows"
|
|
},
|
|
"generator": "Visual Studio 17 2022",
|
|
"architecture": "x64",
|
|
"cacheVariables": {
|
|
"CMAKE_TOOLCHAIN_FILE": "${sourceDir}/vcpkg/scripts/buildsystems/vcpkg.cmake",
|
|
"VCPKG_TARGET_TRIPLET": "x64-windows"
|
|
}
|
|
},
|
|
{
|
|
"name": "asan",
|
|
"displayName": "AddressSanitizer",
|
|
"description": "Debug build with AddressSanitizer",
|
|
"inherits": "debug",
|
|
"cacheVariables": {
|
|
"CMAKE_CXX_FLAGS": "-fsanitize=address -fno-omit-frame-pointer -g",
|
|
"CMAKE_C_FLAGS": "-fsanitize=address -fno-omit-frame-pointer -g",
|
|
"CMAKE_EXE_LINKER_FLAGS": "-fsanitize=address",
|
|
"CMAKE_SHARED_LINKER_FLAGS": "-fsanitize=address"
|
|
}
|
|
},
|
|
{
|
|
"name": "coverage",
|
|
"displayName": "Code Coverage",
|
|
"description": "Debug build with code coverage",
|
|
"inherits": "debug",
|
|
"cacheVariables": {
|
|
"CMAKE_CXX_FLAGS": "--coverage -g -O0",
|
|
"CMAKE_C_FLAGS": "--coverage -g -O0",
|
|
"CMAKE_EXE_LINKER_FLAGS": "--coverage"
|
|
}
|
|
}
|
|
],
|
|
"buildPresets": [
|
|
{
|
|
"name": "default",
|
|
"configurePreset": "default",
|
|
"displayName": "Default Build"
|
|
},
|
|
{
|
|
"name": "debug",
|
|
"configurePreset": "debug",
|
|
"displayName": "Debug Build"
|
|
},
|
|
{
|
|
"name": "release",
|
|
"configurePreset": "release",
|
|
"displayName": "Release Build"
|
|
},
|
|
{
|
|
"name": "dev",
|
|
"configurePreset": "dev",
|
|
"displayName": "Development Build"
|
|
},
|
|
{
|
|
"name": "ci",
|
|
"configurePreset": "ci",
|
|
"displayName": "CI Build"
|
|
},
|
|
{
|
|
"name": "macos-debug",
|
|
"configurePreset": "macos-debug",
|
|
"displayName": "macOS Debug Build"
|
|
},
|
|
{
|
|
"name": "macos-release",
|
|
"configurePreset": "macos-release",
|
|
"displayName": "macOS Release Build"
|
|
},
|
|
{
|
|
"name": "fast",
|
|
"configurePreset": "debug",
|
|
"displayName": "Fast Debug Build",
|
|
"jobs": 0
|
|
}
|
|
],
|
|
"testPresets": [
|
|
{
|
|
"name": "default",
|
|
"configurePreset": "default",
|
|
"displayName": "Default Tests",
|
|
"execution": {
|
|
"noTestsAction": "error",
|
|
"stopOnFailure": false
|
|
},
|
|
"filter": {
|
|
"exclude": {
|
|
"label": "ROM_DEPENDENT"
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"name": "dev",
|
|
"configurePreset": "dev",
|
|
"displayName": "Development Tests (with ROM)",
|
|
"execution": {
|
|
"noTestsAction": "error",
|
|
"stopOnFailure": false
|
|
}
|
|
},
|
|
{
|
|
"name": "ci",
|
|
"configurePreset": "ci",
|
|
"displayName": "CI Tests (no ROM)",
|
|
"execution": {
|
|
"noTestsAction": "error",
|
|
"stopOnFailure": false
|
|
},
|
|
"filter": {
|
|
"exclude": {
|
|
"label": "ROM_DEPENDENT"
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"name": "unit-only",
|
|
"configurePreset": "default",
|
|
"displayName": "Unit Tests Only",
|
|
"filter": {
|
|
"include": {
|
|
"label": "UNIT_TEST"
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"name": "integration-only",
|
|
"configurePreset": "dev",
|
|
"displayName": "Integration Tests Only",
|
|
"filter": {
|
|
"include": {
|
|
"label": "INTEGRATION_TEST"
|
|
}
|
|
}
|
|
}
|
|
],
|
|
"packagePresets": [
|
|
{
|
|
"name": "default",
|
|
"configurePreset": "release",
|
|
"displayName": "Default Package"
|
|
},
|
|
{
|
|
"name": "macos",
|
|
"configurePreset": "macos-release",
|
|
"displayName": "macOS Package"
|
|
}
|
|
],
|
|
"workflowPresets": [
|
|
{
|
|
"name": "dev-workflow",
|
|
"displayName": "Development Workflow",
|
|
"steps": [
|
|
{
|
|
"type": "configure",
|
|
"name": "dev"
|
|
},
|
|
{
|
|
"type": "build",
|
|
"name": "dev"
|
|
},
|
|
{
|
|
"type": "test",
|
|
"name": "dev"
|
|
}
|
|
]
|
|
},
|
|
{
|
|
"name": "ci-workflow",
|
|
"displayName": "CI Workflow",
|
|
"steps": [
|
|
{
|
|
"type": "configure",
|
|
"name": "ci"
|
|
},
|
|
{
|
|
"type": "build",
|
|
"name": "ci"
|
|
},
|
|
{
|
|
"type": "test",
|
|
"name": "ci"
|
|
}
|
|
]
|
|
},
|
|
{
|
|
"name": "release-workflow",
|
|
"displayName": "Release Workflow",
|
|
"steps": [
|
|
{
|
|
"type": "configure",
|
|
"name": "macos-release"
|
|
},
|
|
{
|
|
"type": "build",
|
|
"name": "macos-release"
|
|
},
|
|
{
|
|
"type": "package",
|
|
"name": "macos"
|
|
}
|
|
]
|
|
}
|
|
]
|
|
}
|