VirtualBox

source: vbox/trunk/src/VBox/Devices/EFI/Firmware/BaseTools/Scripts/ShowEnvironment.bat@ 64529

最後變更 在這個檔案從64529是 58466,由 vboxsync 提交於 9 年 前

EFI/Firmware: Merged in the svn:eol-style, svn:mime-type and trailing whitespace cleanup that was done after the initial UDK2014.SP1 import: svn merge /vendor/edk2/UDK2014.SP1 /vendor/edk2/current .

  • 屬性 svn:eol-style 設為 CRLF
  • 屬性 svn:executable 設為 *
檔案大小: 7.4 KB
 
1@REM @file
2@REM Windows batch file to display the Windows environment
3@REM
4@REM This script will be used to show the current EDK II build environment.
5@REM it may be called by the Edk2Setup.bat (that will be renamed to edksetup.bat) or
6@REM run as stand-alone application.
7@REM
8@REM Copyright (c) 2014, Intel Corporation. All rights reserved.<BR>
9@REM This program and the accompanying materials
10@REM are licensed and made available under the terms and conditions of the BSD License
11@REM which accompanies this distribution. The full text of the license may be found at
12@REM http://opensource.org/licenses/bsd-license.php
13@REM
14@REM THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
15@REM WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
16@REM
17@echo off
18@set SE_SVN_REVISION=$Revision: 8 $
19@set SE_VERSION=0.7.0.
20@if "%SCRIPT%"=="EDKSETUP_BAT" goto SkipCmdlineArgumentCheck
21
22:parse_cmd_line
23@if /I "%1"=="-h" @goto Usage
24@if /I "%1"=="--help" @goto Usage
25@if /I "%1"=="/?" @goto Usage
26@if /I "%1"=="-v" @goto Version
27@if /I "%1"=="--version" @goto Version
28
29:Usage
30@echo Usage: ShowEnvironment.bat [Options]
31@echo Copyright(c) 2014, Intel Corporation. All rights reserved.
32@echo.
33@echo Options:
34@echo --help, -h Print this help screen and exit
35@echo --version, -v Print this tool's version and exit
36@echo.
37@goto End
38
39:Version
40@echo ShowEnvironment.bat Version: %SE_VERSION%%SE_SVN_REVISION:~11,-1%
41@echo Copyright(c) 2014, Intel Corporation. All rights reserved.
42
43:SkipCmdlineArgumentCheck
44if defined SRC_CONF @goto SetEnv
45
46@echo.
47@echo #############################################################################
48@if defined WORKSPACE @echo WORKSPACE = %WORKSPACE%
49@if not defined WORKSPACE @echo WORKSPACE = Not Set
50@if defined EDK_TOOLS_PATH @echo EDK_TOOLS_PATH = %EDK_TOOLS_PATH%
51@if not defined EDK_TOOLS_PATH @echo EDK_TOOLS_PATH = Not Set
52@if defined BASE_TOOLS_PATH @echo BASE_TOOLS_PATH = %BASE_TOOLS_PATH%
53@if defined PYTHON_FREEZER_PATH @echo PYTHON_FREEZER_PATH = %PYTHON_FREEZER_PATH%
54@if "%NT32PKG%"=="TRUE" (
55 @echo.
56 @echo NOTE: Please configure your build to use the following TOOL_CHAIN_TAG
57 @echo when building NT32Pkg/Nt32Pkg.dsc
58 @if defined VCINSTALLDIR @call :CheckVsVer
59 @set TEST_VS=
60)
61@if defined HIDE_PATH goto End
62
63
64@echo ############################## PATH #########################################
65@setlocal DisableDelayedExpansion
66@set "var=%PATH%"
67@set "var=%var:"=""%"
68@set "var=%var:^=^^%"
69@set "var=%var:&=^&%"
70@set "var=%var:|=^|%"
71@set "var=%var:<=^<%"
72@set "var=%var:>=^>%"
73@set "var=%var:;=^;^;%"
74@set var=%var:""="%
75@set "var=%var:"=""Q%"
76@set "var=%var:;;="S"S%"
77@set "var=%var:^;^;=;%"
78@set "var=%var:""="%"
79@setlocal EnableDelayedExpansion
80@set "var=!var:"Q=!"
81@for %%a in ("!var:"S"S=";"!") do (
82 @if "!!"=="" endlocal
83 @if %%a neq "" echo %%~a
84)
85@goto End
86
87:CheckVsVer
88@set "TEST_VS=C:\Program Files (x86)\Microsoft Visual Studio 9.0\"
89@if "%VSINSTALLDIR%"=="%TEST_VS%" (
90 @echo TOOL_CHAIN_TAG = VS2008x86
91 @goto :EOF
92)
93@set "TEST_VS=C:\Program Files\Microsoft Visual Studio 9.0\"
94@if "%VSINSTALLDIR%"=="%TEST_VS%" (
95 @echo TOOL_CHAIN_TAG = VS2008
96 @goto :EOF
97)
98
99@set "TEST_VS=C:\Program Files (x86)\Microsoft Visual Studio 10.0\"
100@if "%VSINSTALLDIR%"=="%TEST_VS%" (
101 @echo TOOL_CHAIN_TAG = VS2010x86
102 @goto :EOF
103)
104@set "TEST_VS=C:\Program Files\Microsoft Visual Studio 10.0\"
105@if "%VSINSTALLDIR%"=="%TEST_VS%" (
106 @echo TOOL_CHAIN_TAG = VS2010
107 @goto :EOF
108)
109
110@set "TEST_VS=C:\Program Files (x86)\Microsoft Visual Studio 11.0\"
111@if "%VSINSTALLDIR%"=="%TEST_VS%" (
112 @echo TOOL_CHAIN_TAG = VS2012x86
113 @goto :EOF
114)
115@set "TEST_VS=C:\Program Files\Microsoft Visual Studio 11.0\"
116@if "%VSINSTALLDIR%"=="%TEST_VS%" (
117 @echo TOOL_CHAIN_TAG = VS2012
118 @goto :EOF
119)
120
121@set "TEST_VS=C:\Program Files (x86)\Microsoft Visual Studio 12.0\"
122@if "%VSINSTALLDIR%"=="%TEST_VS%" (
123 @echo TOOL_CHAIN_TAG = VS2013x86
124 @goto :EOF
125)
126@set "TEST_VS=C:\Program Files\Microsoft Visual Studio 12.0\"
127@if "%VSINSTALLDIR%"=="%TEST_VS%" (
128 @echo TOOL_CHAIN_TAG = VS2013
129 @goto :EOF
130)
131@goto :EOF
132
133:SetEnv
134@set FIRST_COPY=FALSE
135@set MISSING_TARGET_TEMPLATE=FALSE
136@set MISSING_TOOLS_DEF_TEMPLATE=FALSE
137@set MISSING_BUILD_RULE_TEMPLATE=FALSE
138@if not exist "%SRC_CONF%\target.template" @set MISSING_TARGET_TEMPLATE=TRUE
139@if not exist "%SRC_CONF%\tools_def.template" @set MISSING_TOOLS_DEF_TEMPLATE=TRUE
140@if not exist "%SRC_CONF%\build_rule.template" @set MISSING_BUILD_RULE_TEMPLATE=TRUE
141
142@if not exist "%WORKSPACE%\Conf\target.txt" (
143 @if "%MISSING_TARGET_TEMPLATE%"=="TRUE" @goto MissingTemplates
144 @echo copying ... target.template to %WORKSPACE%\Conf\target.txt
145 @copy /Y "%SRC_CONF%\target.template" "%WORKSPACE%\Conf\target.txt" > nul
146 @set FIRST_COPY=TRUE
147)
148@if not exist "%WORKSPACE%\Conf\tools_def.txt" (
149 @if "%MISSING_TOOLS_DEF_TEMPLATE%"=="TRUE" @goto MissingTemplates
150 @echo copying ... tools_def.template to %WORKSPACE%\Conf\tools_def.txt
151 @copy /Y "%SRC_CONF%\tools_def.template" "%WORKSPACE%\Conf\tools_def.txt" > nul
152 @set FIRST_COPY=TRUE
153)
154@if not exist "%WORKSPACE%\Conf\build_rule.txt" (
155 @if "%MISSING_BUILD_RULE_TEMPLATE%"=="TRUE" @goto MissingTemplates
156 @echo copying ... build_rule.template to %WORKSPACE%\Conf\build_rule.txt
157 @copy /Y "%SRC_CONF%\build_rule.template" "%WORKSPACE%\Conf\build_rule.txt" > nul
158 @set FIRST_COPY=TRUE
159)
160
161@if "%FIRST_COPY%"=="TRUE" @goto End
162@if not "%RECONFIG%"=="TRUE" @goto End
163
164@if "%RECONFIG%"=="TRUE" (
165 @echo.
166 @echo Over-writing the files in the WORKSPACE\Conf directory
167 @echo using the default template files
168 @echo.
169 @if "%MISSING_TARGET_TEMPLATE%"=="TRUE" @goto MissingTemplates
170 @echo over-write ... target.template to %WORKSPACE%\Conf\target.txt
171 @copy /Y "%SRC_CONF%\target.template" "%WORKSPACE%\Conf\target.txt" > nul
172
173 @if "%MISSING_TOOLS_DEF_TEMPLATE%"=="TRUE" @goto MissingTemplates
174 @echo over-write ... tools_def.template to %WORKSPACE%\Conf\tools_def.txt
175 @copy /Y "%SRC_CONF%\tools_def.template" "%WORKSPACE%\Conf\tools_def.txt" > nul
176
177 @if "%MISSING_BUILD_RULE_TEMPLATE%"=="TRUE" @goto MissingTemplates
178 @echo over-write ... build_rule.template to %WORKSPACE%\Conf\build_rule.txt
179 @copy /Y "%SRC_CONF%\build_rule.template" "%WORKSPACE%\Conf\build_rule.txt" > nul
180 @goto End
181)
182
183:MissingTemplates
184@echo.
185@if "%RECONFIG%"=="TRUE" @echo ERROR : Reconfig failed
186@if "%MISSING_TARGET_TEMPLATE%"=="TRUE" @echo ERROR : Unable to locate: "%SRC_CONF%\target.template"
187@if "%MISSING_TOOLS_DEF_TEMPLATE%"=="TRUE" @echo ERROR : Unable to locate: "%SRC_CONF%\tools_def.template"
188@if "%MISSING_BUILD_RULE_TEMPLATE%"=="TRUE" @echo ERROR : Unable to locate: "%SRC_CONF%\build_rule.template"
189@echo.
190@set MISSING_TARGET_TEMPLATE=
191@set MISSING_TOOLS_DEF_TEMPLATE=
192@set MISSING_BUILD_RULE_TEMPLATE=
193@set FIRST_COPY=
194@set SE_VERSION=
195@set SE_SVN_REVISION=
196@if not "%SCRIPT%"=="EDKSETUP_BAT" @echo on
197exit /B 1
198
199:End
200@set MISSING_TARGET_TEMPLATE=
201@set MISSING_TOOLS_DEF_TEMPLATE=
202@set MISSING_BUILD_RULE_TEMPLATE=
203@set FIRST_COPY=
204@set SE_VERSION=
205@set SE_SVN_REVISION=
206@if not "%SCRIPT%"=="EDKSETUP_BAT" @echo on
207exit /B 0
注意: 瀏覽 TracBrowser 來幫助您使用儲存庫瀏覽器

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette