Você não pode selecionar mais de 25 tópicos Os tópicos devem começar com uma letra ou um número, podem incluir traços ('-') e podem ter até 35 caracteres.

build.bat 1.6 KiB

5 meses atrás
4 meses atrás
2 meses atrás
2 meses atrás
2 meses atrás
5 meses atrás
4 meses atrás
1234567891011121314151617181920212223242526
  1. @echo off
  2. if NOT EXIST .\build mkdir .\build
  3. set commonLinkerFlags= -opt:ref user32.lib Gdi32.lib winmm.lib
  4. set commonCompilerFlags=^
  5. -MT %= Make sure the C runtime library is statically linked =%^
  6. -Gm- %= Turns off incremently building =%^
  7. -nologo %= No one cares you made the compiler Microsoft =%^
  8. -Oi %= Always use intrinsics =%^
  9. -EHa- %= Disable exception handling =%^
  10. -GR- %= Never use runtime type info from C++ =%^
  11. -WX -W4 -wd4201 -wd4100 -wd4189 %= Compiler warnings, -WX warnings as errors, -W4 warning level 4, -wdXXXX disable warning XXXX =%^
  12. -DHANDMADE_INTERNAL=1 -DHANDMADE_SLOW=1 -DHANDMADE_WIN32=1 %= Custom #defines =%^
  13. -FC %= Full path of source code file in diagnostics =%^
  14. -Zi %= Generate debugger info =%
  15. pushd .\build
  16. cl %commonCompilerFlags% -Fe:handmade.dll ..\src\handmade.cpp -Fmhandmade.map /link /DLL /EXPORT:gameGetSoundSamples /EXPORT:gameUpdateAndRender
  17. cl %commonCompilerFlags% -Fe:handmade_win32.exe ..\src\win32_handmade.cpp -Fmwin32_handmade.map /link %commonLinkerFlags%
  18. popd
  19. exit /b
  20. :error
  21. echo Failed with error #%errorlevel%.
  22. exit /b %errorlevel%