Fixes two CI failures:
1. Windows Abseil header lookup - removed manual include_directories
in util.cmake that were only added when gRPC was enabled. CMake
target properties now handle Abseil includes automatically.
2. Code formatting violations in test/yaze_test.cc - applied clang-format
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <noreply@anthropic.com>
- Updated CMakeLists.txt to conditionally include AI GUI controller tests and experimental AI test suites based on the YAZE_ENABLE_AI_RUNTIME flag.
- Added status messages to inform users when AI tests are skipped due to the runtime being disabled, improving clarity in the build process.
- This change ensures that tests related to AI features are only compiled and run when the appropriate runtime is enabled, enhancing modularity and build efficiency.
- Moved all third-party libraries (SDL, ImGui, Asar, etc.) from `src/lib/` and `third_party/` to a new `ext/` directory for better organization and clarity in dependency management.
- Updated CMake configuration to reflect the new paths, ensuring all targets and includes point to the `ext/` directory.
- Enhanced CMake presets to support new build options for AI and gRPC features, improving modularity and build flexibility.
- Added new feature flags for agent UI and remote automation, allowing for more granular control over build configurations.
- Updated documentation to reflect changes in the project structure and build options, ensuring clarity for contributors and users.
- Added new entries to `.pre-commit-config.yaml`, `cmake-format.yaml`, and `.github/dependabot.yml` to improve code quality checks and dependency updates.
- Enhanced GitHub Actions workflows by adding new steps for testing and build retention.
- Introduced support for the nlohmann_json library in CMake, allowing for conditional inclusion based on the `YAZE_ENABLE_JSON` option.
- Updated CMake configurations to streamline SDL2 and gRPC integration, ensuring proper linking and target management.
Benefits:
- Improves code quality and consistency through automated checks and formatting.
- Enhances dependency management and build reliability across platforms.
- Provides flexibility for users to enable optional features, improving overall functionality.
- Enhanced CMake configuration to conditionally apply /WHOLEARCHIVE linking for protobuf targets, ensuring only library targets are included.
- Updated linking logic across multiple components including `yaze`, `yaze_emu`, `z3ed`, and test suites to improve compatibility and prevent linker errors.
Benefits:
- Increases build stability and clarity by ensuring only relevant targets are linked, reducing potential conflicts during the build process.
- Adjusted CMake files to conditionally link protobuf using /WHOLEARCHIVE on Windows to include internal symbols while avoiding LNK1241 errors.
- Updated linking logic for `yaze`, `yaze_editor`, `yaze_emu`, `z3ed`, and test suites to ensure compatibility across platforms.
Benefits:
- Improves build stability and compatibility for Windows users by ensuring proper symbol inclusion without resource duplication issues.
- Added /WHOLEARCHIVE linking for protobuf in various CMake files to ensure internal symbols are included while preventing resource duplication.
- Updated linking options for `yaze`, `yaze_emu`, `z3ed`, and test suites to apply this option conditionally on Windows with MSVC.
Benefits:
- Ensures proper inclusion of protobuf symbols in executables, improving compatibility and functionality across platforms.
- Upgraded gRPC version from v1.68.0 to v1.75.1 for improved compatibility across all platforms.
- Removed /WHOLEARCHIVE linking for protobuf to prevent duplicate version resource errors in the dependency chain.
- Updated status messages to reflect the latest gRPC version and build optimizations.
Benefits:
- Enhances build stability and compatibility with modern toolchains.
- Simplifies linking process by avoiding unnecessary options that cause conflicts.
- Moved core components such as `Controller` and `Window` from `src/app/core/` to `src/app/` and `src/app/platform/`, respectively, to improve modularity and clarity.
- Updated include paths across the codebase to reflect the new locations of these components.
- Introduced a new foundational core library in `src/core/` for project management and ROM patching logic, enhancing the separation of concerns.
- Adjusted CMake configurations to ensure proper compilation of the new core library and updated dependencies in various modules.
Benefits:
- Streamlines the application structure, making it easier to navigate and maintain.
- Enhances code organization by clearly delineating core functionalities from application-specific logic.
- Improves overall architecture by promoting a clearer separation of concerns between different components.
- Relocated AsarWrapper implementation and header files from `src/app/core/` to `src/core/` to enhance modularity and organization.
- Updated all relevant include paths across the codebase to reflect the new location of AsarWrapper.
- Adjusted CMake configurations to ensure proper compilation of the core library.
Benefits:
- Improves project structure by separating core functionalities from application-specific code.
- Facilitates easier maintenance and understanding of the codebase by clarifying the organization of core components.
- Introduced YAZE_PROTOBUF_WHOLEARCHIVE_TARGETS to streamline linking of Protobuf targets, excluding "lite" variants.
- Updated CMake configurations across various components (yaze, yaze_core_lib, yaze_editor, yaze_net, yaze_agent, z3ed) to utilize the new whole-archive targets for MSVC builds.
- Improved test suite linking to ensure all Protobuf symbols are included during the build process.
Benefits:
- Enhances compatibility and maintainability of Protobuf linking, leading to a more robust build configuration.
Benefits:
- Streamlines the build process by allowing for multiple Protobuf targets, enhancing compatibility and maintainability.
- Improves session management capabilities within the editor, leading to a more organized and efficient user experience.
- Enhance Protobuf target handling in CMake configuration
- Updated CMake files to support multiple Protobuf targets, improving flexibility in linking.
- Adjusted target link libraries across various components (yaze, yaze_core_lib, yaze_editor, etc.) to utilize the new
- Added caching for ccache and CMake dependencies in CI and release workflows to improve build performance.
- Updated installation commands to include ccache across Linux, macOS, and Windows environments.
- Enhanced CMake configuration steps to utilize ccache for faster builds and added statistics reporting.
Benefits:
- Reduces build times and improves efficiency in CI processes, facilitating quicker feedback and integration.
- Updated CI and release workflows to enable building the emulator (YAZE_BUILD_EMU), Z3ED (YAZE_BUILD_Z3ED), and additional tools (YAZE_BUILD_TOOLS).
- Ensured consistent build configurations across different platforms to enhance testing and deployment capabilities.
Benefits:
- Improves the completeness of builds in CI and release processes, facilitating better testing and integration of all components.
- Updated CMake files to conditionally link against libprotobuf based on the YAZE_PROTOBUF_TARGET variable across various modules (core, net, agent, z3ed).
- Ensured consistent use of the static MSVC runtime to align with vcpkg static triplets.
- Improved clarity in build logs by adding status messages for whole-archive linking conditions.
Benefits:
- Enhances modularity and compatibility of the build system with protobuf.
- Streamlines the build process for different platforms by ensuring appropriate linking based on configuration options.
- Updated CMake configurations across core, net, agent, and z3ed to conditionally apply /WHOLEARCHIVE linking for libprotobuf based on the compiler ID.
- Added status messages to indicate when /WHOLEARCHIVE linking is skipped for clang-cl, improving clarity in build logs.
Benefits:
- Improves compatibility and clarity in the build process for Windows environments using different compilers.
- Ensures that necessary symbols are included when using MSVC, enhancing build reliability.
- Modified CMake configurations across multiple files to use `$<TARGET_FILE:libprotobuf>` for whole-archive linking on Windows, ensuring all symbols are included correctly.
- This change enhances compatibility and reliability of the build process when using gRPC.
Benefits:
- Improves build stability on Windows platforms by ensuring proper linking of the protobuf library.
- Modified CI configuration to use the D-Bus portal for file dialogs on Linux for improved reliability.
- Updated CMake commands in both CI and release workflows to include the NFD_PORTAL option.
- Removed OpenSSL from vcpkg.json to streamline dependencies.
Benefits:
- Enhances build reliability across different platforms.
- Simplifies dependency management in the project.
- Updated include paths for various GUI-related headers to improve organization and clarity.
- Introduced new components for better modularity, including PaletteEditorWidget and EditorCardManager.
- Refactored existing code to utilize the new components, ensuring consistency across the GUI subsystem.
Benefits:
- Enhances maintainability and readability of the GUI code.
- Facilitates future enhancements and optimizations within the GUI subsystem.
- Updated include paths for various graphics-related headers to improve organization and clarity.
- Introduced new types for SNES color, palette, and tile management, enhancing the structure of the graphics subsystem.
- Refactored existing code to utilize the new types, ensuring consistency across the codebase.
Benefits:
- Improves maintainability and readability of the graphics code.
- Facilitates future enhancements and optimizations within the graphics subsystem.
- Introduced PaletteManager to handle all palette-related operations, including color modifications, undo/redo functionality, and batch processing.
- Updated PaletteEditor and PaletteGroupCard to utilize PaletteManager for managing palette states and modifications, streamlining the editing process.
- Enhanced user interface with confirmation popups for discard actions and error notifications for save failures.
Benefits:
- Centralizes palette management, improving consistency and reducing code duplication across editors.
- Enhances user experience by providing clear feedback on unsaved changes and simplifying color operations.
- Removed experimental test option and modular build option from CMakeLists.txt to simplify configuration.
- Added a definition for YAZE_GUI_TEST_TARGET in the test CMakeLists.txt to mark GUI test targets.
- Updated yaze_test.cc to conditionally register E2E tests only for GUI test targets, enhancing clarity in test registration.
Benefits:
- Streamlined CMake configuration for testing.
- Improved organization of test registration logic for GUI targets.
- Updated CMakeLists.txt to always include GUI test sources when tests are built, removing the conditional check for YAZE_ENABLE_UI_TESTS.
- Added a headless test entry for the entire GUI suite, ensuring consistent execution without a GUI.
Benefits:
- Simplified configuration for GUI tests, enhancing clarity and usability.
- Improved test execution flexibility by allowing headless operation.
- Updated CMake configuration to always include the ImGui Test Engine when tests are enabled, removing conditional checks for UI tests.
- Simplified feature flag management by enabling JSON and gRPC by default, with a minimal build option to disable only the most expensive features.
- Enhanced status messages to provide clearer feedback on build configurations and feature availability.
Benefits:
- Streamlined integration of the ImGui Test Engine for testing purposes.
- Improved clarity in feature flag settings, making it easier to manage build configurations.
- Added conditional compilation for ImGui test engine features in `test_utils.cc` and `test_utils.h`, enabling the loading of ROMs and opening of editors only when the YAZE_ENABLE_IMGUI_TEST_ENGINE flag is set.
- Improved modularity by managing includes based on feature flags, enhancing the flexibility of the testing framework.
Benefits:
- Streamlined testing process for ImGui-related functionalities.
- Enhanced code organization by isolating ImGui test engine dependencies.
- Updated TestConfig to include ImGui test speed options, conditionally compiled based on the YAZE_ENABLE_IMGUI_TEST_ENGINE flag.
- Enhanced command line argument parsing to support new test speed options: --fast, --normal, and --cinematic, improving flexibility for UI testing.
Benefits:
- Improved configurability for testing scenarios involving ImGui.
- Enhanced user experience by allowing more granular control over test execution speed.
- Added option to export compile commands for clangd and other Language Server Protocol (LSP) tools by setting CMAKE_EXPORT_COMPILE_COMMANDS to ON in CMake.
- Updated yaze_test.cc to conditionally include ImGui test engine headers based on the YAZE_ENABLE_IMGUI_TEST_ENGINE flag, improving modularity and organization.
Benefits:
- Enhanced development experience with better integration of LSP tools.
- Improved code organization by managing includes based on feature flags.
- Moved the declaration of `AgentControlServer` to a forward declaration in the header file for better clarity and organization.
- Updated the `EditorManager` constructor to initialize the version string and popup manager context.
- Added conditional compilation for gRPC-related includes and commented out the agent control server initialization for future reference.
- Ensured consistent definition of `IMGUI_DEFINE_MATH_OPERATORS` across multiple files to prevent potential issues with ImGui usage.
Benefits:
- Improved code organization and readability.
- Enhanced maintainability by clarifying the initialization process and managing includes effectively.
- Included the JSON library directory in the test CMake configuration to support JSON functionalities in tests.
- This addition enhances the testing environment by providing necessary dependencies for JSON handling.
Benefits:
- Improved testing capabilities by integrating JSON support.
- Streamlined CMake configuration for better modularity in test setups.
- Updated include paths in several source files to reflect the new directory structure, ensuring consistency across the project.
- Deferred the linkage of the yaze_test_support library to the test.cmake file for better dependency management and ordering.
Benefits:
- Improved organization of include paths for better maintainability.
- Enhanced modularity by managing test dependencies separately.
- Added new include directories for ImGui and SDL to the test CMake configuration, enhancing the testing environment.
- Updated the linkage to include ImGui and SDL targets, ensuring proper integration for GUI tests.
Benefits:
- Improved support for GUI testing by integrating necessary libraries.
- Streamlined the CMake configuration for better modularity in test setups.
- Refactored CMakeLists.txt to streamline project configuration and improve readability.
- Introduced new utility functions in `utils.cmake` for setting compiler flags and managing dependencies.
- Added `dependencies.cmake` to centralize third-party dependency management, enhancing modularity.
- Updated CI workflows to include new build options and improved logging for better feedback during configuration.
- Implemented precompiled headers in various libraries to speed up compilation times.
Benefits:
- Improved maintainability and clarity of the build system.
- Enhanced build performance through precompiled headers.
- Streamlined dependency management for easier integration of third-party libraries.
- Implemented a Command Abstraction Layer to eliminate ~1300 lines of duplicated code across tool commands, enhancing maintainability and consistency.
- Established a unified structure for argument parsing, ROM loading, and output formatting across all commands.
- Added comprehensive documentation, including a Command Abstraction Guide with migration checklists and testing strategies.
- Introduced better testing capabilities for command components, making them AI-friendly and easier to validate.
- Removed legacy command classes and integrated new command handlers for improved functionality.
Benefits:
- Streamlined command handling and improved code quality.
- Enhanced developer experience with clear documentation and testing strategies.
- Maintained backward compatibility with no breaking changes to existing command interfaces.
- Introduced a new method `set_dirty` in the `Rom` class to manage the dirty state of ROM data.
- Updated `DungeonCanvasViewer` to process texture queues before drawing, improving texture readiness and rendering performance.
- Refactored `ObjectDrawer` to utilize `TileInfo` instead of `Tile16`, enhancing tile data handling and consistency across the codebase.
- Improved the `ObjectParser` to read tile data as `TileInfo`, ensuring accurate parsing and memory management.
- Added performance optimizations in the `Room` class to track changes in properties and reduce unnecessary rendering.
- Enhanced logging for debugging purposes during tile drawing and object rendering processes.
- Refactored file paths for performance-related headers to reflect the new directory structure under `app/gfx/performance/`.
- Updated references in the `Canvas` class to align with the new paths, ensuring proper integration of performance monitoring components.
- Cleaned up unnecessary prefixes in performance integration checks to enhance code readability and maintainability.
- Refactored header includes for Performance Profiler and Dashboard to reflect new directory structure under `app/gfx/performance/`.
- Introduced a new `EmulatorTestSuite` class to validate core emulator components, including APU, SPC700, and debugging features.
- Enhanced test suite with detailed test cases for APU handshake, SPC700 cycle accuracy, breakpoint management, and audio backend functionality.
- Removed outdated `test_dungeon_objects.cc` file from the test suite to streamline testing focus.
- Introduced a new document detailing the APU timing issue that prevents music playback due to handshake failures between the CPU and APU.
- Analyzed the CPU-APU handshake process, identifying points of failure and root causes related to cycle inaccuracies in SPC700 emulation.
- Proposed a comprehensive refactoring plan to implement cycle-accurate instruction execution, centralize the APU execution loop, and use integer-based cycle ratios to eliminate floating-point errors.
- This document serves as a critical resource for developers addressing audio emulation challenges.
- Deleted the old D1-dungeon-editor-guide.md and F1-dungeon-editor-guide.md files to streamline documentation.
- Introduced a new DUNGEON_EDITOR_GUIDE.md that consolidates features, architecture, and usage instructions for the Dungeon Editor.
- Updated the development guide to include new naming conventions and clarified rendering processes.
- Enhanced the overall structure and content of the documentation to reflect the current production-ready status of the Dungeon Editor.
- Replaced the deprecated DungeonEditor with DungeonEditorV2, implementing a card-based architecture for improved UI management.
- Updated CMakeLists.txt to reflect changes in source file organization, including renaming dungeon_editor files to their V2 counterparts.
- Refactored DungeonCanvasViewer to support per-room layer visibility settings and updated related methods for rendering and layer management.
- Enhanced testing framework to accommodate the new DungeonEditorV2 structure, including updates to smoke tests and integration tests.
- Removed legacy dungeon_editor files to streamline the codebase and prevent confusion with the new implementation.
- Deleted the ManualObjectRenderer and DungeonRenderer classes to streamline the codebase and reduce redundancy.
- Updated DungeonCanvasViewer and DungeonEditorV2 to remove references to the deleted renderers, ensuring proper functionality without them.
- Enhanced the rendering logic in DungeonCanvasViewer to directly handle object rendering and background layers, improving performance and maintainability.
- Added debug logging to track rendering processes and ensure proper graphics loading.
- Changed the type of dictionary variable from int to int8_t for better type safety.
- Updated the handling of dictionary entries in message parsing to ensure correct formatting and prevent parsing errors with command arguments.
- Refactored message data parsing logic to use index-based loops, improving clarity and correctness in handling command arguments.
- Enhanced the documentation in message_data.h to provide a comprehensive overview of the message data system and its components.
- Added new tests to validate the correct parsing of messages with commands and arguments, ensuring robustness against previous bugs.
- Updated the testing guide to clarify the testing framework's organization and execution methods, improving user understanding.
- Refactored CMakeLists to include new platform-specific files, ensuring proper integration of the rendering backend.
- Modified main application files to utilize the new IRenderer interface, enhancing flexibility in rendering operations.
- Implemented deferred texture management in various components, allowing for more efficient graphics handling and improved performance.
- Introduced new methods for texture creation and updates, streamlining the rendering process across the application.
- Enhanced logging and error handling in the rendering pipeline to facilitate better debugging and diagnostics.
- Updated Emulator::Run method to accept a Rom* parameter, improving flexibility in ROM handling.
- Refactored texture creation and ROM data initialization to utilize the new parameter.
- Enhanced logging in Snes class to provide detailed information during initialization, reset, and frame processing, aiding in debugging and performance monitoring.
- Introduced cycle tracking in Apu and Spc700 classes for accurate synchronization and debugging.
- Added unit tests for APU DSP functionality and IPL ROM handshake to ensure reliability and correctness of audio processing.
- Updated CMakeLists.txt to include additional proto files for canvas automation, enhancing the build process for gRPC services.
- Refactored file_util.cc to use the core namespace for feature flags, improving code clarity and consistency.
- Added new unit tests for CanvasAutomationAPI, covering various functionalities such as coordinate conversion, tile operations, and selection management, ensuring robust testing for canvas automation features.
- Replaced static context menu setup in OverworldEditor with dynamic configuration based on the current map state, improving usability and responsiveness.
- Introduced TileSelectorWidget for better tile selection management, allowing for a more intuitive user experience when selecting tiles.
- Updated canvas controls to include zoom in and zoom out functionalities, enhancing the editor's navigation capabilities.
- Cleaned up legacy context menu code and improved overall organization for better maintainability and clarity.
- Added InitializeForTesting method in Rom class to facilitate testing setup.
- Updated DungeonCanvasViewer to adjust object and sprite sizes from 16x16 to 8x8, improving rendering accuracy.
- Modified rendering logic for various dungeon objects (chests, doors, walls, pots) to reflect new size calculations.
- Adjusted object position calculations in ObjectRenderer to align with the new size metrics, ensuring consistent rendering across the application.
- Updated integration tests to verify the new initialization method for ROM objects.
- Added functionality to save AI agent plans to disk using ProposalRegistry, including directory creation and error handling for failed saves.
- Enhanced AIGUIController with new gRPC GUI automation actions, including click, type, wait, and verify actions, improving interaction capabilities.
- Introduced new command parsing for set-area and replace-tile commands in Tile16ProposalGenerator, allowing for more complex tile modifications.
- Added integration and unit tests for AIGUIController and Tile16ProposalGenerator to ensure robust functionality and error handling.