Debian Codegraph @

src/vendor/azure-uamqp-c/deps/azure-ctest/jenkins/windows_vs2008_c.cmd

raw
1 @REM Copyright (c) Microsoft. All rights reserved.
2 @REM Licensed under the MIT license. See LICENSE file in the project root for full license information.
3
4 @setlocal EnableExtensions EnableDelayedExpansion
5
6 set build-root=%~dp0..
7 rem // resolve to fully qualified path
8 for %%i in ("%build-root%") do set build-root=%%~fi
9
10 @echo off
11
12 set repo_root=%build-root%\..
13 rem // resolve to fully qualified path
14 for %%i in ("%repo_root%") do set repo_root=%%~fi
15
16 echo Build Root: %build-root%
17 echo Repo Root: %repo_root%
18
19 set CMAKE_DIR=ctest_win32
20
21 rem -----------------------------------------------------------------------------
22 rem -- build with CMAKE and run tests
23 rem -----------------------------------------------------------------------------
24
25 echo CMAKE Output Path: %build-root%\cmake\%CMAKE_DIR%
26
27 if EXIST %build-root%\cmake\%CMAKE_DIR% (
28 rmdir /s/q %build-root%\cmake\%CMAKE_DIR%
29 rem no error checking
30 )
31
32 echo %build-root%\cmake\%CMAKE_DIR%
33 mkdir %build-root%\cmake\%CMAKE_DIR%
34 rem no error checking
35 pushd %build-root%\cmake\%CMAKE_DIR%
36
37 echo ***Running CMAKE for Win32***
38 cmake %build-root% -Drun_unittests:BOOL=ON -Duse_cppunittest:bool=OFF
39 if not !ERRORLEVEL!==0 exit /b !ERRORLEVEL!
40
41 call :_run-msbuild "Build" ctest.sln
42 if not !ERRORLEVEL!==0 exit /b !ERRORLEVEL!
43
44 ctest -C "debug" -V
45 if not !ERRORLEVEL!==0 exit /b !ERRORLEVEL!
46
47 popd
48 goto :eof
49
50 rem -----------------------------------------------------------------------------
51 rem -- subroutines
52 rem -----------------------------------------------------------------------------
53
54 :_run-msbuild
55 rem // optionally override configuration|platform
56 setlocal EnableExtensions
57 set build-target=
58 if "%~1" neq "Build" set "build-target=/t:%~1"
59
60 msbuild /m %build-target% "/p:Configuration=Debug;Platform=Win32" %2
61 if not !ERRORLEVEL!==0 exit /b !ERRORLEVEL!
62 goto :eof
63
64 echo done