]> git.proxmox.com Git - mirror_edk2.git/blob - BaseTools/Source/C/Makefiles/NmakeSubdirs.bat
License header updated to match correct format.
[mirror_edk2.git] / BaseTools / Source / C / Makefiles / NmakeSubdirs.bat
1 @REM ## @file
2 @REM # Makefile
3 @REM #
4 @REM # Copyright (c) 2007 - 2014, Intel Corporation. All rights reserved.<BR>
5 @REM # This program and the accompanying materials
6 @REM # are licensed and made available under the terms and conditions of the BSD License
7 @REM # which accompanies this distribution. The full text of the license may be found at
8 @REM # http://opensource.org/licenses/bsd-license.php
9 @REM #
10 @REM # THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
11 @REM # WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
12 @REM #
13
14 @echo off
15 @set TOOL_ERROR=0
16 setlocal
17 SET NMAKE_COMMAND=%1
18 SHIFT
19
20 :loop
21 if "%1"=="" goto success
22
23 ECHO Building %1
24 pushd %1
25 nmake %NMAKE_COMMAND%
26 if ERRORLEVEL 1 (
27 set /A TOOL_ERROR= %TOOL_ERROR% + %ERRORLEVEL%
28 goto error
29 )
30 ECHO %1 built successfully (%NMAKE_COMMAND%)
31 ECHO.
32 shift
33 popd
34 goto loop
35
36 :success
37 goto exit
38
39 :error
40 popd
41 set /A TOOL_ERROR=%TOOL_ERROR%+%ERRORLEVEL%
42 ENDLOCAL
43 ECHO Error while making %1!
44 VERIFY OTHER 2>NUL
45
46 :exit
47 exit /B %TOOL_ERROR%