build.cmd 635 B

1234567891011121314151617181920212223242526272829303132333435
  1. @echo off
  2. setlocal ENABLEDELAYEDEXPANSION
  3. set basedir=%~dp0
  4. set awlsim_base=%basedir%\..
  5. set PATH=%PATH%;C:\WINDOWS;C:\WINDOWS\SYSTEM32
  6. for /D %%f in ( "C:\PYTHON*" ) do set PATH=!PATH!;%%f
  7. for /D %%f in ( "%USERPROFILE%\AppData\Local\Programs\Python\Python*" ) do set PATH=!PATH!;%%f;%%f\Scripts
  8. cd %awlsim_base%
  9. if ERRORLEVEL 1 goto error_cd
  10. set AWLSIM_CYTHON_BUILD=1
  11. py -3 setup.py build
  12. if ERRORLEVEL 1 goto error_build
  13. echo ---
  14. echo finished
  15. pause
  16. exit /B 0
  17. :error_cd
  18. echo FAILED to cd to base directory
  19. goto error
  20. :error_build
  21. echo FAILED to build Awlsim
  22. goto error
  23. :error
  24. pause
  25. exit 1