starpu_exec.bat 1.6 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859
  1. @ECHO OFF
  2. REM StarPU --- Runtime system for heterogeneous multicore architectures.
  3. REM
  4. REM Copyright (C) 2013 Centre National de la Recherche Scientifique
  5. REM
  6. REM StarPU is free software; you can redistribute it and/or modify
  7. REM it under the terms of the GNU Lesser General Public License as published by
  8. REM the Free Software Foundation; either version 2.1 of the License, or (at
  9. REM your option) any later version.
  10. REM
  11. REM StarPU is distributed in the hope that it will be useful, but
  12. REM WITHOUT ANY WARRANTY; without even the implied warranty of
  13. REM MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
  14. REM
  15. REM See the GNU Lesser General Public License in COPYING.LGPL for more details.
  16. TITLE MSVC StarPU Execution
  17. ECHO.
  18. ECHO MSVC StarPU Execution
  19. IF NOT EXIST %STARPUPATH%\AUTHORS GOTO starpunotfound
  20. ECHO.
  21. ECHO Using StarPU in %STARPUPATH%
  22. IF "%1" == "" GOTO invalidparam
  23. IF NOT EXIST %1 GOTO invalidparam
  24. mkdir starpu
  25. FOR %%F IN (%STARPUPATH%\bin\*dll) DO COPY %%F starpu\%%~nF
  26. FOR %%F IN (%STARPUPATH%\bin\*dll) DO COPY %%F starpu
  27. COPY c:\MinGW\bin\pthreadGC2.dll starpu
  28. COPY %STARPUPATH%\lib\libstarpu-1.0.lib starpu
  29. set OLDPATH=%PATH%
  30. call "C:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\vcvarsall.bat" x86
  31. echo cd starpu
  32. echo dir %STARPUPATH%\include\starpu\1.0
  33. cl %1 /I%STARPUPATH%\include\starpu\1.0 /link starpu\libstarpu-1.0.lib
  34. set PATH=starpu;%PATH%
  35. .\%~n1.exe
  36. set PATH=%OLDPATH%
  37. GOTO end
  38. :invalidparam
  39. ECHO.
  40. ECHO Syntax error. You need to give the name of a StarPU application
  41. GOTO end
  42. :starpunotfound
  43. ECHO.
  44. ECHO You need to set the variable STARPUPATH to a valid StarPU installation directory
  45. GOTO end
  46. :end