From bf46e44e1cb6027a072819a2a3aa3be32651f6e1 Mon Sep 17 00:00:00 2001 From: skal Date: Tue, 3 Feb 2026 18:44:41 +0100 Subject: refactor: Task #20 - Platform & Code Hygiene - Consolidated all WebGPU shims and platform-specific logic into src/platform.h. - Refactored platform_init to return PlatformState by value and platform_poll to automatically refresh time and aspect_ratio. - Removed STL dependencies (std::map, std::vector, std::string) from AssetManager and Procedural subsystems. - Fixed Windows cross-compilation by adjusting include paths and linker flags in CMakeLists.txt and updating build_win.sh. - Removed redundant direct inclusions of GLFW/glfw3.h and WebGPU headers across the project. - Applied clang-format and updated documentation. handoff(Gemini): Completed Task #20 and 20.1. Platform abstraction is now unified, and core paths are STL-free. Windows build is stable. --- scripts/build_win.sh | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'scripts') diff --git a/scripts/build_win.sh b/scripts/build_win.sh index c062929..915d1e5 100755 --- a/scripts/build_win.sh +++ b/scripts/build_win.sh @@ -1,13 +1,14 @@ #!/bin/bash set -e -# 1. Build native tools (asset_packer) +# 1. Build native tools echo "Building native tools..." cmake -S . -B build_native -DDEMO_BUILD_TOOLS=OFF -DDEMO_BUILD_TESTS=OFF -cmake --build build_native --target asset_packer seq_compiler -j8 +cmake --build build_native --target asset_packer seq_compiler tracker_compiler_host -j8 ASSET_PACKER_PATH=$(pwd)/build_native/asset_packer SEQ_COMPILER_PATH=$(pwd)/build_native/seq_compiler +TRACKER_COMPILER_PATH=$(pwd)/build_native/tools_host/tracker_compiler_host echo "Cross-compiling for Windows..." cmake -S . -B build_win \ @@ -15,7 +16,8 @@ cmake -S . -B build_win \ -DDEMO_CROSS_COMPILE_WIN32=ON \ -DDEMO_STRIP_ALL=ON \ -DASSET_PACKER_PATH=$ASSET_PACKER_PATH \ - -DSEQ_COMPILER_PATH=$SEQ_COMPILER_PATH + -DSEQ_COMPILER_PATH=$SEQ_COMPILER_PATH \ + -DTRACKER_COMPILER_PATH=$TRACKER_COMPILER_PATH cmake --build build_win -j8 -- cgit v1.2.3