重置claude
This commit is contained in:
81
build.bat
Normal file
81
build.bat
Normal file
@@ -0,0 +1,81 @@
|
||||
@echo off
|
||||
chcp 65001 >nul
|
||||
setlocal
|
||||
|
||||
echo ========================================
|
||||
echo EzUI Static Library Build Script
|
||||
echo VS2022 + CMake
|
||||
echo ========================================
|
||||
echo.
|
||||
|
||||
REM Check if CMake is available
|
||||
where cmake >nul 2>&1
|
||||
if %ERRORLEVEL% neq 0 (
|
||||
echo Error: CMake not found. Please install CMake.
|
||||
exit /b 1
|
||||
)
|
||||
|
||||
REM Get the directory of this script
|
||||
set "SCRIPT_DIR=%~dp0"
|
||||
cd /d "%SCRIPT_DIR%"
|
||||
|
||||
REM Clean previous build
|
||||
echo [1/4] Cleaning previous build...
|
||||
if exist "build" rmdir /s /q build
|
||||
if exist "lib\*.lib" del /q "lib\*.lib"
|
||||
if exist "lib\*.pdb" del /q "lib\*.pdb"
|
||||
|
||||
REM Generate and build Win32
|
||||
echo.
|
||||
echo [2/4] Building Win32...
|
||||
cmake -G "Visual Studio 17 2022" -A Win32 -S . -B build\Win32
|
||||
if %ERRORLEVEL% neq 0 (
|
||||
echo Error: CMake generation failed for Win32
|
||||
exit /b 1
|
||||
)
|
||||
|
||||
cmake --build build\Win32 --config Debug
|
||||
if %ERRORLEVEL% neq 0 (
|
||||
echo Error: Build failed for Win32 Debug
|
||||
exit /b 1
|
||||
)
|
||||
|
||||
cmake --build build\Win32 --config Release
|
||||
if %ERRORLEVEL% neq 0 (
|
||||
echo Error: Build failed for Win32 Release
|
||||
exit /b 1
|
||||
)
|
||||
|
||||
REM Generate and build x64
|
||||
echo.
|
||||
echo [3/4] Building x64...
|
||||
cmake -G "Visual Studio 17 2022" -A x64 -S . -B build\x64
|
||||
if %ERRORLEVEL% neq 0 (
|
||||
echo Error: CMake generation failed for x64
|
||||
exit /b 1
|
||||
)
|
||||
|
||||
cmake --build build\x64 --config Debug
|
||||
if %ERRORLEVEL% neq 0 (
|
||||
echo Error: Build failed for x64 Debug
|
||||
exit /b 1
|
||||
)
|
||||
|
||||
cmake --build build\x64 --config Release
|
||||
if %ERRORLEVEL% neq 0 (
|
||||
echo Error: Build failed for x64 Release
|
||||
exit /b 1
|
||||
)
|
||||
|
||||
REM Show results
|
||||
echo.
|
||||
echo [4/4] Build completed!
|
||||
echo.
|
||||
echo Generated libraries:
|
||||
dir /b lib\*.lib
|
||||
echo.
|
||||
echo ========================================
|
||||
echo Build Successful!
|
||||
echo ========================================
|
||||
|
||||
endlocal
|
||||
Reference in New Issue
Block a user