X-Git-Url: https://git.proxmox.com/?p=mirror_edk2.git;a=blobdiff_plain;f=Setup%2Fedksetup.bat;fp=Setup%2Fedksetup.bat;h=66494e7d5b45d64a447e5735090bdc34f24de3e0;hp=0000000000000000000000000000000000000000;hb=965958c1ba9564d1051d9df68897f68e24d0f93d;hpb=e8f5c5c02dc879fa2c52f027a273839750150474 diff --git a/Setup/edksetup.bat b/Setup/edksetup.bat new file mode 100644 index 0000000000..66494e7d5b --- /dev/null +++ b/Setup/edksetup.bat @@ -0,0 +1,83 @@ +@REM +@REM Copyright (c) 2006, Intel Corporation +@REM All rights reserved. This program and the accompanying materials +@REM are licensed and made available under the terms and conditions of the BSD License +@REM which accompanies this distribution. The full text of the license may be found at +@REM http://opensource.org/licenses/bsd-license.php +@REM +@REM THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, +@REM WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. +@REM + +@REM usage: edksetup.bat [Reconfig] +@REM if the argument, skip is present, only the paths and the +@REM test and set of environment settings are performed. + +@REM ############################################################## +@REM # You should not have to modify anything below this line +@REM # + +@echo off + +@REM +@REM Set the WORKSPACE to the current working directory +@REM +if not defined WORKSPACE ( + @set WORKSPACE=%CD% +) else ( + @echo WORKSPACE was already set to %WORKSPACE% +) + + +@if /I "%1"=="-h" goto Usage +@if /I "%1"=="-help" goto Usage +@if /I "%1"=="--help" goto Usage +@if /I "%1"=="/h" goto Usage +@if /I "%1"=="/?" goto Usage +@if /I "%1"=="/help" goto Usage + +if defined CYGWIN_HOME goto NewBuild +if exist c:\cygwin ( + set CYGWIN_HOME=c:\cygwin +) else ( + echo. + echo !!! WARNING !!!! Not set CYGWIN_HOME, gcc build may not be used !!! + echo. +) + +goto NewBuild + +:Usage +echo. +echo Usage: %0 [Reconfig] +echo Reconfig: Reinstall target.txt, tools_def.txt, FrameworkDatabase.db. +echo. +echo Note that target.template, tools_def.template, FrameworkDatabase.template will be +echo only copied to target.txt, tools_def.txt, FrameworkDatabase.db respectively if they +echo are not existed. Using option [Reconfig] to do the force copy. +echo. +goto end + +:NewBuild +@IF DEFINED EDK_TOOLS_PATH goto RunToolSetup + +@if exist %WORKSPACE%\BaseTools ( + @set EDK_TOOLS_PATH=%WORKSPACE%\BaseTools +) else ( + echo. + echo The WORKSPACE does not contain a BaseTools directory and + echo the EDK_TOOLS_PATH is not set + echo. + goto Usage +) + +:RunToolSetup +@if /I "%1"=="Reconfig" ( + @call %EDK_TOOLS_PATH%\toolsetup.bat Reconfig +) else ( + @call %EDK_TOOLS_PATH%\toolsetup.bat +) + +:end +@echo on +