]>
Commit | Line | Data |
---|---|---|
965958c1 | 1 | @REM\r |
2 | @REM Copyright (c) 2006, Intel Corporation\r | |
3 | @REM All rights reserved. This program and the accompanying materials\r | |
4 | @REM are licensed and made available under the terms and conditions of the BSD License\r | |
5 | @REM which accompanies this distribution. The full text of the license may be found at\r | |
6 | @REM http://opensource.org/licenses/bsd-license.php\r | |
7 | @REM\r | |
8 | @REM THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r | |
9 | @REM WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r | |
10 | @REM\r | |
11 | \r | |
12 | @REM usage: edksetup.bat [Reconfig]\r | |
13 | @REM if the argument, skip is present, only the paths and the\r | |
14 | @REM test and set of environment settings are performed. \r | |
15 | \r | |
16 | @REM ##############################################################\r | |
17 | @REM # You should not have to modify anything below this line\r | |
18 | @REM #\r | |
19 | \r | |
20 | @echo off\r | |
21 | \r | |
22 | @REM\r | |
23 | @REM Set the WORKSPACE to the current working directory\r | |
24 | @REM\r | |
25 | if not defined WORKSPACE (\r | |
26 | @set WORKSPACE=%CD%\r | |
27 | ) else (\r | |
28 | @echo WORKSPACE was already set to %WORKSPACE%\r | |
29 | )\r | |
30 | \r | |
31 | \r | |
32 | @if /I "%1"=="-h" goto Usage\r | |
33 | @if /I "%1"=="-help" goto Usage\r | |
34 | @if /I "%1"=="--help" goto Usage\r | |
35 | @if /I "%1"=="/h" goto Usage\r | |
36 | @if /I "%1"=="/?" goto Usage\r | |
37 | @if /I "%1"=="/help" goto Usage\r | |
38 | \r | |
39 | if defined CYGWIN_HOME goto NewBuild\r | |
40 | if exist c:\cygwin (\r | |
41 | set CYGWIN_HOME=c:\cygwin\r | |
42 | ) else (\r | |
43 | echo.\r | |
44 | echo !!! WARNING !!!! Not set CYGWIN_HOME, gcc build may not be used !!!\r | |
45 | echo.\r | |
46 | )\r | |
47 | \r | |
48 | goto NewBuild\r | |
49 | \r | |
50 | :Usage\r | |
51 | echo.\r | |
52 | echo Usage: %0 [Reconfig]\r | |
53 | echo Reconfig: Reinstall target.txt, tools_def.txt, FrameworkDatabase.db. \r | |
54 | echo.\r | |
55 | echo Note that target.template, tools_def.template, FrameworkDatabase.template will be\r | |
56 | echo only copied to target.txt, tools_def.txt, FrameworkDatabase.db respectively if they\r | |
57 | echo are not existed. Using option [Reconfig] to do the force copy. \r | |
58 | echo.\r | |
59 | goto end\r | |
60 | \r | |
61 | :NewBuild\r | |
62 | @IF DEFINED EDK_TOOLS_PATH goto RunToolSetup\r | |
63 | \r | |
64 | @if exist %WORKSPACE%\BaseTools (\r | |
65 | @set EDK_TOOLS_PATH=%WORKSPACE%\BaseTools\r | |
66 | ) else (\r | |
67 | echo.\r | |
68 | echo The WORKSPACE does not contain a BaseTools directory and\r | |
69 | echo the EDK_TOOLS_PATH is not set\r | |
70 | echo.\r | |
71 | goto Usage\r | |
72 | )\r | |
73 | \r | |
74 | :RunToolSetup\r | |
75 | @if /I "%1"=="Reconfig" (\r | |
76 | @call %EDK_TOOLS_PATH%\toolsetup.bat Reconfig\r | |
77 | ) else (\r | |
78 | @call %EDK_TOOLS_PATH%\toolsetup.bat\r | |
79 | )\r | |
80 | \r | |
81 | :end\r | |
82 | @echo on\r | |
83 | \r |