模拟器构建入口改VS版本自适应(新增build_sim,兼容VS2019/2022/2026);文档同步并补SDL2 SDK下载步骤

This commit is contained in:
2026-09-21 02:30:16 +08:00
parent d0ec983cdd
commit bad5ceac0d
9 changed files with 246 additions and 51 deletions
+24
View File
@@ -0,0 +1,24 @@
@echo off
rem ============================================================
rem LVGL PC simulator one-shot build (VS2019/2022/2026 auto-detect, x64)
rem Usage (from repo root, any shell):
rem & "simulator\build_sim.bat" incremental build
rem & "simulator\build_sim.bat" -Clean full rebuild
rem & "simulator\build_sim.bat" -Config Release Release build
rem Logic lives in build_sim.ps1 (vswhere probe -> generator mapping);
rem this bat only bypasses the PowerShell execution policy and
rem forwards the arguments. Exit code = build result (0 ok / 1 fail / 3 env).
rem NOTE: keep this file PURE ASCII - cmd parses .bat in the ANSI
rem codepage; UTF-8 Chinese here corrupts the command lines.
rem ============================================================
setlocal
where pwsh >nul 2>nul
if %errorlevel%==0 (
pwsh -NoProfile -ExecutionPolicy Bypass -File "%~dp0build_sim.ps1" %*
goto :done
)
powershell -NoProfile -ExecutionPolicy Bypass -File "%~dp0build_sim.ps1" %*
:done
exit /b %errorlevel%