File: run.bat

package info (click to toggle)
opencascade 7.8.1%2Bdfsg1-7
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 293,924 kB
  • sloc: cpp: 1,249,635; tcl: 15,974; cs: 5,173; java: 1,554; sh: 1,354; ansic: 821; xml: 737; makefile: 30; javascript: 22
file content (40 lines) | stat: -rw-r--r-- 913 bytes parent folder | download | duplicates (7)
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
@echo off

Setlocal EnableDelayedExpansion

if "%1" == "-h" (
  goto err_bat
)

if not ["%4"] == [""] (
  set "SampleName=%4"
  call "%~dp0env.bat" %1 %2 %3
) else if not ["%1"] == [""] (
  set "SampleName=%1"
  call "%~dp0env.bat"
) else (
  goto err_bat
)

if not exist "%~dp0%BIN_DIR%\IE_%SampleName%.exe" goto err_exe

"%~dp0%BIN_DIR%\IE_%SampleName%.exe"

goto eof

:err_bat
echo Possible names of samples: WinForms, WPF_D3D, WPF_WinForms
echo Launch selected sample as follows:
echo   %~n0.bat [^vc10^|^vc11^|^vc12^|^vc14^] [^win32^|^win64^] [^Release^|^Debug^] [^SampleName^]
echo or
echo   %~n0.bat [^SampleName^]
echo Run %~n0.bat -h to get this help
exit /B

:err_exe
echo Executable %~dp0%BIN_DIR%\IE_%SampleName%.exe not found.
echo Check that OCCT and sample are built with the selected configuration:
echo compiler=%VCVER% platform=win%ARCH% %3
exit /B

:eof