-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathrun.bat
39 lines (31 loc) · 889 Bytes
/
run.bat
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
@echo off
echo Starting CMake configuration...
cmake -DCMAKE_BUILD_TYPE:STRING=Debug ^
-DCMAKE_EXPORT_COMPILE_COMMANDS:BOOL=TRUE ^
-DCMAKE_C_COMPILER:FILEPATH=C:\msys64\ucrt64\bin\gcc.exe ^
-DCMAKE_CXX_COMPILER:FILEPATH=C:\msys64\ucrt64\bin\g++.exe ^
--no-warn-unused-cli ^
-SC:/Users/Nauval/Documents/Learning/cpp ^
-Bc:/Users/Nauval/Documents/Learning/cpp/build ^
-G "MinGW Makefiles"
if %ERRORLEVEL% neq 0 (
echo CMake configuration failed
pause
exit /b %ERRORLEVEL%
)
echo Building project...
cmake --build c:/Users/Nauval/Documents/Learning/cpp/build --config Debug --target all -j6
if %ERRORLEVEL% neq 0 (
echo Build failed
pause
exit /b %ERRORLEVEL%
)
echo Running executable...
cd c:/Users/Nauval/Documents/Learning/cpp/build/bin/
MyGLFWProject.exe
if %ERRORLEVEL% neq 0 (
echo Program execution failed
pause
exit /b %ERRORLEVEL%
)
pause