[edk2-devel] [edk2-platforms] [PATCH] ClevoOpenBoardPkg: Remove batch build scripts

Agyeman, Prince posted 1 patch 18 weeks ago
Failed in applying to current master (apply log)
.../ClevoOpenBoardPkg/N1xxWU/GitEdk2Clevo.bat |  79 -------
.../Intel/ClevoOpenBoardPkg/N1xxWU/bld.bat    | 159 -------------
.../Intel/ClevoOpenBoardPkg/N1xxWU/cln.bat    |  48 ----
.../ClevoOpenBoardPkg/N1xxWU/postbuild.bat    |  39 ----
.../ClevoOpenBoardPkg/N1xxWU/prebuild.bat     | 214 ------------------
.../Intel/ClevoOpenBoardPkg/N1xxWU/prep.bat   |  79 -------
6 files changed, 618 deletions(-)
delete mode 100644 Platform/Intel/ClevoOpenBoardPkg/N1xxWU/GitEdk2Clevo.bat
delete mode 100644 Platform/Intel/ClevoOpenBoardPkg/N1xxWU/bld.bat
delete mode 100644 Platform/Intel/ClevoOpenBoardPkg/N1xxWU/cln.bat
delete mode 100644 Platform/Intel/ClevoOpenBoardPkg/N1xxWU/postbuild.bat
delete mode 100644 Platform/Intel/ClevoOpenBoardPkg/N1xxWU/prebuild.bat
delete mode 100644 Platform/Intel/ClevoOpenBoardPkg/N1xxWU/prep.bat

[edk2-devel] [edk2-platforms] [PATCH] ClevoOpenBoardPkg: Remove batch build scripts

Posted by Agyeman, Prince 18 weeks ago
Ref: https://bugzilla.tianocore.org/show_bug.cgi?id=1775

Removed batch build scripts as they are replaced

by build_bios.py

Signed-off-by: Agyeman <prince.agyeman@intel.com>
---
 .../ClevoOpenBoardPkg/N1xxWU/GitEdk2Clevo.bat |  79 -------
 .../Intel/ClevoOpenBoardPkg/N1xxWU/bld.bat    | 159 -------------
 .../Intel/ClevoOpenBoardPkg/N1xxWU/cln.bat    |  48 ----
 .../ClevoOpenBoardPkg/N1xxWU/postbuild.bat    |  39 ----
 .../ClevoOpenBoardPkg/N1xxWU/prebuild.bat     | 214 ------------------
 .../Intel/ClevoOpenBoardPkg/N1xxWU/prep.bat   |  79 -------
 6 files changed, 618 deletions(-)
 delete mode 100644 Platform/Intel/ClevoOpenBoardPkg/N1xxWU/GitEdk2Clevo.bat
 delete mode 100644 Platform/Intel/ClevoOpenBoardPkg/N1xxWU/bld.bat
 delete mode 100644 Platform/Intel/ClevoOpenBoardPkg/N1xxWU/cln.bat
 delete mode 100644 Platform/Intel/ClevoOpenBoardPkg/N1xxWU/postbuild.bat
 delete mode 100644 Platform/Intel/ClevoOpenBoardPkg/N1xxWU/prebuild.bat
 delete mode 100644 Platform/Intel/ClevoOpenBoardPkg/N1xxWU/prep.bat

diff --git a/Platform/Intel/ClevoOpenBoardPkg/N1xxWU/GitEdk2Clevo.bat b/Platform/Intel/ClevoOpenBoardPkg/N1xxWU/GitEdk2Clevo.bat
deleted file mode 100644
index 81f51b3785..0000000000
--- a/Platform/Intel/ClevoOpenBoardPkg/N1xxWU/GitEdk2Clevo.bat
+++ /dev/null
@@ -1,79 +0,0 @@
-@REM @file
-@REM
-@REM Copyright (c) 2019, Intel Corporation. All rights reserved.<BR>
-@REM SPDX-License-Identifier: BSD-2-Clause-Patent
-@REM
-
-@echo off
-
-pushd ..\..\..\..\..\
-
-@REM Set WORKSPACE environment.
-set WORKSPACE=%cd%
-echo.
-echo Set WORKSPACE as: %WORKSPACE%
-echo.
-
-@REM Check whether Git has been installed and been added to system path.
-git --help >nul 2>nul
-if %ERRORLEVEL% NEQ 0 (
-  echo.
-  echo The 'git' command is not recognized.
-  echo Please make sure that Git is installed and has been added to system path.
-  echo.
-  goto :EOF
-)
-
-@REM Create the Conf directory under WORKSPACE
-if not exist %WORKSPACE%\Conf (
-  mkdir Conf
-)
-
-@REM Set other environments.
-@REM Basic Rule:
-@REM   Platform override Silicon override Core
-@REM   Source override Binary
-
-set PACKAGES_PATH=%WORKSPACE%\edk2-platforms\Platform\Intel;%WORKSPACE%\edk2-platforms\Silicon\Intel;%WORKSPACE%\edk2-non-osi\Silicon\Intel;%WORKSPACE%\FSP;%WORKSPACE%\edk2;%WORKSPACE%
-set EDK_TOOLS_BIN=%WORKSPACE%\edk2-BaseTools-win32
-
-@if not defined PYTHON_HOME (
-  @if exist C:\Python27 (
-    set PYTHON_HOME=C:\Python27
-  )
-)
-
-set EDK_SETUP_OPTION=
-@rem if python is installed, disable the binary base tools.
-if defined PYTHON_HOME (
-  set EDK_TOOLS_BIN=
-  set EDK_SETUP_OPTION=--nt32
-)
-pushd %WORKSPACE%\edk2
-call edksetup.bat %EDK_SETUP_OPTION%
-popd
-pushd %WORKSPACE%
-@rem if python is installed, nmake BaseTools source and enable BaseTools source build
-@if defined PYTHON_HOME (
-  nmake -f %BASE_TOOLS_PATH%\Makefile
-)
-popd
-
-set openssl_path=%WORKSPACE%
-
-popd
-
-goto :EOF
-
-:Help
-echo.
-echo Usage:
-echo GitEdk2.bat [-w Workspace_Directory] (optional) [-b Branch_Name] (optional)
-echo.
-echo -w    A absolute/relative path to be the workspace.
-echo       Default value is the current directory.
-echo.
-echo -b    The branch name of the repository. Currently, only master, udk2015,
-echo       trunk (same as master) and bp13 (same as udk2015) are supported.
-echo       Default value is master.
-echo.
diff --git a/Platform/Intel/ClevoOpenBoardPkg/N1xxWU/bld.bat b/Platform/Intel/ClevoOpenBoardPkg/N1xxWU/bld.bat
deleted file mode 100644
index 606ce979a7..0000000000
--- a/Platform/Intel/ClevoOpenBoardPkg/N1xxWU/bld.bat
+++ /dev/null
@@ -1,159 +0,0 @@
-@REM @file
-@REM
-@REM Copyright (c) 2019, Intel Corporation. All rights reserved.<BR>
-@REM SPDX-License-Identifier: BSD-2-Clause-Patent
-@REM
-
-:: Useage: bld [/s] [/f <FEATURE_PCD_NAME> <FALSE or TRUE>] [/r]
-::
-:: For a given build command, 3 options may be passed into this batch file via command prompt:
-:: 1) /s = Redirects all output to a file called EDK2.log(Prep.log must be existed), which will be located at the root.
-:: 2) /f = Defines the passing in of a single override to a feature PCD that is used in the platform
-::    DSC file.  If this parameter is used, it is to be followed immediately after by both the feature
-::    pcd name and value. FeaturePcd is the full PCD name, like gMinPlatformPkgTokenSpaceGuid.PcdOptimizeCompilerEnable
-:: 3) /r = Useful for faster rebuilds when no changes have been made to .inf files. Passes -u to
-::    build.exe to skip the generation of makefiles.
-:: 4) rom = Build Bios.rom only and building SPIs will be skipped.
-::
-
-@echo on
-
-cd %WORKSPACE%
-
-@REM
-@REM Build FSP Binary
-@REM
-@if not defined FSP_BINARY_BUILD goto :SkipFspBinaryBuild
-@if %FSP_BINARY_BUILD% EQU FALSE goto :SkipFspBinaryBuild
-@set FSP_BUILD_PARAMETER=/d
-@set FSP_PKG_NAME=KabylakeFspPkg
-@if /I "%TARGET%" == "RELEASE" (
-  @if "%FSP_TEST_RELEASE%"=="TRUE" (
-    set FSP_BUILD_PARAMETER=/tr
-  ) else (
-    set FSP_BUILD_PARAMETER=/r
-  )
-)
-
-@if %FSP_WRAPPER_BUILD% EQU FALSE goto :BldEnd
-:SkipFspBinaryBuild
-
-@if %FSP_WRAPPER_BUILD% EQU FALSE goto :SkipPatchFspBinFvsBaseAddress
-del /f %WORKSPACE_FSP_BIN%\KabylakeFspBinPkg\Fsp_Rebased*.fd
-
-cd %WORKSPACE%
-
-if exist %WORKSPACE_PLATFORM%\%PROJECT%\OpenBoardPkgPcd.dsc attrib -r %WORKSPACE_PLATFORM%\%PROJECT%\OpenBoardPkgPcd.dsc
-@call %PYTHON_HOME%\python.exe %WORKSPACE_PLATFORM%\%PLATFORM_PACKAGE%\Tools\Fsp\RebaseAndPatchFspBinBaseAddress.py %WORKSPACE_PLATFORM%\%PROJECT%\Include\Fdf\FlashMapInclude.fdf %WORKSPACE_FSP_BIN%\KabylakeFspBinPkg Fsp.fd %WORKSPACE_PLATFORM%\%PROJECT%\OpenBoardPkgPcd.dsc 0x0
-
-@if %ERRORLEVEL% NEQ 0 (
-  @echo !!! ERROR:RebaseAndPatchFspBinBaseAddress failed!!!
-  set SCRIPT_ERROR=1
-  goto :BldFail
-)
-
-cd %WORKSPACE%
-
-copy /y /b %WORKSPACE_FSP_BIN%\KabylakeFspBinPkg\Fsp_Rebased_S.fd+%WORKSPACE_FSP_BIN%\KabylakeFspBinPkg\Fsp_Rebased_M.fd+%WORKSPACE_FSP_BIN%\KabylakeFspBinPkg\Fsp_Rebased_T.fd %WORKSPACE_FSP_BIN%\KabylakeFspBinPkg\Fsp_Rebased.fd
-:SkipPatchFspBinFvsBaseAddress
-
-
-@SET SILENT_MODE=FALSE
-@SET REBUILD_MODE=
-@SET BUILD_ROM_ONLY=
-
-:: Loop through arguements until all are processed
-
-:BUILD_FLAGS_LOOP
-
-@if "%~1" == "" goto BUILD_FLAGS_LOOP_DONE
-
-@if "%~1" == "/f" (
-  shift
-  goto BUILD_FLAGS_LOOP
-)
-@if "%~1" == "/s" (
-  SET SILENT_MODE=TRUE
-  shift
-  goto BUILD_FLAGS_LOOP
-)
-@if "%~1" == "/r" (
-  SET REBUILD_MODE=-u
-  shift
-  goto BUILD_FLAGS_LOOP
-)
-@if "%~1" == "rom" (
-  SET BUILD_ROM_ONLY=rom
-  shift
-  goto BUILD_FLAGS_LOOP
-)
-:: Unknown build flag.
-shift
-goto BUILD_FLAGS_LOOP
-:BUILD_FLAGS_LOOP_DONE
-
-:: Output the build variables the user has selected.
-
-@echo.
-@echo  User Selected build options:
-@echo    SILENT_MODE = %SILENT_MODE%
-@echo    REBUILD_MODE = %REBUILD_MODE%
-@echo    BUILD_ROM_ONLY = %BUILD_ROM_ONLY%
-@echo.
-
-@if %SILENT_MODE% EQU TRUE goto BldSilent
-
-call build -n %NUMBER_OF_PROCESSORS% %REBUILD_MODE% %EXT_BUILD_FLAGS%
-
-@if %ERRORLEVEL% NEQ 0 goto BldFail
-@echo.
-@echo Running postbuild.bat to complete the build process.
-@echo.
-call %WORKSPACE_PLATFORM%\%PROJECT%\postbuild.bat %BUILD_ROM_ONLY%
-@if %SCRIPT_ERROR% EQU 1 goto BldFail
-@goto BldSuccess
-
-:BldSilent
-@if exist Build.log del Build.log
-
-@echo. > Build.log
-@echo ************************************************************************ >> Build.log
-@echo ***********             Build.bat is launched here           *********** >> Build.log
-@echo ************************************************************************ >> Build.log
-@echo. >> Build.log
-
-call build -n %NUMBER_OF_PROCESSORS% %REBUILD_MODE% %EXT_BUILD_FLAGS% 1>>Build.log 2>&1
-
-@if %ERRORLEVEL% NEQ 0 goto BldFail
-@echo. >> Build.log
-@echo Running postbuild.bat to complete the build process. >> Build.log
-@echo. >> Build.log
-@call %WORKSPACE_PLATFORM%\%PROJECT%\postbuild.bat %BUILD_ROM_ONLY% 1>>Build.log 2>&1
-@If %SCRIPT_ERROR% EQU 1 goto BldFail
-
-:BldSuccess
-@echo.
-@echo TARGET:               %TARGET%
-@echo TOOL_CHAIN_TAG:       %TOOL_CHAIN_TAG%
-@echo BIOS location:        %BUILD_DIR%\FV
-@echo.
-@echo The EDKII BIOS build has successfully completed!
-@echo.
-@REM
-
-@goto BldEnd
-
-:BldFail
-cd %WORKSPACE_PLATFORM%\%PROJECT%
-@echo.
-@echo The EDKII BIOS Build has failed!
-@echo.
-@exit /b 1
-
-:BldEnd
-@if %SILENT_MODE% EQU TRUE (
-  @if exist EDK2.log del EDK2.log
-  @if exist Prep.log if exist Build.log copy Prep.log+Build.log EDK2.log
-)
-
-cd %WORKSPACE_PLATFORM%\%PROJECT%
\ No newline at end of file
diff --git a/Platform/Intel/ClevoOpenBoardPkg/N1xxWU/cln.bat b/Platform/Intel/ClevoOpenBoardPkg/N1xxWU/cln.bat
deleted file mode 100644
index 61c8a7d1a4..0000000000
--- a/Platform/Intel/ClevoOpenBoardPkg/N1xxWU/cln.bat
+++ /dev/null
@@ -1,48 +0,0 @@
-@REM @file
-@REM
-@REM Copyright (c) 2019, Intel Corporation. All rights reserved.<BR>
-@REM SPDX-License-Identifier: BSD-2-Clause-Patent
-@REM
-
-@echo off
-echo.
-echo Run build cleanall...
-echo.
-
-cd ..
-
-if not defined WORKSPACE set WORKSPACE=%cd%
-if not defined WORKSPACE_PLATFORM set WORKSPACE_PLATFORM=%cd%
-if not defined WORKSPACE_SILICON set WORKSPACE_SILICON=%cd%
-
-REM build cleanall
-
-echo.
-echo Directories to clean...
-echo.
-
-if exist %WORKSPACE%\build rmdir /q /s %WORKSPACE%\build
-if exist %WORKSPACE%\conf\.cache rmdir /q /s %WORKSPACE%\conf\.cache
-
-echo.
-echo Files to clean...
-echo.
-
-if exist %WORKSPACE%\edk2.log del %WORKSPACE%\edk2.log
-if exist %WORKSPACE%\Conf\build_rule.txt del %WORKSPACE%\Conf\build_rule.txt
-if exist %WORKSPACE%\Conf\FrameworkDatabase.db del %WORKSPACE%\Conf\FrameworkDatabase.db
-if exist %WORKSPACE%\Conf\target.txt del %WORKSPACE%\Conf\target.txt
-if exist %WORKSPACE%\Conf\tools_def.txt del %WORKSPACE%\Conf\tools_def.txt
-@REM *.c.c is generated by Catalog Debug feature across code tree.
-@REM
-del /s *.c.c > nul 2>&1
-
-cd %WORKSPACE_PLATFORM%\%PROJECT%
-
-del /f /q Prep.log > nul 2>&1
-del /f /q ..\Build.log > nul 2>&1
-
-echo.
-echo All done...
-echo.
-@echo on
diff --git a/Platform/Intel/ClevoOpenBoardPkg/N1xxWU/postbuild.bat b/Platform/Intel/ClevoOpenBoardPkg/N1xxWU/postbuild.bat
deleted file mode 100644
index 5553645fbf..0000000000
--- a/Platform/Intel/ClevoOpenBoardPkg/N1xxWU/postbuild.bat
+++ /dev/null
@@ -1,39 +0,0 @@
-@REM @file
-@REM
-@REM Copyright (c) 2019, Intel Corporation. All rights reserved.<BR>
-@REM SPDX-License-Identifier: BSD-2-Clause-Patent
-@REM
-
-@REM #
-@REM #  Module Name:
-@REM #
-@REM #    postbuild.bat
-@REM #
-@REM #  Abstract:
-@REM #
-@REM #    Post build script.
-@REM #
-@REM #--*/
-
-@set SCRIPT_ERROR=0
-
-@if /I not "%0" == "%WORKSPACE_PLATFORM%\%PROJECT%\postbuild.bat" (
-  if /I not "%0" == "%WORKSPACE_PLATFORM%\%PROJECT%\postbuild" (
-    echo.
-    echo !!! ERROR !!! This postbuild.bat must run under workspace root using "%WORKSPACE_PLATFORM%\%PROJECT%\postbuild.bat" !!!
-    echo.
-    set SCRIPT_ERROR=1
-    goto :EOF
-  )
-)
-
-@cd %WORKSPACE_PLATFORM%
-
-@cd %WORKSPACE%
-
-@if %FSP_WRAPPER_BUILD% EQU TRUE (
-  del /f %WORKSPACE_FSP_BIN%\KabylakeFspBinPkg\Fsp_Rebased*.fd
-)
-
-@if %FSP_WRAPPER_BUILD% EQU TRUE exit /b
-
diff --git a/Platform/Intel/ClevoOpenBoardPkg/N1xxWU/prebuild.bat b/Platform/Intel/ClevoOpenBoardPkg/N1xxWU/prebuild.bat
deleted file mode 100644
index c18dd5e89d..0000000000
--- a/Platform/Intel/ClevoOpenBoardPkg/N1xxWU/prebuild.bat
+++ /dev/null
@@ -1,214 +0,0 @@
-@REM @file
-@REM  Pre build script.
-@REM
-@REM Copyright (c) 2019, Intel Corporation. All rights reserved.<BR>
-@REM SPDX-License-Identifier: BSD-2-Clause-Patent
-@REM
-
-cd ..
-
-@REM
-@REM Set build capsule flag with default being OFF
-@REM
-
-@set CAPSULE_BUILD=0
-
-@if /I "%2" == "TRUE" (
-  @set CAPSULE_BUILD=1
-  goto StartCapsulePrep
-)
-
-:StartCapsulePrep
-@REM
-@REM Define platform specific environment variables.
-@REM
-if not defined WORKSPACE_PLATFORM set WORKSPACE_PLATFORM=%WORKSPACE%\edk2-platforms\Platform\Intel
-if not defined WORKSPACE_SILICON set WORKSPACE_SILICON=%WORKSPACE%\edk2-platforms\Silicon\Intel
-if not defined WORKSPACE_PLATFORM_BIN set WORKSPACE_PLATFORM_BIN=%WORKSPACE%\edk2-non-osi\Platform\Intel
-if not defined WORKSPACE_SILICON_BIN set WORKSPACE_SILICON_BIN=%WORKSPACE%\edk2-non-osi\Silicon\Intel
-if not defined WORKSPACE_FSP_BIN set WORKSPACE_FSP_BIN=%WORKSPACE%\FSP
-if not defined WORKSPACE_CORE set WORKSPACE_CORE=%WORKSPACE%\edk2
-if not defined PLATFORM_PACKAGE set PLATFORM_PACKAGE=MinPlatformPkg
-if not defined PLATFORM_BOARD_PACKAGE set PLATFORM_BOARD_PACKAGE=ClevoOpenBoardPkg
-if not defined BOARD set BOARD=N1xxWU
-if not defined PROJECT set PROJECT=%PLATFORM_BOARD_PACKAGE%\%BOARD%
-
-@set SCRIPT_ERROR=0
-
-@set CATALOG_DEBUG=0
-
-@REM Set basic environment.
-@echo.
-@echo Prebuild:  Run edksetup.bat batch file.
-@echo.
-@if %CATALOG_DEBUG% == 0 (
-  @del Conf\build_rule.txt
-)
-cd %WORKSPACE_CORE%
-@call edksetup.bat
-cd %WORKSPACE%
-@set EFI_SOURCE=%WORKSPACE_CORE%
-
-@REM
-@REM Setup Visual Studio environment. Order of precedence is 2012, 2013, 2010 and then 2008.
-@REM
-@REM NOTE: To override precedence set TOOL_CHAIN_TAG before calling prep.bat.
-@REM       Example: set TOOL_CHAIN_TAG=VS2008
-@REM
-
-@REM Check if tool chain has not been selected and Visual Studio 2014 is installed.
-@if not defined TOOL_CHAIN_TAG (
-  if defined VS140COMNTOOLS (
-    set TOOL_CHAIN_TAG=VS2015
-  )
-)
-
-@REM If Visual Studio 2014 is selected by priority or by preference, setup the environment variables.
-@if /I "%TOOL_CHAIN_TAG%"=="VS2015" (
-  echo.
-  echo Prebuild:  Set the VS2015 environment.
-  echo.
-  if not defined VSINSTALLDIR call "%VS140COMNTOOLS%\vsvars32.bat"
-  if /I "%VS140COMNTOOLS%" == "C:\Program Files\Microsoft Visual Studio 14.0\Common7\Tools\" (
-    set TOOL_CHAIN_TAG=VS2015
-  ) else (
-    set TOOL_CHAIN_TAG=VS2015x86
-  )
-)
-
-@REM Check if tool chain has not been selected and Visual Studio 2013 is installed.
-@if not defined TOOL_CHAIN_TAG (
-  if defined VS120COMNTOOLS (
-    set TOOL_CHAIN_TAG=VS2013
-  )
-)
-
-@REM If Visual Studio 2013 is selected by priority or by preference, setup the environment variables.
-@if /I "%TOOL_CHAIN_TAG%"=="VS2013" (
-  echo.
-  echo Prebuild:  Set the VS2013 environment.
-  echo.
-  if not defined VSINSTALLDIR call "%VS120COMNTOOLS%\vsvars32.bat"
-  if /I "%VS120COMNTOOLS%" == "C:\Program Files\Microsoft Visual Studio 12.0\Common7\Tools\" (
-    set TOOL_CHAIN_TAG=VS2013
-  ) else (
-    set TOOL_CHAIN_TAG=VS2013x86
-  )
-)
-
-@REM If no supported version of Visual Studio was detected, return an error.
-@if not defined TOOL_CHAIN_TAG (
-  echo.
-  echo !!! ERROR !!! Visual Studio not installed correctly!!!
-  echo.
-  set SCRIPT_ERROR=1
-  goto :EndPreBuild
-)
-
-echo Show CL revision
-cl
-
-@REM Set build TARGET.
-@if /I "%1" == "" (
-  set TARGET=DEBUG
-  set TARGET_SHORT=D
-) else if /I "%1" == "DEBUG" (
-  set TARGET=DEBUG
-  set TARGET_SHORT=D
-) else if /I "%1" == "TEST_RELEASE" (
-  set TARGET=RELEASE
-  set TARGET_SHORT=R
-) else if /I "%1" == "RELEASE" (
-  set TARGET=RELEASE
-  set TARGET_SHORT=R
-) else if /I "%1" == "RELEASE_PDB" (
-  set TARGET=RELEASE
-  set TARGET_SHORT=R
-) else (
-  echo.
-  echo !!! ERROR !!! Incorrect TARGET option for prebuild.bat. !!!
-  echo.
-  set SCRIPT_ERROR=1
-  goto :EndPreBuild
-)
-
-@set BUILD_DIR_PATH=%WORKSPACE%\Build\%PROJECT%\%TARGET%_%TOOL_CHAIN_TAG%
-@set BUILD_DIR=Build\%PROJECT%\%TARGET%_%TOOL_CHAIN_TAG%
-@set BUILD_X64=%BUILD_DIR_PATH%\X64
-@set BUILD_IA32=%BUILD_DIR_PATH%\IA32
-
-
-@echo.
-@echo Prebuild:  Set build environment.
-@echo.
-@if not exist %BUILD_DIR_PATH% (
-  mkdir %BUILD_DIR_PATH%
-)
-
-@findstr /V "ACTIVE_PLATFORM TARGET TARGET_ARCH TOOL_CHAIN_TAG BUILD_RULE_CONF" %WORKSPACE%\Conf\target.txt > %BUILD_DIR_PATH%\target.txt
-@echo ACTIVE_PLATFORM = %WORKSPACE_PLATFORM%/%PLATFORM_BOARD_PACKAGE%/%BOARD%/OpenBoardPkg.dsc        >> %BUILD_DIR_PATH%\target.txt
-@echo TARGET          = %TARGET%                                  >> %BUILD_DIR_PATH%\target.txt
-@echo TARGET_ARCH     = IA32 X64                                  >> %BUILD_DIR_PATH%\target.txt
-@echo TOOL_CHAIN_TAG  = %TOOL_CHAIN_TAG%                          >> %BUILD_DIR_PATH%\target.txt
-@echo BUILD_RULE_CONF = Conf/build_rule.txt                       >> %BUILD_DIR_PATH%\target.txt
-@move /Y %BUILD_DIR_PATH%\target.txt Conf
-
-@if %CAPSULE_BUILD% == 1 (
-  goto EndCapsulePrep
-)
-
-@REM
-@REM Set %FSP_WRAPPER_BUILD%
-@REM
-@set FSP_WRAPPER_BUILD=TRUE
-
-@if %FSP_WRAPPER_BUILD% EQU TRUE (
-  @REM Create dummy Fsp_Rebased_S_padded.fd to build the BiosInfo.inf if it is wrapper build, due to the SECTION inclusion
-  echo "" > %WORKSPACE_FSP_BIN%\KabylakeFspBinPkg\Fsp_Rebased_S_padded.fd
-  attrib -r %WORKSPACE_FSP_BIN%\KabylakeFspBinPkg\Fsp_Rebased_S_padded.fd
-)
-
-@REM
-@REM Set %PERFORMANCE_BUILD%
-@REM
-@set PERFORMANCE_BUILD=FALSE
-
-@REM
-@REM Set %FSP_BINARY_BUILD% and %FSP_TEST_RELEASE%
-@REM
-@set FSP_BINARY_BUILD=FALSE
-@set FSP_TEST_RELEASE=FALSE
-
-@if "FSP_BINARY_BUILD"=="TRUE" (
-  @if %FSP_WRAPPER_BUILD% EQU FALSE goto :EndPreBuild
-)
-
-@if not exist %BUILD_X64% (
-  mkdir %BUILD_X64%
-)
-
-@set SECURE_BOOT_ENABLE=FALSE
-
-@REM
-@REM Skip BIOS_SIZE_OPTION if it is predefined
-@REM
-@if NOT "%BIOS_SIZE_OPTION%" == "" goto BiosSizeDone
-
-@set BIOS_SIZE_OPTION=
-
-@REM default size option is 6M
-@set BIOS_SIZE_OPTION=-DBIOS_SIZE_OPTION=SIZE_60
-
-:BiosSizeDone
-@echo BIOS_SIZE_OPTION=%BIOS_SIZE_OPTION%
-
-@echo   EFI_SOURCE           = %EFI_SOURCE%
-@echo   TARGET               = %TARGET%
-@echo   TARGET_ARCH          = IA32 X64
-@echo   TOOL_CHAIN_TAG       = %TOOL_CHAIN_TAG%
-@echo   WORKSPACE            = %WORKSPACE%
-@echo   WORKSPACE_CORE       = %WORKSPACE_CORE%
-@echo   EXT_BUILD_FLAGS      = %EXT_BUILD_FLAGS%
-@echo.
-:EndPreBuild
-cd %WORKSPACE_PLATFORM%\%PROJECT%
diff --git a/Platform/Intel/ClevoOpenBoardPkg/N1xxWU/prep.bat b/Platform/Intel/ClevoOpenBoardPkg/N1xxWU/prep.bat
deleted file mode 100644
index cb0d44f722..0000000000
--- a/Platform/Intel/ClevoOpenBoardPkg/N1xxWU/prep.bat
+++ /dev/null
@@ -1,79 +0,0 @@
-@REM @file
-@REM
-@REM Copyright (c) 2019, Intel Corporation. All rights reserved.<BR>
-@REM SPDX-License-Identifier: BSD-2-Clause-Patent
-@REM
-
-@echo OFF
-@set PrepRELEASE=DEBUG
-@set SILENT_MODE=FALSE
-@set CapsuleBuild=FALSE
-
-@set EXT_CONFIG_CLEAR=
-@set EXT_BUILD_FLAGS=
-
-:CmdLineParse
-if "" == "%1" (
-  goto Continue
-) else if "r" == "%1" (
-  set PrepRELEASE=RELEASE
-) else if "tr" == "%1" (
-  set PrepRELEASE=TEST_RELEASE
-) else if "rp" == "%1" (
-  set PrepRELEASE=RELEASE_PDB
-) else if "s" == "%1" (
-  set SILENT_MODE=TRUE
-) else if "help" == "%1" (
-  goto PrepHelp
-) else (
-  echo Invalid input arguments: %1
-  echo.
-  goto PrepHelp
-)
-SHIFT
-goto CmdLineParse
-
-:PrepHelp
-@echo Preparation for BIOS build.
-@echo.
-@echo prep [r][rp][s][help]
-@echo.
-@echo   r         To do release build. Default is debug build. See note 1
-@echo   rp        To do release build with Symbols - For source level debugging. See note 1
-@echo   s         To build in silent mode. . See note 1
-@echo.
-@echo 1) Re-running prep without these arguments cannot be used for
-@echo    incremental build. Hence, these inputs must be supplied each time
-@echo    prep are desired to be re-run.
-@echo.
-goto PrepDone
-
-:Continue
-@echo ==============================================
-
-if exist %WORKSPACE%\Prep.log del %WORKSPACE%\Prep.log
-
-:PrepReleaseCheck
-
-@if %SILENT_MODE% EQU TRUE goto BldSilent
-
-call prebuild.bat %PrepRelease% %CapsuleBuild%
-goto PrePrepDone
-
-:BldSilent
-@echo ************************************************************************ >> %WORKSPACE%\Prep.log
-@echo ***********           Prebuild.bat is launched here          *********** >> %WORKSPACE%\Prep.log
-@echo ************************************************************************ >> %WORKSPACE%\Prep.log
-call prebuild.bat %PrepRelease% %CapsuleBuild% 1>>%WORKSPACE%\Prep.log 2>&1
-
-:PrePrepDone
-@If %SCRIPT_ERROR% EQU 1 goto PrepFail
-@goto PrepDone
-
-:PrepFail
-@echo.
-@echo !! The EDKII BIOS build has failed in prep!
-@echo.
-@exit /b 1
-
-:PrepDone
\ No newline at end of file
-- 
2.19.1.windows.1


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#45288): https://edk2.groups.io/g/devel/message/45288
Mute This Topic: https://groups.io/mt/32812476/1787277
Group Owner: devel+owner@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [importer@patchew.org]
-=-=-=-=-=-=-=-=-=-=-=-

Re: [edk2-devel] [edk2-platforms] [PATCH] ClevoOpenBoardPkg: Remove batch build scripts

Posted by Kubacki, Michael A 17 weeks ago
Reviewed-by: Michael Kubacki <michael.a.kubacki@intel.com>

> -----Original Message-----
> From: devel@edk2.groups.io [mailto:devel@edk2.groups.io] On Behalf Of
> Agyeman, Prince
> Sent: Friday, August 9, 2019 9:35 AM
> To: devel@edk2.groups.io
> Subject: [edk2-devel] [edk2-platforms] [PATCH] ClevoOpenBoardPkg: Remove
> batch build scripts
> 
> Ref: https://bugzilla.tianocore.org/show_bug.cgi?id=1775
> 
> Removed batch build scripts as they are replaced
> 
> by build_bios.py
> 
> Signed-off-by: Agyeman <prince.agyeman@intel.com>
> ---
>  .../ClevoOpenBoardPkg/N1xxWU/GitEdk2Clevo.bat |  79 -------
>  .../Intel/ClevoOpenBoardPkg/N1xxWU/bld.bat    | 159 -------------
>  .../Intel/ClevoOpenBoardPkg/N1xxWU/cln.bat    |  48 ----
>  .../ClevoOpenBoardPkg/N1xxWU/postbuild.bat    |  39 ----
>  .../ClevoOpenBoardPkg/N1xxWU/prebuild.bat     | 214 ------------------
>  .../Intel/ClevoOpenBoardPkg/N1xxWU/prep.bat   |  79 -------
>  6 files changed, 618 deletions(-)
>  delete mode 100644
> Platform/Intel/ClevoOpenBoardPkg/N1xxWU/GitEdk2Clevo.bat
>  delete mode 100644 Platform/Intel/ClevoOpenBoardPkg/N1xxWU/bld.bat
>  delete mode 100644 Platform/Intel/ClevoOpenBoardPkg/N1xxWU/cln.bat
>  delete mode 100644
> Platform/Intel/ClevoOpenBoardPkg/N1xxWU/postbuild.bat
>  delete mode 100644
> Platform/Intel/ClevoOpenBoardPkg/N1xxWU/prebuild.bat
>  delete mode 100644 Platform/Intel/ClevoOpenBoardPkg/N1xxWU/prep.bat
> 
> diff --git a/Platform/Intel/ClevoOpenBoardPkg/N1xxWU/GitEdk2Clevo.bat
> b/Platform/Intel/ClevoOpenBoardPkg/N1xxWU/GitEdk2Clevo.bat
> deleted file mode 100644
> index 81f51b3785..0000000000
> --- a/Platform/Intel/ClevoOpenBoardPkg/N1xxWU/GitEdk2Clevo.bat
> +++ /dev/null
> @@ -1,79 +0,0 @@
> -@REM @file
> -@REM
> -@REM Copyright (c) 2019, Intel Corporation. All rights reserved.<BR> -@REM
> SPDX-License-Identifier: BSD-2-Clause-Patent -@REM
> -
> -@echo off
> -
> -pushd ..\..\..\..\..\
> -
> -@REM Set WORKSPACE environment.
> -set WORKSPACE=%cd%
> -echo.
> -echo Set WORKSPACE as: %WORKSPACE%
> -echo.
> -
> -@REM Check whether Git has been installed and been added to system path.
> -git --help >nul 2>nul
> -if %ERRORLEVEL% NEQ 0 (
> -  echo.
> -  echo The 'git' command is not recognized.
> -  echo Please make sure that Git is installed and has been added to system path.
> -  echo.
> -  goto :EOF
> -)
> -
> -@REM Create the Conf directory under WORKSPACE -if not exist
> %WORKSPACE%\Conf (
> -  mkdir Conf
> -)
> -
> -@REM Set other environments.
> -@REM Basic Rule:
> -@REM   Platform override Silicon override Core
> -@REM   Source override Binary
> -
> -set PACKAGES_PATH=%WORKSPACE%\edk2-
> platforms\Platform\Intel;%WORKSPACE%\edk2-
> platforms\Silicon\Intel;%WORKSPACE%\edk2-non-
> osi\Silicon\Intel;%WORKSPACE%\FSP;%WORKSPACE%\edk2;%WORKSPACE%
> -set EDK_TOOLS_BIN=%WORKSPACE%\edk2-BaseTools-win32
> -
> -@if not defined PYTHON_HOME (
> -  @if exist C:\Python27 (
> -    set PYTHON_HOME=C:\Python27
> -  )
> -)
> -
> -set EDK_SETUP_OPTION=
> -@rem if python is installed, disable the binary base tools.
> -if defined PYTHON_HOME (
> -  set EDK_TOOLS_BIN=
> -  set EDK_SETUP_OPTION=--nt32
> -)
> -pushd %WORKSPACE%\edk2
> -call edksetup.bat %EDK_SETUP_OPTION%
> -popd
> -pushd %WORKSPACE%
> -@rem if python is installed, nmake BaseTools source and enable BaseTools
> source build -@if defined PYTHON_HOME (
> -  nmake -f %BASE_TOOLS_PATH%\Makefile
> -)
> -popd
> -
> -set openssl_path=%WORKSPACE%
> -
> -popd
> -
> -goto :EOF
> -
> -:Help
> -echo.
> -echo Usage:
> -echo GitEdk2.bat [-w Workspace_Directory] (optional) [-b Branch_Name]
> (optional) -echo.
> -echo -w    A absolute/relative path to be the workspace.
> -echo       Default value is the current directory.
> -echo.
> -echo -b    The branch name of the repository. Currently, only master, udk2015,
> -echo       trunk (same as master) and bp13 (same as udk2015) are supported.
> -echo       Default value is master.
> -echo.
> diff --git a/Platform/Intel/ClevoOpenBoardPkg/N1xxWU/bld.bat
> b/Platform/Intel/ClevoOpenBoardPkg/N1xxWU/bld.bat
> deleted file mode 100644
> index 606ce979a7..0000000000
> --- a/Platform/Intel/ClevoOpenBoardPkg/N1xxWU/bld.bat
> +++ /dev/null
> @@ -1,159 +0,0 @@
> -@REM @file
> -@REM
> -@REM Copyright (c) 2019, Intel Corporation. All rights reserved.<BR> -@REM
> SPDX-License-Identifier: BSD-2-Clause-Patent -@REM
> -
> -:: Useage: bld [/s] [/f <FEATURE_PCD_NAME> <FALSE or TRUE>] [/r]
> -::
> -:: For a given build command, 3 options may be passed into this batch file via
> command prompt:
> -:: 1) /s = Redirects all output to a file called EDK2.log(Prep.log must be existed),
> which will be located at the root.
> -:: 2) /f = Defines the passing in of a single override to a feature PCD that is used
> in the platform
> -::    DSC file.  If this parameter is used, it is to be followed immediately after by
> both the feature
> -::    pcd name and value. FeaturePcd is the full PCD name, like
> gMinPlatformPkgTokenSpaceGuid.PcdOptimizeCompilerEnable
> -:: 3) /r = Useful for faster rebuilds when no changes have been made to .inf
> files. Passes -u to
> -::    build.exe to skip the generation of makefiles.
> -:: 4) rom = Build Bios.rom only and building SPIs will be skipped.
> -::
> -
> -@echo on
> -
> -cd %WORKSPACE%
> -
> -@REM
> -@REM Build FSP Binary
> -@REM
> -@if not defined FSP_BINARY_BUILD goto :SkipFspBinaryBuild -@if
> %FSP_BINARY_BUILD% EQU FALSE goto :SkipFspBinaryBuild -@set
> FSP_BUILD_PARAMETER=/d -@set FSP_PKG_NAME=KabylakeFspPkg -@if /I
> "%TARGET%" == "RELEASE" (
> -  @if "%FSP_TEST_RELEASE%"=="TRUE" (
> -    set FSP_BUILD_PARAMETER=/tr
> -  ) else (
> -    set FSP_BUILD_PARAMETER=/r
> -  )
> -)
> -
> -@if %FSP_WRAPPER_BUILD% EQU FALSE goto :BldEnd -:SkipFspBinaryBuild
> -
> -@if %FSP_WRAPPER_BUILD% EQU FALSE goto
> :SkipPatchFspBinFvsBaseAddress -del /f
> %WORKSPACE_FSP_BIN%\KabylakeFspBinPkg\Fsp_Rebased*.fd
> -
> -cd %WORKSPACE%
> -
> -if exist %WORKSPACE_PLATFORM%\%PROJECT%\OpenBoardPkgPcd.dsc attrib
> -r %WORKSPACE_PLATFORM%\%PROJECT%\OpenBoardPkgPcd.dsc
> -@call %PYTHON_HOME%\python.exe
> %WORKSPACE_PLATFORM%\%PLATFORM_PACKAGE%\Tools\Fsp\RebaseAndP
> atchFspBinBaseAddress.py
> %WORKSPACE_PLATFORM%\%PROJECT%\Include\Fdf\FlashMapInclude.fdf
> %WORKSPACE_FSP_BIN%\KabylakeFspBinPkg Fsp.fd
> %WORKSPACE_PLATFORM%\%PROJECT%\OpenBoardPkgPcd.dsc 0x0
> -
> -@if %ERRORLEVEL% NEQ 0 (
> -  @echo !!! ERROR:RebaseAndPatchFspBinBaseAddress failed!!!
> -  set SCRIPT_ERROR=1
> -  goto :BldFail
> -)
> -
> -cd %WORKSPACE%
> -
> -copy /y /b
> %WORKSPACE_FSP_BIN%\KabylakeFspBinPkg\Fsp_Rebased_S.fd+%WORKSPA
> CE_FSP_BIN%\KabylakeFspBinPkg\Fsp_Rebased_M.fd+%WORKSPACE_FSP_BI
> N%\KabylakeFspBinPkg\Fsp_Rebased_T.fd
> %WORKSPACE_FSP_BIN%\KabylakeFspBinPkg\Fsp_Rebased.fd
> -:SkipPatchFspBinFvsBaseAddress
> -
> -
> -@SET SILENT_MODE=FALSE
> -@SET REBUILD_MODE=
> -@SET BUILD_ROM_ONLY=
> -
> -:: Loop through arguements until all are processed
> -
> -:BUILD_FLAGS_LOOP
> -
> -@if "%~1" == "" goto BUILD_FLAGS_LOOP_DONE
> -
> -@if "%~1" == "/f" (
> -  shift
> -  goto BUILD_FLAGS_LOOP
> -)
> -@if "%~1" == "/s" (
> -  SET SILENT_MODE=TRUE
> -  shift
> -  goto BUILD_FLAGS_LOOP
> -)
> -@if "%~1" == "/r" (
> -  SET REBUILD_MODE=-u
> -  shift
> -  goto BUILD_FLAGS_LOOP
> -)
> -@if "%~1" == "rom" (
> -  SET BUILD_ROM_ONLY=rom
> -  shift
> -  goto BUILD_FLAGS_LOOP
> -)
> -:: Unknown build flag.
> -shift
> -goto BUILD_FLAGS_LOOP
> -:BUILD_FLAGS_LOOP_DONE
> -
> -:: Output the build variables the user has selected.
> -
> -@echo.
> -@echo  User Selected build options:
> -@echo    SILENT_MODE = %SILENT_MODE%
> -@echo    REBUILD_MODE = %REBUILD_MODE%
> -@echo    BUILD_ROM_ONLY = %BUILD_ROM_ONLY%
> -@echo.
> -
> -@if %SILENT_MODE% EQU TRUE goto BldSilent
> -
> -call build -n %NUMBER_OF_PROCESSORS% %REBUILD_MODE%
> %EXT_BUILD_FLAGS%
> -
> -@if %ERRORLEVEL% NEQ 0 goto BldFail
> -@echo.
> -@echo Running postbuild.bat to complete the build process.
> -@echo.
> -call %WORKSPACE_PLATFORM%\%PROJECT%\postbuild.bat
> %BUILD_ROM_ONLY% -@if %SCRIPT_ERROR% EQU 1 goto BldFail -@goto
> BldSuccess
> -
> -:BldSilent
> -@if exist Build.log del Build.log
> -
> -@echo. > Build.log
> -@echo
> *************************************************************
> *********** >> Build.log
> -@echo ***********             Build.bat is launched here           *********** >>
> Build.log
> -@echo
> *************************************************************
> *********** >> Build.log -@echo. >> Build.log
> -
> -call build -n %NUMBER_OF_PROCESSORS% %REBUILD_MODE%
> %EXT_BUILD_FLAGS% 1>>Build.log 2>&1
> -
> -@if %ERRORLEVEL% NEQ 0 goto BldFail
> -@echo. >> Build.log
> -@echo Running postbuild.bat to complete the build process. >> Build.log -
> @echo. >> Build.log -@call
> %WORKSPACE_PLATFORM%\%PROJECT%\postbuild.bat
> %BUILD_ROM_ONLY% 1>>Build.log 2>&1 -@If %SCRIPT_ERROR% EQU 1 goto
> BldFail
> -
> -:BldSuccess
> -@echo.
> -@echo TARGET:               %TARGET%
> -@echo TOOL_CHAIN_TAG:       %TOOL_CHAIN_TAG%
> -@echo BIOS location:        %BUILD_DIR%\FV
> -@echo.
> -@echo The EDKII BIOS build has successfully completed!
> -@echo.
> -@REM
> -
> -@goto BldEnd
> -
> -:BldFail
> -cd %WORKSPACE_PLATFORM%\%PROJECT%
> -@echo.
> -@echo The EDKII BIOS Build has failed!
> -@echo.
> -@exit /b 1
> -
> -:BldEnd
> -@if %SILENT_MODE% EQU TRUE (
> -  @if exist EDK2.log del EDK2.log
> -  @if exist Prep.log if exist Build.log copy Prep.log+Build.log EDK2.log
> -)
> -
> -cd %WORKSPACE_PLATFORM%\%PROJECT%
> \ No newline at end of file
> diff --git a/Platform/Intel/ClevoOpenBoardPkg/N1xxWU/cln.bat
> b/Platform/Intel/ClevoOpenBoardPkg/N1xxWU/cln.bat
> deleted file mode 100644
> index 61c8a7d1a4..0000000000
> --- a/Platform/Intel/ClevoOpenBoardPkg/N1xxWU/cln.bat
> +++ /dev/null
> @@ -1,48 +0,0 @@
> -@REM @file
> -@REM
> -@REM Copyright (c) 2019, Intel Corporation. All rights reserved.<BR> -@REM
> SPDX-License-Identifier: BSD-2-Clause-Patent -@REM
> -
> -@echo off
> -echo.
> -echo Run build cleanall...
> -echo.
> -
> -cd ..
> -
> -if not defined WORKSPACE set WORKSPACE=%cd% -if not defined
> WORKSPACE_PLATFORM set WORKSPACE_PLATFORM=%cd% -if not defined
> WORKSPACE_SILICON set WORKSPACE_SILICON=%cd%
> -
> -REM build cleanall
> -
> -echo.
> -echo Directories to clean...
> -echo.
> -
> -if exist %WORKSPACE%\build rmdir /q /s %WORKSPACE%\build -if exist
> %WORKSPACE%\conf\.cache rmdir /q /s %WORKSPACE%\conf\.cache
> -
> -echo.
> -echo Files to clean...
> -echo.
> -
> -if exist %WORKSPACE%\edk2.log del %WORKSPACE%\edk2.log -if exist
> %WORKSPACE%\Conf\build_rule.txt del %WORKSPACE%\Conf\build_rule.txt -if
> exist %WORKSPACE%\Conf\FrameworkDatabase.db del
> %WORKSPACE%\Conf\FrameworkDatabase.db
> -if exist %WORKSPACE%\Conf\target.txt del %WORKSPACE%\Conf\target.txt -if
> exist %WORKSPACE%\Conf\tools_def.txt del
> %WORKSPACE%\Conf\tools_def.txt -@REM *.c.c is generated by Catalog Debug
> feature across code tree.
> -@REM
> -del /s *.c.c > nul 2>&1
> -
> -cd %WORKSPACE_PLATFORM%\%PROJECT%
> -
> -del /f /q Prep.log > nul 2>&1
> -del /f /q ..\Build.log > nul 2>&1
> -
> -echo.
> -echo All done...
> -echo.
> -@echo on
> diff --git a/Platform/Intel/ClevoOpenBoardPkg/N1xxWU/postbuild.bat
> b/Platform/Intel/ClevoOpenBoardPkg/N1xxWU/postbuild.bat
> deleted file mode 100644
> index 5553645fbf..0000000000
> --- a/Platform/Intel/ClevoOpenBoardPkg/N1xxWU/postbuild.bat
> +++ /dev/null
> @@ -1,39 +0,0 @@
> -@REM @file
> -@REM
> -@REM Copyright (c) 2019, Intel Corporation. All rights reserved.<BR> -@REM
> SPDX-License-Identifier: BSD-2-Clause-Patent -@REM
> -
> -@REM #
> -@REM #  Module Name:
> -@REM #
> -@REM #    postbuild.bat
> -@REM #
> -@REM #  Abstract:
> -@REM #
> -@REM #    Post build script.
> -@REM #
> -@REM #--*/
> -
> -@set SCRIPT_ERROR=0
> -
> -@if /I not "%0" == "%WORKSPACE_PLATFORM%\%PROJECT%\postbuild.bat" (
> -  if /I not "%0" == "%WORKSPACE_PLATFORM%\%PROJECT%\postbuild" (
> -    echo.
> -    echo !!! ERROR !!! This postbuild.bat must run under workspace root using
> "%WORKSPACE_PLATFORM%\%PROJECT%\postbuild.bat" !!!
> -    echo.
> -    set SCRIPT_ERROR=1
> -    goto :EOF
> -  )
> -)
> -
> -@cd %WORKSPACE_PLATFORM%
> -
> -@cd %WORKSPACE%
> -
> -@if %FSP_WRAPPER_BUILD% EQU TRUE (
> -  del /f %WORKSPACE_FSP_BIN%\KabylakeFspBinPkg\Fsp_Rebased*.fd
> -)
> -
> -@if %FSP_WRAPPER_BUILD% EQU TRUE exit /b
> -
> diff --git a/Platform/Intel/ClevoOpenBoardPkg/N1xxWU/prebuild.bat
> b/Platform/Intel/ClevoOpenBoardPkg/N1xxWU/prebuild.bat
> deleted file mode 100644
> index c18dd5e89d..0000000000
> --- a/Platform/Intel/ClevoOpenBoardPkg/N1xxWU/prebuild.bat
> +++ /dev/null
> @@ -1,214 +0,0 @@
> -@REM @file
> -@REM  Pre build script.
> -@REM
> -@REM Copyright (c) 2019, Intel Corporation. All rights reserved.<BR> -@REM
> SPDX-License-Identifier: BSD-2-Clause-Patent -@REM
> -
> -cd ..
> -
> -@REM
> -@REM Set build capsule flag with default being OFF -@REM
> -
> -@set CAPSULE_BUILD=0
> -
> -@if /I "%2" == "TRUE" (
> -  @set CAPSULE_BUILD=1
> -  goto StartCapsulePrep
> -)
> -
> -:StartCapsulePrep
> -@REM
> -@REM Define platform specific environment variables.
> -@REM
> -if not defined WORKSPACE_PLATFORM set
> WORKSPACE_PLATFORM=%WORKSPACE%\edk2-platforms\Platform\Intel
> -if not defined WORKSPACE_SILICON set
> WORKSPACE_SILICON=%WORKSPACE%\edk2-platforms\Silicon\Intel
> -if not defined WORKSPACE_PLATFORM_BIN set
> WORKSPACE_PLATFORM_BIN=%WORKSPACE%\edk2-non-osi\Platform\Intel
> -if not defined WORKSPACE_SILICON_BIN set
> WORKSPACE_SILICON_BIN=%WORKSPACE%\edk2-non-osi\Silicon\Intel
> -if not defined WORKSPACE_FSP_BIN set
> WORKSPACE_FSP_BIN=%WORKSPACE%\FSP -if not defined
> WORKSPACE_CORE set WORKSPACE_CORE=%WORKSPACE%\edk2 -if not
> defined PLATFORM_PACKAGE set PLATFORM_PACKAGE=MinPlatformPkg -if
> not defined PLATFORM_BOARD_PACKAGE set
> PLATFORM_BOARD_PACKAGE=ClevoOpenBoardPkg
> -if not defined BOARD set BOARD=N1xxWU
> -if not defined PROJECT set
> PROJECT=%PLATFORM_BOARD_PACKAGE%\%BOARD%
> -
> -@set SCRIPT_ERROR=0
> -
> -@set CATALOG_DEBUG=0
> -
> -@REM Set basic environment.
> -@echo.
> -@echo Prebuild:  Run edksetup.bat batch file.
> -@echo.
> -@if %CATALOG_DEBUG% == 0 (
> -  @del Conf\build_rule.txt
> -)
> -cd %WORKSPACE_CORE%
> -@call edksetup.bat
> -cd %WORKSPACE%
> -@set EFI_SOURCE=%WORKSPACE_CORE%
> -
> -@REM
> -@REM Setup Visual Studio environment. Order of precedence is 2012, 2013,
> 2010 and then 2008.
> -@REM
> -@REM NOTE: To override precedence set TOOL_CHAIN_TAG before calling
> prep.bat.
> -@REM       Example: set TOOL_CHAIN_TAG=VS2008
> -@REM
> -
> -@REM Check if tool chain has not been selected and Visual Studio 2014 is
> installed.
> -@if not defined TOOL_CHAIN_TAG (
> -  if defined VS140COMNTOOLS (
> -    set TOOL_CHAIN_TAG=VS2015
> -  )
> -)
> -
> -@REM If Visual Studio 2014 is selected by priority or by preference, setup the
> environment variables.
> -@if /I "%TOOL_CHAIN_TAG%"=="VS2015" (
> -  echo.
> -  echo Prebuild:  Set the VS2015 environment.
> -  echo.
> -  if not defined VSINSTALLDIR call "%VS140COMNTOOLS%\vsvars32.bat"
> -  if /I "%VS140COMNTOOLS%" == "C:\Program Files\Microsoft Visual Studio
> 14.0\Common7\Tools\" (
> -    set TOOL_CHAIN_TAG=VS2015
> -  ) else (
> -    set TOOL_CHAIN_TAG=VS2015x86
> -  )
> -)
> -
> -@REM Check if tool chain has not been selected and Visual Studio 2013 is
> installed.
> -@if not defined TOOL_CHAIN_TAG (
> -  if defined VS120COMNTOOLS (
> -    set TOOL_CHAIN_TAG=VS2013
> -  )
> -)
> -
> -@REM If Visual Studio 2013 is selected by priority or by preference, setup the
> environment variables.
> -@if /I "%TOOL_CHAIN_TAG%"=="VS2013" (
> -  echo.
> -  echo Prebuild:  Set the VS2013 environment.
> -  echo.
> -  if not defined VSINSTALLDIR call "%VS120COMNTOOLS%\vsvars32.bat"
> -  if /I "%VS120COMNTOOLS%" == "C:\Program Files\Microsoft Visual Studio
> 12.0\Common7\Tools\" (
> -    set TOOL_CHAIN_TAG=VS2013
> -  ) else (
> -    set TOOL_CHAIN_TAG=VS2013x86
> -  )
> -)
> -
> -@REM If no supported version of Visual Studio was detected, return an error.
> -@if not defined TOOL_CHAIN_TAG (
> -  echo.
> -  echo !!! ERROR !!! Visual Studio not installed correctly!!!
> -  echo.
> -  set SCRIPT_ERROR=1
> -  goto :EndPreBuild
> -)
> -
> -echo Show CL revision
> -cl
> -
> -@REM Set build TARGET.
> -@if /I "%1" == "" (
> -  set TARGET=DEBUG
> -  set TARGET_SHORT=D
> -) else if /I "%1" == "DEBUG" (
> -  set TARGET=DEBUG
> -  set TARGET_SHORT=D
> -) else if /I "%1" == "TEST_RELEASE" (
> -  set TARGET=RELEASE
> -  set TARGET_SHORT=R
> -) else if /I "%1" == "RELEASE" (
> -  set TARGET=RELEASE
> -  set TARGET_SHORT=R
> -) else if /I "%1" == "RELEASE_PDB" (
> -  set TARGET=RELEASE
> -  set TARGET_SHORT=R
> -) else (
> -  echo.
> -  echo !!! ERROR !!! Incorrect TARGET option for prebuild.bat. !!!
> -  echo.
> -  set SCRIPT_ERROR=1
> -  goto :EndPreBuild
> -)
> -
> -@set
> BUILD_DIR_PATH=%WORKSPACE%\Build\%PROJECT%\%TARGET%_%TOOL_C
> HAIN_TAG%
> -@set BUILD_DIR=Build\%PROJECT%\%TARGET%_%TOOL_CHAIN_TAG%
> -@set BUILD_X64=%BUILD_DIR_PATH%\X64
> -@set BUILD_IA32=%BUILD_DIR_PATH%\IA32
> -
> -
> -@echo.
> -@echo Prebuild:  Set build environment.
> -@echo.
> -@if not exist %BUILD_DIR_PATH% (
> -  mkdir %BUILD_DIR_PATH%
> -)
> -
> -@findstr /V "ACTIVE_PLATFORM TARGET TARGET_ARCH TOOL_CHAIN_TAG
> BUILD_RULE_CONF" %WORKSPACE%\Conf\target.txt >
> %BUILD_DIR_PATH%\target.txt
> -@echo ACTIVE_PLATFORM =
> %WORKSPACE_PLATFORM%/%PLATFORM_BOARD_PACKAGE%/%BOARD%/O
> penBoardPkg.dsc        >> %BUILD_DIR_PATH%\target.txt
> -@echo TARGET          = %TARGET%                                  >>
> %BUILD_DIR_PATH%\target.txt
> -@echo TARGET_ARCH     = IA32 X64                                  >>
> %BUILD_DIR_PATH%\target.txt
> -@echo TOOL_CHAIN_TAG  = %TOOL_CHAIN_TAG%                          >>
> %BUILD_DIR_PATH%\target.txt
> -@echo BUILD_RULE_CONF = Conf/build_rule.txt                       >>
> %BUILD_DIR_PATH%\target.txt
> -@move /Y %BUILD_DIR_PATH%\target.txt Conf
> -
> -@if %CAPSULE_BUILD% == 1 (
> -  goto EndCapsulePrep
> -)
> -
> -@REM
> -@REM Set %FSP_WRAPPER_BUILD%
> -@REM
> -@set FSP_WRAPPER_BUILD=TRUE
> -
> -@if %FSP_WRAPPER_BUILD% EQU TRUE (
> -  @REM Create dummy Fsp_Rebased_S_padded.fd to build the BiosInfo.inf if it
> is wrapper build, due to the SECTION inclusion
> -  echo "" >
> %WORKSPACE_FSP_BIN%\KabylakeFspBinPkg\Fsp_Rebased_S_padded.fd
> -  attrib -r
> %WORKSPACE_FSP_BIN%\KabylakeFspBinPkg\Fsp_Rebased_S_padded.fd
> -)
> -
> -@REM
> -@REM Set %PERFORMANCE_BUILD%
> -@REM
> -@set PERFORMANCE_BUILD=FALSE
> -
> -@REM
> -@REM Set %FSP_BINARY_BUILD% and %FSP_TEST_RELEASE% -@REM -@set
> FSP_BINARY_BUILD=FALSE -@set FSP_TEST_RELEASE=FALSE
> -
> -@if "FSP_BINARY_BUILD"=="TRUE" (
> -  @if %FSP_WRAPPER_BUILD% EQU FALSE goto :EndPreBuild
> -)
> -
> -@if not exist %BUILD_X64% (
> -  mkdir %BUILD_X64%
> -)
> -
> -@set SECURE_BOOT_ENABLE=FALSE
> -
> -@REM
> -@REM Skip BIOS_SIZE_OPTION if it is predefined -@REM -@if NOT
> "%BIOS_SIZE_OPTION%" == "" goto BiosSizeDone
> -
> -@set BIOS_SIZE_OPTION=
> -
> -@REM default size option is 6M
> -@set BIOS_SIZE_OPTION=-DBIOS_SIZE_OPTION=SIZE_60
> -
> -:BiosSizeDone
> -@echo BIOS_SIZE_OPTION=%BIOS_SIZE_OPTION%
> -
> -@echo   EFI_SOURCE           = %EFI_SOURCE%
> -@echo   TARGET               = %TARGET%
> -@echo   TARGET_ARCH          = IA32 X64
> -@echo   TOOL_CHAIN_TAG       = %TOOL_CHAIN_TAG%
> -@echo   WORKSPACE            = %WORKSPACE%
> -@echo   WORKSPACE_CORE       = %WORKSPACE_CORE%
> -@echo   EXT_BUILD_FLAGS      = %EXT_BUILD_FLAGS%
> -@echo.
> -:EndPreBuild
> -cd %WORKSPACE_PLATFORM%\%PROJECT%
> diff --git a/Platform/Intel/ClevoOpenBoardPkg/N1xxWU/prep.bat
> b/Platform/Intel/ClevoOpenBoardPkg/N1xxWU/prep.bat
> deleted file mode 100644
> index cb0d44f722..0000000000
> --- a/Platform/Intel/ClevoOpenBoardPkg/N1xxWU/prep.bat
> +++ /dev/null
> @@ -1,79 +0,0 @@
> -@REM @file
> -@REM
> -@REM Copyright (c) 2019, Intel Corporation. All rights reserved.<BR> -@REM
> SPDX-License-Identifier: BSD-2-Clause-Patent -@REM
> -
> -@echo OFF
> -@set PrepRELEASE=DEBUG
> -@set SILENT_MODE=FALSE
> -@set CapsuleBuild=FALSE
> -
> -@set EXT_CONFIG_CLEAR=
> -@set EXT_BUILD_FLAGS=
> -
> -:CmdLineParse
> -if "" == "%1" (
> -  goto Continue
> -) else if "r" == "%1" (
> -  set PrepRELEASE=RELEASE
> -) else if "tr" == "%1" (
> -  set PrepRELEASE=TEST_RELEASE
> -) else if "rp" == "%1" (
> -  set PrepRELEASE=RELEASE_PDB
> -) else if "s" == "%1" (
> -  set SILENT_MODE=TRUE
> -) else if "help" == "%1" (
> -  goto PrepHelp
> -) else (
> -  echo Invalid input arguments: %1
> -  echo.
> -  goto PrepHelp
> -)
> -SHIFT
> -goto CmdLineParse
> -
> -:PrepHelp
> -@echo Preparation for BIOS build.
> -@echo.
> -@echo prep [r][rp][s][help]
> -@echo.
> -@echo   r         To do release build. Default is debug build. See note 1
> -@echo   rp        To do release build with Symbols - For source level debugging.
> See note 1
> -@echo   s         To build in silent mode. . See note 1
> -@echo.
> -@echo 1) Re-running prep without these arguments cannot be used for
> -@echo    incremental build. Hence, these inputs must be supplied each time
> -@echo    prep are desired to be re-run.
> -@echo.
> -goto PrepDone
> -
> -:Continue
> -@echo ==============================================
> -
> -if exist %WORKSPACE%\Prep.log del %WORKSPACE%\Prep.log
> -
> -:PrepReleaseCheck
> -
> -@if %SILENT_MODE% EQU TRUE goto BldSilent
> -
> -call prebuild.bat %PrepRelease% %CapsuleBuild% -goto PrePrepDone
> -
> -:BldSilent
> -@echo
> *************************************************************
> *********** >> %WORKSPACE%\Prep.log
> -@echo ***********           Prebuild.bat is launched here          ***********
> >> %WORKSPACE%\Prep.log
> -@echo
> *************************************************************
> *********** >> %WORKSPACE%\Prep.log -call prebuild.bat %PrepRelease%
> %CapsuleBuild% 1>>%WORKSPACE%\Prep.log 2>&1
> -
> -:PrePrepDone
> -@If %SCRIPT_ERROR% EQU 1 goto PrepFail
> -@goto PrepDone
> -
> -:PrepFail
> -@echo.
> -@echo !! The EDKII BIOS build has failed in prep!
> -@echo.
> -@exit /b 1
> -
> -:PrepDone
> \ No newline at end of file
> --
> 2.19.1.windows.1
> 
> 
> 


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#45478): https://edk2.groups.io/g/devel/message/45478
Mute This Topic: https://groups.io/mt/32812476/1787277
Group Owner: devel+owner@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [importer@patchew.org]
-=-=-=-=-=-=-=-=-=-=-=-

Re: [edk2-devel] [edk2-platforms] [PATCH] ClevoOpenBoardPkg: Remove batch build scripts

Posted by Nate DeSimone 18 weeks ago
Reviewed-by: Nate DeSimone <nathaniel.l.desimone@intel.com>

-----Original Message-----
From: devel@edk2.groups.io <devel@edk2.groups.io> On Behalf Of Agyeman, Prince
Sent: Friday, August 9, 2019 9:35 AM
To: devel@edk2.groups.io
Subject: [edk2-devel] [edk2-platforms] [PATCH] ClevoOpenBoardPkg: Remove batch build scripts

Ref: https://bugzilla.tianocore.org/show_bug.cgi?id=1775

Removed batch build scripts as they are replaced

by build_bios.py

Signed-off-by: Agyeman <prince.agyeman@intel.com>
---
 .../ClevoOpenBoardPkg/N1xxWU/GitEdk2Clevo.bat |  79 -------
 .../Intel/ClevoOpenBoardPkg/N1xxWU/bld.bat    | 159 -------------
 .../Intel/ClevoOpenBoardPkg/N1xxWU/cln.bat    |  48 ----
 .../ClevoOpenBoardPkg/N1xxWU/postbuild.bat    |  39 ----
 .../ClevoOpenBoardPkg/N1xxWU/prebuild.bat     | 214 ------------------
 .../Intel/ClevoOpenBoardPkg/N1xxWU/prep.bat   |  79 -------
 6 files changed, 618 deletions(-)
 delete mode 100644 Platform/Intel/ClevoOpenBoardPkg/N1xxWU/GitEdk2Clevo.bat
 delete mode 100644 Platform/Intel/ClevoOpenBoardPkg/N1xxWU/bld.bat
 delete mode 100644 Platform/Intel/ClevoOpenBoardPkg/N1xxWU/cln.bat
 delete mode 100644 Platform/Intel/ClevoOpenBoardPkg/N1xxWU/postbuild.bat
 delete mode 100644 Platform/Intel/ClevoOpenBoardPkg/N1xxWU/prebuild.bat
 delete mode 100644 Platform/Intel/ClevoOpenBoardPkg/N1xxWU/prep.bat

diff --git a/Platform/Intel/ClevoOpenBoardPkg/N1xxWU/GitEdk2Clevo.bat b/Platform/Intel/ClevoOpenBoardPkg/N1xxWU/GitEdk2Clevo.bat
deleted file mode 100644
index 81f51b3785..0000000000
--- a/Platform/Intel/ClevoOpenBoardPkg/N1xxWU/GitEdk2Clevo.bat
+++ /dev/null
@@ -1,79 +0,0 @@
-@REM @file
-@REM
-@REM Copyright (c) 2019, Intel Corporation. All rights reserved.<BR> -@REM SPDX-License-Identifier: BSD-2-Clause-Patent -@REM
-
-@echo off
-
-pushd ..\..\..\..\..\
-
-@REM Set WORKSPACE environment.
-set WORKSPACE=%cd%
-echo.
-echo Set WORKSPACE as: %WORKSPACE%
-echo.
-
-@REM Check whether Git has been installed and been added to system path.
-git --help >nul 2>nul
-if %ERRORLEVEL% NEQ 0 (
-  echo.
-  echo The 'git' command is not recognized.
-  echo Please make sure that Git is installed and has been added to system path.
-  echo.
-  goto :EOF
-)
-
-@REM Create the Conf directory under WORKSPACE -if not exist %WORKSPACE%\Conf (
-  mkdir Conf
-)
-
-@REM Set other environments.
-@REM Basic Rule:
-@REM   Platform override Silicon override Core
-@REM   Source override Binary
-
-set PACKAGES_PATH=%WORKSPACE%\edk2-platforms\Platform\Intel;%WORKSPACE%\edk2-platforms\Silicon\Intel;%WORKSPACE%\edk2-non-osi\Silicon\Intel;%WORKSPACE%\FSP;%WORKSPACE%\edk2;%WORKSPACE%
-set EDK_TOOLS_BIN=%WORKSPACE%\edk2-BaseTools-win32
-
-@if not defined PYTHON_HOME (
-  @if exist C:\Python27 (
-    set PYTHON_HOME=C:\Python27
-  )
-)
-
-set EDK_SETUP_OPTION=
-@rem if python is installed, disable the binary base tools.
-if defined PYTHON_HOME (
-  set EDK_TOOLS_BIN=
-  set EDK_SETUP_OPTION=--nt32
-)
-pushd %WORKSPACE%\edk2
-call edksetup.bat %EDK_SETUP_OPTION%
-popd
-pushd %WORKSPACE%
-@rem if python is installed, nmake BaseTools source and enable BaseTools source build -@if defined PYTHON_HOME (
-  nmake -f %BASE_TOOLS_PATH%\Makefile
-)
-popd
-
-set openssl_path=%WORKSPACE%
-
-popd
-
-goto :EOF
-
-:Help
-echo.
-echo Usage:
-echo GitEdk2.bat [-w Workspace_Directory] (optional) [-b Branch_Name] (optional) -echo.
-echo -w    A absolute/relative path to be the workspace.
-echo       Default value is the current directory.
-echo.
-echo -b    The branch name of the repository. Currently, only master, udk2015,
-echo       trunk (same as master) and bp13 (same as udk2015) are supported.
-echo       Default value is master.
-echo.
diff --git a/Platform/Intel/ClevoOpenBoardPkg/N1xxWU/bld.bat b/Platform/Intel/ClevoOpenBoardPkg/N1xxWU/bld.bat
deleted file mode 100644
index 606ce979a7..0000000000
--- a/Platform/Intel/ClevoOpenBoardPkg/N1xxWU/bld.bat
+++ /dev/null
@@ -1,159 +0,0 @@
-@REM @file
-@REM
-@REM Copyright (c) 2019, Intel Corporation. All rights reserved.<BR> -@REM SPDX-License-Identifier: BSD-2-Clause-Patent -@REM
-
-:: Useage: bld [/s] [/f <FEATURE_PCD_NAME> <FALSE or TRUE>] [/r]
-::
-:: For a given build command, 3 options may be passed into this batch file via command prompt:
-:: 1) /s = Redirects all output to a file called EDK2.log(Prep.log must be existed), which will be located at the root.
-:: 2) /f = Defines the passing in of a single override to a feature PCD that is used in the platform
-::    DSC file.  If this parameter is used, it is to be followed immediately after by both the feature
-::    pcd name and value. FeaturePcd is the full PCD name, like gMinPlatformPkgTokenSpaceGuid.PcdOptimizeCompilerEnable
-:: 3) /r = Useful for faster rebuilds when no changes have been made to .inf files. Passes -u to
-::    build.exe to skip the generation of makefiles.
-:: 4) rom = Build Bios.rom only and building SPIs will be skipped.
-::
-
-@echo on
-
-cd %WORKSPACE%
-
-@REM
-@REM Build FSP Binary
-@REM
-@if not defined FSP_BINARY_BUILD goto :SkipFspBinaryBuild -@if %FSP_BINARY_BUILD% EQU FALSE goto :SkipFspBinaryBuild -@set FSP_BUILD_PARAMETER=/d -@set FSP_PKG_NAME=KabylakeFspPkg -@if /I "%TARGET%" == "RELEASE" (
-  @if "%FSP_TEST_RELEASE%"=="TRUE" (
-    set FSP_BUILD_PARAMETER=/tr
-  ) else (
-    set FSP_BUILD_PARAMETER=/r
-  )
-)
-
-@if %FSP_WRAPPER_BUILD% EQU FALSE goto :BldEnd -:SkipFspBinaryBuild
-
-@if %FSP_WRAPPER_BUILD% EQU FALSE goto :SkipPatchFspBinFvsBaseAddress -del /f %WORKSPACE_FSP_BIN%\KabylakeFspBinPkg\Fsp_Rebased*.fd
-
-cd %WORKSPACE%
-
-if exist %WORKSPACE_PLATFORM%\%PROJECT%\OpenBoardPkgPcd.dsc attrib -r %WORKSPACE_PLATFORM%\%PROJECT%\OpenBoardPkgPcd.dsc
-@call %PYTHON_HOME%\python.exe %WORKSPACE_PLATFORM%\%PLATFORM_PACKAGE%\Tools\Fsp\RebaseAndPatchFspBinBaseAddress.py %WORKSPACE_PLATFORM%\%PROJECT%\Include\Fdf\FlashMapInclude.fdf %WORKSPACE_FSP_BIN%\KabylakeFspBinPkg Fsp.fd %WORKSPACE_PLATFORM%\%PROJECT%\OpenBoardPkgPcd.dsc 0x0
-
-@if %ERRORLEVEL% NEQ 0 (
-  @echo !!! ERROR:RebaseAndPatchFspBinBaseAddress failed!!!
-  set SCRIPT_ERROR=1
-  goto :BldFail
-)
-
-cd %WORKSPACE%
-
-copy /y /b %WORKSPACE_FSP_BIN%\KabylakeFspBinPkg\Fsp_Rebased_S.fd+%WORKSPACE_FSP_BIN%\KabylakeFspBinPkg\Fsp_Rebased_M.fd+%WORKSPACE_FSP_BIN%\KabylakeFspBinPkg\Fsp_Rebased_T.fd %WORKSPACE_FSP_BIN%\KabylakeFspBinPkg\Fsp_Rebased.fd
-:SkipPatchFspBinFvsBaseAddress
-
-
-@SET SILENT_MODE=FALSE
-@SET REBUILD_MODE=
-@SET BUILD_ROM_ONLY=
-
-:: Loop through arguements until all are processed
-
-:BUILD_FLAGS_LOOP
-
-@if "%~1" == "" goto BUILD_FLAGS_LOOP_DONE
-
-@if "%~1" == "/f" (
-  shift
-  goto BUILD_FLAGS_LOOP
-)
-@if "%~1" == "/s" (
-  SET SILENT_MODE=TRUE
-  shift
-  goto BUILD_FLAGS_LOOP
-)
-@if "%~1" == "/r" (
-  SET REBUILD_MODE=-u
-  shift
-  goto BUILD_FLAGS_LOOP
-)
-@if "%~1" == "rom" (
-  SET BUILD_ROM_ONLY=rom
-  shift
-  goto BUILD_FLAGS_LOOP
-)
-:: Unknown build flag.
-shift
-goto BUILD_FLAGS_LOOP
-:BUILD_FLAGS_LOOP_DONE
-
-:: Output the build variables the user has selected.
-
-@echo.
-@echo  User Selected build options:
-@echo    SILENT_MODE = %SILENT_MODE%
-@echo    REBUILD_MODE = %REBUILD_MODE%
-@echo    BUILD_ROM_ONLY = %BUILD_ROM_ONLY%
-@echo.
-
-@if %SILENT_MODE% EQU TRUE goto BldSilent
-
-call build -n %NUMBER_OF_PROCESSORS% %REBUILD_MODE% %EXT_BUILD_FLAGS%
-
-@if %ERRORLEVEL% NEQ 0 goto BldFail
-@echo.
-@echo Running postbuild.bat to complete the build process.
-@echo.
-call %WORKSPACE_PLATFORM%\%PROJECT%\postbuild.bat %BUILD_ROM_ONLY% -@if %SCRIPT_ERROR% EQU 1 goto BldFail -@goto BldSuccess
-
-:BldSilent
-@if exist Build.log del Build.log
-
-@echo. > Build.log
-@echo ************************************************************************ >> Build.log
-@echo ***********             Build.bat is launched here           *********** >> Build.log
-@echo ************************************************************************ >> Build.log -@echo. >> Build.log
-
-call build -n %NUMBER_OF_PROCESSORS% %REBUILD_MODE% %EXT_BUILD_FLAGS% 1>>Build.log 2>&1
-
-@if %ERRORLEVEL% NEQ 0 goto BldFail
-@echo. >> Build.log
-@echo Running postbuild.bat to complete the build process. >> Build.log -@echo. >> Build.log -@call %WORKSPACE_PLATFORM%\%PROJECT%\postbuild.bat %BUILD_ROM_ONLY% 1>>Build.log 2>&1 -@If %SCRIPT_ERROR% EQU 1 goto BldFail
-
-:BldSuccess
-@echo.
-@echo TARGET:               %TARGET%
-@echo TOOL_CHAIN_TAG:       %TOOL_CHAIN_TAG%
-@echo BIOS location:        %BUILD_DIR%\FV
-@echo.
-@echo The EDKII BIOS build has successfully completed!
-@echo.
-@REM
-
-@goto BldEnd
-
-:BldFail
-cd %WORKSPACE_PLATFORM%\%PROJECT%
-@echo.
-@echo The EDKII BIOS Build has failed!
-@echo.
-@exit /b 1
-
-:BldEnd
-@if %SILENT_MODE% EQU TRUE (
-  @if exist EDK2.log del EDK2.log
-  @if exist Prep.log if exist Build.log copy Prep.log+Build.log EDK2.log
-)
-
-cd %WORKSPACE_PLATFORM%\%PROJECT%
\ No newline at end of file
diff --git a/Platform/Intel/ClevoOpenBoardPkg/N1xxWU/cln.bat b/Platform/Intel/ClevoOpenBoardPkg/N1xxWU/cln.bat
deleted file mode 100644
index 61c8a7d1a4..0000000000
--- a/Platform/Intel/ClevoOpenBoardPkg/N1xxWU/cln.bat
+++ /dev/null
@@ -1,48 +0,0 @@
-@REM @file
-@REM
-@REM Copyright (c) 2019, Intel Corporation. All rights reserved.<BR> -@REM SPDX-License-Identifier: BSD-2-Clause-Patent -@REM
-
-@echo off
-echo.
-echo Run build cleanall...
-echo.
-
-cd ..
-
-if not defined WORKSPACE set WORKSPACE=%cd% -if not defined WORKSPACE_PLATFORM set WORKSPACE_PLATFORM=%cd% -if not defined WORKSPACE_SILICON set WORKSPACE_SILICON=%cd%
-
-REM build cleanall
-
-echo.
-echo Directories to clean...
-echo.
-
-if exist %WORKSPACE%\build rmdir /q /s %WORKSPACE%\build -if exist %WORKSPACE%\conf\.cache rmdir /q /s %WORKSPACE%\conf\.cache
-
-echo.
-echo Files to clean...
-echo.
-
-if exist %WORKSPACE%\edk2.log del %WORKSPACE%\edk2.log -if exist %WORKSPACE%\Conf\build_rule.txt del %WORKSPACE%\Conf\build_rule.txt -if exist %WORKSPACE%\Conf\FrameworkDatabase.db del %WORKSPACE%\Conf\FrameworkDatabase.db
-if exist %WORKSPACE%\Conf\target.txt del %WORKSPACE%\Conf\target.txt -if exist %WORKSPACE%\Conf\tools_def.txt del %WORKSPACE%\Conf\tools_def.txt -@REM *.c.c is generated by Catalog Debug feature across code tree.
-@REM
-del /s *.c.c > nul 2>&1
-
-cd %WORKSPACE_PLATFORM%\%PROJECT%
-
-del /f /q Prep.log > nul 2>&1
-del /f /q ..\Build.log > nul 2>&1
-
-echo.
-echo All done...
-echo.
-@echo on
diff --git a/Platform/Intel/ClevoOpenBoardPkg/N1xxWU/postbuild.bat b/Platform/Intel/ClevoOpenBoardPkg/N1xxWU/postbuild.bat
deleted file mode 100644
index 5553645fbf..0000000000
--- a/Platform/Intel/ClevoOpenBoardPkg/N1xxWU/postbuild.bat
+++ /dev/null
@@ -1,39 +0,0 @@
-@REM @file
-@REM
-@REM Copyright (c) 2019, Intel Corporation. All rights reserved.<BR> -@REM SPDX-License-Identifier: BSD-2-Clause-Patent -@REM
-
-@REM #
-@REM #  Module Name:
-@REM #
-@REM #    postbuild.bat
-@REM #
-@REM #  Abstract:
-@REM #
-@REM #    Post build script.
-@REM #
-@REM #--*/
-
-@set SCRIPT_ERROR=0
-
-@if /I not "%0" == "%WORKSPACE_PLATFORM%\%PROJECT%\postbuild.bat" (
-  if /I not "%0" == "%WORKSPACE_PLATFORM%\%PROJECT%\postbuild" (
-    echo.
-    echo !!! ERROR !!! This postbuild.bat must run under workspace root using "%WORKSPACE_PLATFORM%\%PROJECT%\postbuild.bat" !!!
-    echo.
-    set SCRIPT_ERROR=1
-    goto :EOF
-  )
-)
-
-@cd %WORKSPACE_PLATFORM%
-
-@cd %WORKSPACE%
-
-@if %FSP_WRAPPER_BUILD% EQU TRUE (
-  del /f %WORKSPACE_FSP_BIN%\KabylakeFspBinPkg\Fsp_Rebased*.fd
-)
-
-@if %FSP_WRAPPER_BUILD% EQU TRUE exit /b
-
diff --git a/Platform/Intel/ClevoOpenBoardPkg/N1xxWU/prebuild.bat b/Platform/Intel/ClevoOpenBoardPkg/N1xxWU/prebuild.bat
deleted file mode 100644
index c18dd5e89d..0000000000
--- a/Platform/Intel/ClevoOpenBoardPkg/N1xxWU/prebuild.bat
+++ /dev/null
@@ -1,214 +0,0 @@
-@REM @file
-@REM  Pre build script.
-@REM
-@REM Copyright (c) 2019, Intel Corporation. All rights reserved.<BR> -@REM SPDX-License-Identifier: BSD-2-Clause-Patent -@REM
-
-cd ..
-
-@REM
-@REM Set build capsule flag with default being OFF -@REM
-
-@set CAPSULE_BUILD=0
-
-@if /I "%2" == "TRUE" (
-  @set CAPSULE_BUILD=1
-  goto StartCapsulePrep
-)
-
-:StartCapsulePrep
-@REM
-@REM Define platform specific environment variables.
-@REM
-if not defined WORKSPACE_PLATFORM set WORKSPACE_PLATFORM=%WORKSPACE%\edk2-platforms\Platform\Intel
-if not defined WORKSPACE_SILICON set WORKSPACE_SILICON=%WORKSPACE%\edk2-platforms\Silicon\Intel
-if not defined WORKSPACE_PLATFORM_BIN set WORKSPACE_PLATFORM_BIN=%WORKSPACE%\edk2-non-osi\Platform\Intel
-if not defined WORKSPACE_SILICON_BIN set WORKSPACE_SILICON_BIN=%WORKSPACE%\edk2-non-osi\Silicon\Intel
-if not defined WORKSPACE_FSP_BIN set WORKSPACE_FSP_BIN=%WORKSPACE%\FSP -if not defined WORKSPACE_CORE set WORKSPACE_CORE=%WORKSPACE%\edk2 -if not defined PLATFORM_PACKAGE set PLATFORM_PACKAGE=MinPlatformPkg -if not defined PLATFORM_BOARD_PACKAGE set PLATFORM_BOARD_PACKAGE=ClevoOpenBoardPkg
-if not defined BOARD set BOARD=N1xxWU
-if not defined PROJECT set PROJECT=%PLATFORM_BOARD_PACKAGE%\%BOARD%
-
-@set SCRIPT_ERROR=0
-
-@set CATALOG_DEBUG=0
-
-@REM Set basic environment.
-@echo.
-@echo Prebuild:  Run edksetup.bat batch file.
-@echo.
-@if %CATALOG_DEBUG% == 0 (
-  @del Conf\build_rule.txt
-)
-cd %WORKSPACE_CORE%
-@call edksetup.bat
-cd %WORKSPACE%
-@set EFI_SOURCE=%WORKSPACE_CORE%
-
-@REM
-@REM Setup Visual Studio environment. Order of precedence is 2012, 2013, 2010 and then 2008.
-@REM
-@REM NOTE: To override precedence set TOOL_CHAIN_TAG before calling prep.bat.
-@REM       Example: set TOOL_CHAIN_TAG=VS2008
-@REM
-
-@REM Check if tool chain has not been selected and Visual Studio 2014 is installed.
-@if not defined TOOL_CHAIN_TAG (
-  if defined VS140COMNTOOLS (
-    set TOOL_CHAIN_TAG=VS2015
-  )
-)
-
-@REM If Visual Studio 2014 is selected by priority or by preference, setup the environment variables.
-@if /I "%TOOL_CHAIN_TAG%"=="VS2015" (
-  echo.
-  echo Prebuild:  Set the VS2015 environment.
-  echo.
-  if not defined VSINSTALLDIR call "%VS140COMNTOOLS%\vsvars32.bat"
-  if /I "%VS140COMNTOOLS%" == "C:\Program Files\Microsoft Visual Studio 14.0\Common7\Tools\" (
-    set TOOL_CHAIN_TAG=VS2015
-  ) else (
-    set TOOL_CHAIN_TAG=VS2015x86
-  )
-)
-
-@REM Check if tool chain has not been selected and Visual Studio 2013 is installed.
-@if not defined TOOL_CHAIN_TAG (
-  if defined VS120COMNTOOLS (
-    set TOOL_CHAIN_TAG=VS2013
-  )
-)
-
-@REM If Visual Studio 2013 is selected by priority or by preference, setup the environment variables.
-@if /I "%TOOL_CHAIN_TAG%"=="VS2013" (
-  echo.
-  echo Prebuild:  Set the VS2013 environment.
-  echo.
-  if not defined VSINSTALLDIR call "%VS120COMNTOOLS%\vsvars32.bat"
-  if /I "%VS120COMNTOOLS%" == "C:\Program Files\Microsoft Visual Studio 12.0\Common7\Tools\" (
-    set TOOL_CHAIN_TAG=VS2013
-  ) else (
-    set TOOL_CHAIN_TAG=VS2013x86
-  )
-)
-
-@REM If no supported version of Visual Studio was detected, return an error.
-@if not defined TOOL_CHAIN_TAG (
-  echo.
-  echo !!! ERROR !!! Visual Studio not installed correctly!!!
-  echo.
-  set SCRIPT_ERROR=1
-  goto :EndPreBuild
-)
-
-echo Show CL revision
-cl
-
-@REM Set build TARGET.
-@if /I "%1" == "" (
-  set TARGET=DEBUG
-  set TARGET_SHORT=D
-) else if /I "%1" == "DEBUG" (
-  set TARGET=DEBUG
-  set TARGET_SHORT=D
-) else if /I "%1" == "TEST_RELEASE" (
-  set TARGET=RELEASE
-  set TARGET_SHORT=R
-) else if /I "%1" == "RELEASE" (
-  set TARGET=RELEASE
-  set TARGET_SHORT=R
-) else if /I "%1" == "RELEASE_PDB" (
-  set TARGET=RELEASE
-  set TARGET_SHORT=R
-) else (
-  echo.
-  echo !!! ERROR !!! Incorrect TARGET option for prebuild.bat. !!!
-  echo.
-  set SCRIPT_ERROR=1
-  goto :EndPreBuild
-)
-
-@set BUILD_DIR_PATH=%WORKSPACE%\Build\%PROJECT%\%TARGET%_%TOOL_CHAIN_TAG%
-@set BUILD_DIR=Build\%PROJECT%\%TARGET%_%TOOL_CHAIN_TAG%
-@set BUILD_X64=%BUILD_DIR_PATH%\X64
-@set BUILD_IA32=%BUILD_DIR_PATH%\IA32
-
-
-@echo.
-@echo Prebuild:  Set build environment.
-@echo.
-@if not exist %BUILD_DIR_PATH% (
-  mkdir %BUILD_DIR_PATH%
-)
-
-@findstr /V "ACTIVE_PLATFORM TARGET TARGET_ARCH TOOL_CHAIN_TAG BUILD_RULE_CONF" %WORKSPACE%\Conf\target.txt > %BUILD_DIR_PATH%\target.txt
-@echo ACTIVE_PLATFORM = %WORKSPACE_PLATFORM%/%PLATFORM_BOARD_PACKAGE%/%BOARD%/OpenBoardPkg.dsc        >> %BUILD_DIR_PATH%\target.txt
-@echo TARGET          = %TARGET%                                  >> %BUILD_DIR_PATH%\target.txt
-@echo TARGET_ARCH     = IA32 X64                                  >> %BUILD_DIR_PATH%\target.txt
-@echo TOOL_CHAIN_TAG  = %TOOL_CHAIN_TAG%                          >> %BUILD_DIR_PATH%\target.txt
-@echo BUILD_RULE_CONF = Conf/build_rule.txt                       >> %BUILD_DIR_PATH%\target.txt
-@move /Y %BUILD_DIR_PATH%\target.txt Conf
-
-@if %CAPSULE_BUILD% == 1 (
-  goto EndCapsulePrep
-)
-
-@REM
-@REM Set %FSP_WRAPPER_BUILD%
-@REM
-@set FSP_WRAPPER_BUILD=TRUE
-
-@if %FSP_WRAPPER_BUILD% EQU TRUE (
-  @REM Create dummy Fsp_Rebased_S_padded.fd to build the BiosInfo.inf if it is wrapper build, due to the SECTION inclusion
-  echo "" > %WORKSPACE_FSP_BIN%\KabylakeFspBinPkg\Fsp_Rebased_S_padded.fd
-  attrib -r %WORKSPACE_FSP_BIN%\KabylakeFspBinPkg\Fsp_Rebased_S_padded.fd
-)
-
-@REM
-@REM Set %PERFORMANCE_BUILD%
-@REM
-@set PERFORMANCE_BUILD=FALSE
-
-@REM
-@REM Set %FSP_BINARY_BUILD% and %FSP_TEST_RELEASE% -@REM -@set FSP_BINARY_BUILD=FALSE -@set FSP_TEST_RELEASE=FALSE
-
-@if "FSP_BINARY_BUILD"=="TRUE" (
-  @if %FSP_WRAPPER_BUILD% EQU FALSE goto :EndPreBuild
-)
-
-@if not exist %BUILD_X64% (
-  mkdir %BUILD_X64%
-)
-
-@set SECURE_BOOT_ENABLE=FALSE
-
-@REM
-@REM Skip BIOS_SIZE_OPTION if it is predefined -@REM -@if NOT "%BIOS_SIZE_OPTION%" == "" goto BiosSizeDone
-
-@set BIOS_SIZE_OPTION=
-
-@REM default size option is 6M
-@set BIOS_SIZE_OPTION=-DBIOS_SIZE_OPTION=SIZE_60
-
-:BiosSizeDone
-@echo BIOS_SIZE_OPTION=%BIOS_SIZE_OPTION%
-
-@echo   EFI_SOURCE           = %EFI_SOURCE%
-@echo   TARGET               = %TARGET%
-@echo   TARGET_ARCH          = IA32 X64
-@echo   TOOL_CHAIN_TAG       = %TOOL_CHAIN_TAG%
-@echo   WORKSPACE            = %WORKSPACE%
-@echo   WORKSPACE_CORE       = %WORKSPACE_CORE%
-@echo   EXT_BUILD_FLAGS      = %EXT_BUILD_FLAGS%
-@echo.
-:EndPreBuild
-cd %WORKSPACE_PLATFORM%\%PROJECT%
diff --git a/Platform/Intel/ClevoOpenBoardPkg/N1xxWU/prep.bat b/Platform/Intel/ClevoOpenBoardPkg/N1xxWU/prep.bat
deleted file mode 100644
index cb0d44f722..0000000000
--- a/Platform/Intel/ClevoOpenBoardPkg/N1xxWU/prep.bat
+++ /dev/null
@@ -1,79 +0,0 @@
-@REM @file
-@REM
-@REM Copyright (c) 2019, Intel Corporation. All rights reserved.<BR> -@REM SPDX-License-Identifier: BSD-2-Clause-Patent -@REM
-
-@echo OFF
-@set PrepRELEASE=DEBUG
-@set SILENT_MODE=FALSE
-@set CapsuleBuild=FALSE
-
-@set EXT_CONFIG_CLEAR=
-@set EXT_BUILD_FLAGS=
-
-:CmdLineParse
-if "" == "%1" (
-  goto Continue
-) else if "r" == "%1" (
-  set PrepRELEASE=RELEASE
-) else if "tr" == "%1" (
-  set PrepRELEASE=TEST_RELEASE
-) else if "rp" == "%1" (
-  set PrepRELEASE=RELEASE_PDB
-) else if "s" == "%1" (
-  set SILENT_MODE=TRUE
-) else if "help" == "%1" (
-  goto PrepHelp
-) else (
-  echo Invalid input arguments: %1
-  echo.
-  goto PrepHelp
-)
-SHIFT
-goto CmdLineParse
-
-:PrepHelp
-@echo Preparation for BIOS build.
-@echo.
-@echo prep [r][rp][s][help]
-@echo.
-@echo   r         To do release build. Default is debug build. See note 1
-@echo   rp        To do release build with Symbols - For source level debugging. See note 1
-@echo   s         To build in silent mode. . See note 1
-@echo.
-@echo 1) Re-running prep without these arguments cannot be used for
-@echo    incremental build. Hence, these inputs must be supplied each time
-@echo    prep are desired to be re-run.
-@echo.
-goto PrepDone
-
-:Continue
-@echo ==============================================
-
-if exist %WORKSPACE%\Prep.log del %WORKSPACE%\Prep.log
-
-:PrepReleaseCheck
-
-@if %SILENT_MODE% EQU TRUE goto BldSilent
-
-call prebuild.bat %PrepRelease% %CapsuleBuild% -goto PrePrepDone
-
-:BldSilent
-@echo ************************************************************************ >> %WORKSPACE%\Prep.log
-@echo ***********           Prebuild.bat is launched here          *********** >> %WORKSPACE%\Prep.log
-@echo ************************************************************************ >> %WORKSPACE%\Prep.log -call prebuild.bat %PrepRelease% %CapsuleBuild% 1>>%WORKSPACE%\Prep.log 2>&1
-
-:PrePrepDone
-@If %SCRIPT_ERROR% EQU 1 goto PrepFail
-@goto PrepDone
-
-:PrepFail
-@echo.
-@echo !! The EDKII BIOS build has failed in prep!
-@echo.
-@exit /b 1
-
-:PrepDone
\ No newline at end of file
--
2.19.1.windows.1





-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#45324): https://edk2.groups.io/g/devel/message/45324
Mute This Topic: https://groups.io/mt/32812476/1787277
Group Owner: devel+owner@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [importer@patchew.org]
-=-=-=-=-=-=-=-=-=-=-=-