docs: build system refactor design — dual-mode vcpkg + prebuild#82
Draft
Copilot wants to merge 2 commits intocopilot/check-custom-registry-vcpkgfrom
Draft
docs: build system refactor design — dual-mode vcpkg + prebuild#82Copilot wants to merge 2 commits intocopilot/check-custom-registry-vcpkgfrom
Copilot wants to merge 2 commits intocopilot/check-custom-registry-vcpkgfrom
Conversation
Agent-Logs-Url: https://github.com/bluesky013/SkyEngine/sessions/5585620d-c615-4f67-b174-bef0bb818c7e Co-authored-by: yiwenxue <24495793+yiwenxue@users.noreply.github.com>
Copilot
AI
changed the title
[WIP] Refactor build system design for local and prebuild support
docs: build system refactor design — dual-mode vcpkg + prebuild
Mar 29, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The build system has two divergent dependency paths (vcpkg and legacy
3RD_PATH/python/third_party.py) that can silently drift, incomplete triplet auto-detection, no prebuild download path, and ax64-windowsvsx64-windows-staticmismatch across CI and CMake. This document proposes a unified refactor to address all six requirements without requiring immediate implementation.Document:
docs/build-system-refactor.mdDual-Mode Architecture
SKY_PREBUILD_MODE=OFF, default): vcpkg installs from source; all existing3rdParty::alias targets unchanged.SKY_PREBUILD_MODE=ON): downloads a per-triplet archive from CI-published GitHub Releases, unpacks to${CMAKE_BINARY_DIR}/_prebuilts/<triplet>/, setsCMAKE_PREFIX_PATH— then the samesky_packages.cmakeresolves packages identically in both modes.vcpkg Discovery Order
Checks
VCPKG_ROOT→ well-known system paths (%LOCALAPPDATA%\vcpkg,~/.vcpkg,/opt/vcpkg) → local clone bootstrap. Network clone only as last resort.Triplet Auto-Selection (
sky_triplet.cmake)Replaces the ad-hoc
if(WIN32)/elseif(UNIX)block with a full dispatch onCMAKE_SYSTEM_NAME+CMAKE_SYSTEM_PROCESSOR, covering all six triplets. Unifies Windows tox64-windows-staticeverywhere. Flags required fixes toarm64-android.cmake(missingVCPKG_CHAINLOAD_TOOLCHAIN_FILE) andx64-linux.cmake.Package × Triplet Compatibility Matrix
All 26 packages mapped against all 6 triplets (⚠️ / ❌ status and notes for SDL2/iOS/Android exclusions.
x64-windows-static,x64-linux,x64-osx,arm64-osx,arm64-ios,arm64-android) with ✅ /Prebuild CI/CD Design
skyengine-prebuilts-<triplet>-<baseline_short>.tar.zstcmake/prebuild_manifest.json: maps triplet → URL + SHA256, committed to repo, updated by automation after each publish run.sky_prebuild.cmake: SHA256-stamped download + unpack viafile(DOWNLOAD)+file(ARCHIVE_EXTRACT).File Responsibility Map
Defines five new single-responsibility cmake files and retires
cmake/thirdparty.cmake,cmake/vcpkg.cmake,cmake/vcpkg_bootstrap.cmake,python/third_party.py, and the legacyFind*.cmakemodules.Migration Checklist
Three phases: (1) vcpkg stabilization — triplet fixes, CI unification; (2) prebuild infrastructure — manifest schema, download logic, publish workflow; (3) cleanup — retire legacy files, update docs.
Original prompt
💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.