1rem output_params.bat contains:
2rem    (set libr=<lib|dll>)
3rem    (set plat=<win32|x64>)
4rem    (set conf=<debug|release>)
5
6set test_platform=%1
7set test_config=%2
8
9@echo off
10call :clrerr
11
12if exist ..\..\output_params.bat (call ..\..\output_params.bat) else (call :seterr & echo ERROR: 'output_params.bat' not found & exit /b %errorlevel%)
13set out_dir=%libr%\%plat%\%conf%
14
15if /i "%plat%" EQU "" (call :seterr & echo ERROR: 'output_params.bat' is corrupt & exit /b %errorlevel%)
16fc ..\%libr%-%conf%-config.props ..\test-config.props > nul && ((set library=%libr%) & goto cont)
17call :seterr & echo ERROR: cannot determine library type (static or DLL) to test & exit /b %errorlevel%
18
19:cont
20if "%libr%" EQU "lib" if not exist ..\..\..\%out_dir%\mpirxx.lib (call :seterr & echo ERROR: static library tests need 'mpirxx.lib' & exit /b %errorlevel%)
21if /i "%test_platform%" EQU "%plat%" if /i "%test_config%" EQU "%conf%" if /i "%library%" EQU "%libr%" echo OK & exit /b 0
22
23call :seterr
24echo ERROR Last MPIR build was %lib_type%\%plat%\%conf%, not %library%\%test_platform%\%test_config%
25exit /b %errorlevel%
26
27:clrerr
28exit /b 0
29
30:seterr
31exit /b 1
32