-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathbuild.bat
More file actions
64 lines (56 loc) · 1.29 KB
/
build.bat
File metadata and controls
64 lines (56 loc) · 1.29 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
@echo off
echo Building Steam Lua Patcher (C++ Qt6)...
echo.
REM Clean previous build
if exist build rmdir /s /q build
if exist dist rmdir /s /q dist
REM Create build directory
mkdir build
cd build
REM Check for CMake
where cmake >nul 2>&1
if %errorLevel% neq 0 (
echo CMake not found!
if exist setup_build_env.bat (
echo Found environment setup script. Running it...
call setup_build_env.bat
) else (
echo.
echo ERROR: CMake is not in your PATH.
echo Please run 'setup_build_environment.bat' as Administrator to install dependencies.
echo.
pause
exit /b 1
)
)
REM Configure with CMake
echo Configuring with CMake...
cmake -G "MinGW Makefiles" -DCMAKE_BUILD_TYPE=Release ..
if errorlevel 1 (
echo CMake configuration failed!
pause
exit /b 1
)
REM Build
echo.
echo Building...
cmake --build . --config Release
if errorlevel 1 (
echo Build failed!
pause
exit /b 1
)
REM Create distribution folder
echo.
echo Creating distribution...
cd ..
mkdir dist
copy build\SteamLuaPatcher.exe dist\
copy logo.ico dist\ 2>nul
REM Deploy Qt dependencies
echo Deploying Qt dependencies...
windeployqt dist\SteamLuaPatcher.exe --release --no-translations
echo.
echo Build complete! Executable is in 'dist' folder.
echo.
pause