]> git.proxmox.com Git - mirror_edk2.git/blob - Tools/bin/SAVerify.bat
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@981 6f19259b...
[mirror_edk2.git] / Tools / bin / SAVerify.bat
1 @REM
2 @REM Copyright (c) 2006, Intel Corporation
3 @REM All rights reserved. This program and the accompanying materials
4 @REM are licensed and made available under the terms and conditions of the BSD License
5 @REM which accompanies this distribution. The full text of the license may be found at
6 @REM http://opensource.org/licenses/bsd-license.php
7 @REM
8 @REM THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
9 @REM WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
10 @REM
11
12 @if "%JAVA_HOME%"=="" goto no_jdk
13 @if "%WORKSPACE%"=="" goto no_wks
14
15 @if "%1"=="" (goto usage)
16 @if "%1"=="-h" (goto usage)
17 @if "%1"=="-H" (goto usage)
18 @if "%1"=="all" (goto all)
19 @if "%1"=="ALL" (goto all) else (goto standalone)
20
21 :usage
22 @echo off
23 @echo.
24 @echo Verify SurfaceArea file(s)
25 @echo.
26 @echo Usage:
27 @echo SAVerify.bat "MSA_FILE" - Verify SurfaceArea file named by MSA_FILE
28 @echo SAVerify.bat all - Verify all SurfaceArea files under current directory and its sub-directories
29 @echo SAVerify.bat -h - Print usage message
30 @echo.
31 goto end
32
33 :all
34 @echo off
35 @for /R %%a in (*.msa *.fpd *.spd) do @ant -q -f %WORKSPACE%\Tools\Source\SurfaceArea\build.xml validate -DSURFACE_AREA_FILE=%%a
36 @echo on
37 @goto end
38
39 :standalone
40 @ant -q -f %WORKSPACE%\Tools\Source\SurfaceArea\build.xml validate -DSURFACE_AREA_FILE=%~f1
41 @goto end
42
43 :no_jdk
44 @echo.
45 @echo !!! Please set JAVA_HOME !!!
46 @echo.
47 @goto end
48
49 :no_wks
50 @echo.
51 @echo !!! Please set WORKSPACE !!!
52 @echo.
53 @goto end
54
55 :end