-
Notifications
You must be signed in to change notification settings - Fork 5
Expand file tree
/
Copy pathbuild debug.bat
More file actions
60 lines (52 loc) · 1.61 KB
/
build debug.bat
File metadata and controls
60 lines (52 loc) · 1.61 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
@echo off
setlocal
set "PROJECT=%~dp0uc_online2.vcxproj"
REM Find MSBuild
set "MSBUILD="
for /f "delims=" %%i in ('dir /b /s "C:\Program Files\Microsoft Visual Studio\2022\Professional\MSBuild\Current\Bin\MSBuild.exe" 2^>nul') do (
if not defined MSBUILD set "MSBUILD=%%i"
)
if not defined MSBUILD (
echo [ERROR] MSBuild not found.
echo.
echo You need Visual Studio Build Tools 2022 or later.
echo Install it here: https://visualstudio.microsoft.com/visual-cpp-build-tools/
echo.
echo Select "Desktop development with C++" during installation.
echo.
pause
exit /b 1
)
echo Found MSBuild: %MSBUILD%
echo.
echo ========================================
echo Building x86 (debug) (steam_api.dll)
echo ========================================
"%MSBUILD%" "%PROJECT%" -p:Configuration=Debug -p:Platform=Win32 -m
if %errorlevel% neq 0 (
echo.
echo [ERROR] x86 build failed.
pause
exit /b 1
)
echo x86 debug build succeeded: debbuild\x86\steam_api.dll
echo.
echo ========================================
echo Building x64 (debug) (steam_api64.dll)
echo ========================================
"%MSBUILD%" "%PROJECT%" -p:Configuration=Debug -p:Platform=x64 -m
if %errorlevel% neq 0 (
echo.
echo [ERROR] x64 build failed.
pause
exit /b 1
)
echo x64 debug build succeeded: debbuild\x64\steam_api64.dll
echo.
echo ========================================
echo Both debug builds completed successfully
echo ========================================
echo x86: debbuild\x86\steam_api.dll
echo x64: debbuild\x64\steam_api64.dll
echo ========================================
pause