]> git.proxmox.com Git - mirror_edk2.git/commitdiff
Add some EDK build configuration files and EDK DSC file as the templates to build...
authorqhuang8 <qhuang8@6f19259b-4bc3-4df7-8a09-765794883524>
Fri, 26 Oct 2007 08:18:08 +0000 (08:18 +0000)
committerqhuang8 <qhuang8@6f19259b-4bc3-4df7-8a09-765794883524>
Fri, 26 Oct 2007 08:18:08 +0000 (08:18 +0000)
This is a temporary solution to build EDK modules (e.g. Shell applications) under EDK II environment with EDK tools in ECP.
After the EDKII tools are ready to parse EDK II DSC file to build EDK INF file, these temporary build files can be safely removed.

git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@4221 6f19259b-4bc3-4df7-8a09-765794883524

15 files changed:
EdkCompatibilityPkg/Sample/Platform/Ipf/Build/Config.env [new file with mode: 0644]
EdkCompatibilityPkg/Sample/Platform/Ipf/Build/IPF.dsc [new file with mode: 0644]
EdkCompatibilityPkg/Sample/Platform/Ipf/Build/Makefile [new file with mode: 0644]
EdkCompatibilityPkg/Sample/Platform/Ipf/Build/PlatformTools.env [new file with mode: 0644]
EdkCompatibilityPkg/Sample/Platform/Ipf/Build/build.bat [new file with mode: 0644]
EdkCompatibilityPkg/Sample/Platform/Nt32/Build/Config.env [new file with mode: 0644]
EdkCompatibilityPkg/Sample/Platform/Nt32/Build/Makefile [new file with mode: 0644]
EdkCompatibilityPkg/Sample/Platform/Nt32/Build/Nt32.dsc [new file with mode: 0644]
EdkCompatibilityPkg/Sample/Platform/Nt32/Build/PlatformTools.env [new file with mode: 0644]
EdkCompatibilityPkg/Sample/Platform/Nt32/Build/build.bat [new file with mode: 0644]
EdkCompatibilityPkg/Sample/Platform/X64/Build/Config.env [new file with mode: 0644]
EdkCompatibilityPkg/Sample/Platform/X64/Build/Makefile [new file with mode: 0644]
EdkCompatibilityPkg/Sample/Platform/X64/Build/PlatformTools.env [new file with mode: 0644]
EdkCompatibilityPkg/Sample/Platform/X64/Build/X64.dsc [new file with mode: 0644]
EdkCompatibilityPkg/Sample/Platform/X64/Build/build.bat [new file with mode: 0644]

diff --git a/EdkCompatibilityPkg/Sample/Platform/Ipf/Build/Config.env b/EdkCompatibilityPkg/Sample/Platform/Ipf/Build/Config.env
new file mode 100644 (file)
index 0000000..d294b50
--- /dev/null
@@ -0,0 +1,31 @@
+#/*++\r
+#   \r
+#  Copyright (c) 2006 - 2007, Intel Corporation                                                         \r
+#  All rights reserved. This program and the accompanying materials                          \r
+#  are licensed and made available under the terms and conditions of the BSD License         \r
+#  which accompanies this distribution.  The full text of the license may be found at        \r
+#  http://opensource.org/licenses/bsd-license.php                                            \r
+#                                                                                            \r
+#  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,                     \r
+#  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.             \r
+#  \r
+#  Module Name:\r
+#\r
+#    Config.env\r
+#   \r
+#  Abstract:\r
+#   \r
+#    This file is used to define platform build configuration.\r
+#    It gets included by PlatformTools.env.\r
+#   \r
+#--*/\r
+\r
+BUILD_TARGET_DIRECTORY         = Build\r
+EFI_DEBUG                      = NO\r
+EFI_DEBUG_CLEAR_MEMORY         = NO\r
+EFI_SYMBOLIC_DEBUG             = NO\r
+EFI_GENERATE_INTERMEDIATE_FILE = NO\r
+UEFI_MODE                      = YES\r
+USE_VC8                        = NO\r
+USE_VC8_IPF                    = NO\r
+USE_NEWDDK                     = YES\r
diff --git a/EdkCompatibilityPkg/Sample/Platform/Ipf/Build/IPF.dsc b/EdkCompatibilityPkg/Sample/Platform/Ipf/Build/IPF.dsc
new file mode 100644 (file)
index 0000000..c36e6b0
--- /dev/null
@@ -0,0 +1,101 @@
+#/*++\r
+#\r
+# Copyright (c) 2004 - 2007, Intel Corporation                                                         \r
+# All rights reserved. This program and the accompanying materials                          \r
+# are licensed and made available under the terms and conditions of the BSD License         \r
+# which accompanies this distribution.  The full text of the license may be found at        \r
+# http://opensource.org/licenses/bsd-license.php                                            \r
+#                                                                                           \r
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,                     \r
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.             \r
+# \r
+#  Module Name:\r
+#\r
+#    IPF.dsc\r
+#\r
+#  Abstract:\r
+#\r
+#    This is the build description file containing the platform \r
+#    specific build definitions.\r
+#\r
+#\r
+#  Notes:\r
+#    \r
+#    The info in this file is broken down into sections. The start of a section\r
+#    is designated by a "[" in the first column. So the [=====] separater ends\r
+#    a section.\r
+#    \r
+#--*/\r
+\r
+\r
+[=============================================================================]\r
+#\r
+# This section gets processed first by the utility. Define any\r
+# macros that you may use elsewhere in this description file. This is the\r
+# mechanism by which you can pass parameters and defines to the makefiles\r
+# generated for each component. You can define it here, and then make an\r
+# assignment in the [makefile.common] section. For example, if here you\r
+# define MY_VAR = my_var_value, then you can add MY_VAR = $(MY_VAR) in\r
+# the [makefile.common] section and it becomes MY_VAR = my_var_value in\r
+# the output makefiles for each component.\r
+#\r
+[Defines]\r
+PLATFORM=$(PROJECT_NAME)\r
+\r
+\r
+[=============================================================================]\r
+#\r
+# Include other common build descriptions\r
+#\r
+!include "$(EDK_SOURCE)\Sample\Platform\Common.dsc"\r
+!include "$(EDK_SOURCE)\Sample\Platform\Common$(PROCESSOR).dsc"\r
+\r
+\r
+\r
+[=============================================================================]\r
+[Fv.Fv.Attributes]\r
+\r
+[Fv.Fv.options]\r
+\r
+[build.fv.Fv]\r
+\r
+[=============================================================================]\r
+#\r
+# These are the libraries that will be built by the master makefile\r
+#\r
+[=============================================================================]\r
+[Libraries]\r
+DEFINE EDK_PREFIX=\r
+\r
+!include "$(EDK_SOURCE)\Sample\Platform\EdkLibAll.dsc"\r
+\r
+#\r
+# EdkII Glue Library\r
+#\r
+#!include "$(EDK_SOURCE)\Sample\Platform\EdkIIGlueLibAll.dsc"\r
+\r
+[=============================================================================]\r
+#\r
+# These are platform specific libraries that must be built prior to building\r
+# certain drivers that depend upon them.\r
+#\r
+[=============================================================================]\r
+[Libraries.Platform]\r
+Sample\Platform\Generic\RuntimeDxe\StatusCode\Lib\RtMemoryStatusCode\RtMemoryStatusCode.inf\r
+Sample\Platform\Generic\RuntimeDxe\StatusCode\Lib\BsDataHubStatusCode\BsDataHubStatusCode.inf\r
+Sample\Platform\Generic\RuntimeDxe\StatusCode\Lib\BsSerialStatusCode\BsSerialStatusCode.inf\r
+\r
+#Other\Maintained\Application\Shell\Library\EfiShellLib.inf\r
+\r
+[=============================================================================]\r
+#\r
+# These are the components that will be built by the master makefile\r
+#\r
+[=============================================================================]\r
+[Components]\r
+DEFINE PACKAGE=Default\r
+\r
+#Other\Maintained\Application\Shell\Shell.inf\r
+Other\Maintained\Application\Shell\ShellFull.inf\r
+\r
+[=============================================================================]\r
diff --git a/EdkCompatibilityPkg/Sample/Platform/Ipf/Build/Makefile b/EdkCompatibilityPkg/Sample/Platform/Ipf/Build/Makefile
new file mode 100644 (file)
index 0000000..7df7d84
--- /dev/null
@@ -0,0 +1,140 @@
+#/*++\r
+#\r
+#  Copyright (c) 2004 - 2007, Intel Corporation                                                         \r
+#  All rights reserved. This program and the accompanying materials                          \r
+#  are licensed and made available under the terms and conditions of the BSD License         \r
+#  which accompanies this distribution.  The full text of the license may be found at        \r
+#  http://opensource.org/licenses/bsd-license.php                                            \r
+#                                                                                            \r
+#  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,                     \r
+#  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.             \r
+#  \r
+#  Module Name:\r
+#  \r
+#    Makefile\r
+#  \r
+#  Abstract:\r
+#   \r
+#    This makefile is used to build the IPF build tip.\r
+#   \r
+#--*/\r
+\r
+#\r
+# Everything depends on EDK_SOURCE & EDK_TOOLS_PATH. Make sure it's defined\r
+#\r
+!IFNDEF EDK_SOURCE\r
+!ERROR EDK_SOURCE environmental variable not set \r
+!ENDIF\r
+\r
+!IFNDEF EDK_TOOLS_PATH\r
+!MESSAGE EDK_TOOLS_PATH environmental variable not set, default setting used\r
+!ENDIF\r
+\r
+#\r
+# Set the processor type\r
+#\r
+PROCESSOR = IPF\r
+\r
+#\r
+# Define a toolchain so we can pick up the basic defines from\r
+# the EFI tool setup file.\r
+#\r
+TOOLCHAIN = TOOLCHAIN_MSVC\r
+\r
+!INCLUDE PlatformTools.env\r
+\r
+#\r
+# Target to build customer config\r
+#\r
+all : tempstamp_file build_tools makefiles builds\r
+\r
+#\r
+# Create a file to store the date and time, and used by SetStamp.exe\r
+#\r
+tempstamp_file:\r
+!IF DEFINED(DATE_STAMP) && DEFINED(TIME_STAMP)\r
+  @echo $(DATE_STAMP) $(TIME_STAMP) > GenStamp.txt\r
+!ELSEIF EXIST(GenStamp.txt)\r
+  - @del GenStamp.txt\r
+!ENDIF\r
+\r
+#\r
+# Make all the EFI build tools by calling the makefile\r
+#\r
+build_tools :\r
+  -if not exist $(EDK_TOOLS_OUTPUT) mkdir $(EDK_TOOLS_OUTPUT)\r
+  -if exist $(EDK_TOOLS_BIN)\*.* copy $(EDK_TOOLS_BIN)\*.* $(EDK_TOOLS_OUTPUT)\r
+  $(MAKE) -f $(EDK_TOOLS_SOURCE)\makefile PROCESSOR=$(PROCESSOR) BUILD_DIR=$(BUILD_DIR)\r
+  $(GUIDCHK) -b $(EDK_TOOLS_OUTPUT)\GuidDatabase.txt\r
+\r
+#\r
+# Run the utility that processes our description files and generates the\r
+# makefiles. Specify -v option for more verbose output.\r
+# Specify "-xref filename" to generate a cross-reference file of \r
+# basename-to-fileguid that can be used by VolInfo.\r
+#\r
+makefiles :\r
+  $(PROCESSDSC)                                    \\r
+    -d EFI_SOURCE=$(EDK_SOURCE)                    \\r
+    -d EDK_SOURCE=$(EDK_SOURCE)                    \\r
+    -d PROCESSOR=$(PROCESSOR)                      \\r
+    -d PROJECT_NAME=$(PROJECT_NAME)                \\r
+    -d OEMTOOLPATH=$(EDK_TOOLS_OUTPUT)             \\r
+    -d COMPRESS_METHOD=$(COMPRESS_METHOD)          \\r
+    -d UEFI_PREFIX=$(UEFI_PREFIX)                  \\r
+    -d PI_PREFIX=$(PI_PREFIX)                      \\r
+    -g $(EDK_TOOLS_OUTPUT)\GuidDatabase.txt        \\r
+    $(PROJECT_NAME).dsc\r
+\r
+\r
+#\r
+# Call all the makefiles that were generated by ProcessDsc. ProcessDsc\r
+# creates the makefile.out that calls all the component makefiles.\r
+#\r
+builds :\r
+  $(MAKE) -f makefile.out libraries\r
+  $(MAKE) -f makefile.out components\r
+\r
+#\r
+# Create a target to clean up all build directories\r
+#\r
+clean :\r
+  - @if exist vc??.* del vc??.* > NUL\r
+  - @if exist *.bak del *.bak > NUL\r
+  - @if exist $(PROCESSOR) rd /s /q $(PROCESSOR) > NUL\r
+  - @if exist ebc rd /s /q ebc > NUL\r
+  - @if exist fv rd /s /q fv > NUL\r
+  - @if exist Tools rd /s /q Tools > NUL\r
+  - @if exist makefile.out del makefile.out > NUL\r
+  - @if exist module.* del module.* > NUL\r
+  - @echo All targets cleaned\r
+\r
+#\r
+# Clean up all build directories except for tools.\r
+#\r
+cleanbuilds :\r
+  - @if exist *.bak del *.bak > NUL\r
+  - @if exist $(PROCESSOR) rd /s /q $(PROCESSOR) > NUL\r
+  - @if exist ebc rd /s /q ebc > NUL\r
+  - @if exist fv rd /s /q fv > NUL\r
+  - @if exist makefile.out del makefile.out > NUL\r
+  - @if exist module.* del module.* > NUL\r
+  - @echo All modules cleaned\r
+\r
+#\r
+# Clean up only the tools\r
+#\r
+cleantools :\r
+  - @if exist vc??.* del vc??.* > NUL\r
+  - @if exist Tools rd /s /q Tools > NUL\r
+  - @echo All tools cleaned\r
+\r
+#\r
+# Rebuild target, clean and build all\r
+#\r
+rebuild : clean all\r
+\r
+#\r
+# cleanall target to clean all build directories.\r
+#\r
+cleanall : clean\r
diff --git a/EdkCompatibilityPkg/Sample/Platform/Ipf/Build/PlatformTools.env b/EdkCompatibilityPkg/Sample/Platform/Ipf/Build/PlatformTools.env
new file mode 100644 (file)
index 0000000..b12060e
--- /dev/null
@@ -0,0 +1,69 @@
+#/*++\r
+#   \r
+#  Copyright (c) 2004 - 2006, Intel Corporation                                                         \r
+#  All rights reserved. This program and the accompanying materials                          \r
+#  are licensed and made available under the terms and conditions of the BSD License         \r
+#  which accompanies this distribution.  The full text of the license may be found at        \r
+#  http://opensource.org/licenses/bsd-license.php                                            \r
+#                                                                                            \r
+#  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,                     \r
+#  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.             \r
+#  \r
+#  Module Name:\r
+#\r
+#    PlatformTools.env\r
+#   \r
+#  Abstract:\r
+#   \r
+#    This file is used to define platform specific environment variables.\r
+#    It gets included by every makefile.\r
+#   \r
+#--*/\r
+\r
+!INCLUDE Config.env\r
+\r
+#\r
+# Set the project name\r
+#\r
+PROJECT_NAME = IPF\r
+\r
+#\r
+# Set the build directory\r
+#\r
+BUILD_DIR = $(EDK_SOURCE)\Sample\Platform\$(PROJECT_NAME)\$(BUILD_TARGET_DIRECTORY)\r
+\r
+#\r
+# Define compiler names\r
+#\r
+\r
+!IFNDEF EDK_TOOLS_PATH\r
+EFI_ASL_LOCAL           = YES\r
+!ELSE \r
+!IF "$(USE_NEWDDK)" == "YES"\r
+EFI_COMPILER_NAME       = DDK3790.1830\r
+EFI_ASSEMBLER_NAME      = DDK3790.1830\r
+!ELSE\r
+EFI_COMPILER_NAME       = DDK3790\r
+EFI_ASSEMBLER_NAME      = DDK3790\r
+!ENDIF\r
+EFI_ASL_LOCAL           = NO\r
+!ENDIF\r
+\r
+#\r
+# These flags are specific to this platform.  If a flag is not specific to this \r
+# platform the flag should be placed in the CommonTools.env file.\r
+# Processor architecture specific and global macros can be found in \r
+# CommonTools.env, macros named xxx_ARCH_FLAGS and xxx_STD_FLAGS respectively.\r
+#\r
+C_PROJ_FLAGS          = /Os\r
+ASM_PROJ_FLAGS        =\r
+LINK_PROJ_FLAGS       = /ALIGN:32\r
+LIB_PROJ_FLAGS        =\r
+EBC_C_PROJ_FLAGS      =\r
+EBC_LINK_PROJ_FLAGS   =\r
+EBC_LIB_PROJ_FLAGS    =\r
+\r
+#\r
+# Include processor architecture specific and general EFI build flags.\r
+#\r
+!INCLUDE $(EDK_SOURCE)\Sample\CommonTools.env
\ No newline at end of file
diff --git a/EdkCompatibilityPkg/Sample/Platform/Ipf/Build/build.bat b/EdkCompatibilityPkg/Sample/Platform/Ipf/Build/build.bat
new file mode 100644 (file)
index 0000000..c224c2e
--- /dev/null
@@ -0,0 +1,304 @@
+@rem #/*++\r
+@rem #  \r
+@rem #  Copyright (c) 2007, Intel Corporation                                                         \r
+@rem #  All rights reserved. This program and the accompanying materials                          \r
+@rem #  are licensed and made available under the terms and conditions of the BSD License         \r
+@rem #  which accompanies this distribution.  The full text of the license may be found at        \r
+@rem #  http://opensource.org/licenses/bsd-license.php                                            \r
+@rem #                                                                                            \r
+@rem #  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,                     \r
+@rem #  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.             \r
+@rem #  \r
+@rem #  Module Name:\r
+@rem #  \r
+@rem #    build.bat\r
+@rem #  \r
+@rem #  Abstract:\r
+@rem #    \r
+@rem #    This script provides single module build, clean and find function\r
+@rem #    based on module name.\r
+@rem #    \r
+@rem #    The auto-generated module.list file records all module names \r
+@rem #    described in the current platform.dsc.\r
+@rem #    \r
+@rem #--*/ \r
+\r
+@echo off\r
+\r
+setlocal\r
+@rem initilize local variable\r
+set FUNCTION=build\r
+set MODULE=\r
+set UPDATE=\r
+set VERBOSE=\r
+\r
+:parse\r
+if /I "%1"=="/c" (\r
+  set FUNCTION=clean\r
+  shift\r
+  goto parse\r
+)\r
+if /I "%1"=="clean" (\r
+  set FUNCTION=clean\r
+  shift\r
+  goto parse\r
+)\r
+if /I "%1"=="/r" (\r
+  set FUNCTION=rebuild\r
+  shift\r
+  goto parse\r
+)\r
+if /I "%1"=="/h" (\r
+  set FUNCTION=usage\r
+  shift\r
+  goto parse\r
+)\r
+if /I "%1"=="/?" (\r
+  set FUNCTION=usage\r
+  shift\r
+  goto parse\r
+)\r
+if /I "%1"=="/f" (\r
+  set FUNCTION=find\r
+  shift\r
+  goto parse\r
+)\r
+if /I "%1"=="/a" (\r
+  set UPDATE=TRUE\r
+  shift\r
+  goto parse\r
+)\r
+if /I "%1"=="/v" (\r
+  set VERBOSE=TRUE\r
+  shift\r
+  goto parse\r
+)\r
+if not "%1"=="" (\r
+  set MODULE=%1\r
+  shift\r
+  goto parse\r
+) else (\r
+  @rem no other paramters\r
+  if "%FUNCTION%"=="rebuild" goto build\r
+  goto %FUNCTION%\r
+)\r
+\r
+:build\r
+set StartTime=%time%\r
+@rem if no input, build all\r
+if "%MODULE%"=="" (\r
+  if "%FUNCTION%"=="rebuild" (\r
+    nmake -nologo -f Makefile clean\r
+  )\r
+  nmake -nologo -f Makefile all\r
+  goto endtime\r
+)\r
+@rem then try to build special targets: all, fast, tools.\r
+if /I "%MODULE%"=="all" (\r
+  @rem build all modules and tools.\r
+  if "%FUNCTION%"=="rebuild" (\r
+    nmake -nologo -f Makefile cleanall\r
+  )\r
+  nmake -nologo -f Makefile all\r
+  goto endtime\r
+)\r
+if /I "%MODULE%"=="fast" (\r
+  @rem build fast target to skip FV=NULL modules.\r
+  if "%FUNCTION%"=="rebuild" (\r
+    nmake -nologo -f Makefile clean\r
+  )\r
+  nmake -nologo -f Makefile fast\r
+  goto endtime\r
+)\r
+if /I "%MODULE%"=="tools" (\r
+  @rem build all tools.\r
+  if "%FUNCTION%"=="rebuild" (\r
+    nmake -nologo -f Makefile cleantools\r
+  )\r
+  nmake -nologo -f Makefile build_tools\r
+  echo.\r
+  echo All tools are built.\r
+  goto endtime\r
+)\r
+@rem build single module, update build makefiles\r
+if "%FUNCTION%"=="rebuild" (\r
+  nmake -nologo -f module.mak %MODULE%Clean 2>NUL\r
+)\r
+nmake -nologo -f Makefile flashmap > NUL 2>&1\r
+nmake -nologo -f Makefile makefiles\r
+if errorlevel 1 goto builderror\r
+@rem check whether input module name is described in current dsc file. \r
+findstr /I /C:" %MODULE% " module.list > NUL\r
+if errorlevel 1 (\r
+  echo.\r
+  echo.\r
+  findstr /I /C:"%MODULE%" module.list > NUL\r
+  if errorlevel 1 goto finderror\r
+  for /F %%A in ('findstr /I /C:"%MODULE%" module.list') do echo  %%A\r
+  echo.\r
+  echo Warning!!! Your specified module name can't be found. \r
+  echo One of the above modules may be what you want to build.\r
+  goto end\r
+)\r
+@rem build this module\r
+nmake -nologo -f module.mak %MODULE%Build \r
+echo.\r
+if "%FUNCTION%"=="rebuild" (\r
+  echo Module %MODULE% is rebuilt.\r
+) else (\r
+  echo Module %MODULE% is built.\r
+)\r
+:endtime\r
+@rem output build time.\r
+set EndTime=%time%\r
+echo.\r
+echo Start time %StartTime%\r
+echo End   time %EndTime%\r
+goto end\r
+\r
+:clean\r
+@rem if no input, default clean all build directories.\r
+if "%MODULE%"=="" (\r
+  nmake -nologo -f Makefile clean\r
+  goto end\r
+)\r
+@rem first try to clean special tasks: all, modules and tools\r
+if /I "%MODULE%"=="all" (\r
+  nmake -nologo -f Makefile cleanall\r
+  goto end\r
+)\r
+if /I "%MODULE%"=="modules" (\r
+  nmake -nologo -f Makefile cleanbuilds\r
+  goto end\r
+)\r
+if /I "%MODULE%"=="tools" (\r
+  nmake -nologo -f Makefile cleantools\r
+  goto end\r
+)\r
+@rem clean single module  \r
+@rem check whether input module name is in module.list file. \r
+if not exist module.list (\r
+  echo Module list info doesn't exist.\r
+  echo Processing dsc file to generate module list info.\r
+  nmake -nologo -f Makefile flashmap > NUL 2>&1\r
+  nmake -nologo -f Makefile makefiles > error.log 2>&1\r
+  if errorlevel 1 goto builderror\r
+)\r
+findstr /I /C:" %MODULE% " module.list > NUL\r
+if errorlevel 1 (\r
+  echo.\r
+  findstr /I /C:"%MODULE%" module.list > NUL\r
+  if errorlevel 1 goto finderror\r
+  for /F %%A in ('findstr /I /C:"%MODULE%" module.list') do echo  %%A\r
+  echo.\r
+  echo Warning!!! Your specified module name can't be found. \r
+  echo One of the above modules may be what you want to clean. \r
+  goto end\r
+)\r
+@rem clean this module \r
+nmake -nologo -f module.mak %MODULE%Clean 2>NUL\r
+echo.\r
+echo Module %MODULE% is cleaned.\r
+goto end\r
+\r
+:find\r
+@rem find match module name by subname.\r
+if "%UPDATE%"=="TRUE" (\r
+  echo Processing dsc file to update module list info.\r
+  nmake -nologo -f Makefile flashmap > NUL 2>&1\r
+  nmake -nologo -f Makefile makefiles > error.log 2>&1\r
+  if errorlevel 1 goto builderror\r
+)\r
+if not exist module.list (\r
+  echo Module list info doesn't exist.\r
+  echo Processing dsc file to generate module list info.\r
+  nmake -nologo -f Makefile flashmap > NUL 2>&1\r
+  nmake -nologo -f Makefile makefiles > error.log 2>&1\r
+  if errorlevel 1 goto builderror\r
+)\r
+if "%MODULE%"=="" (\r
+  @rem display all\r
+  echo.\r
+  if "%VERBOSE%"=="TRUE" ( \r
+    type module.list\r
+  ) else (\r
+    @rem only output module name without module.inf file name\r
+    for /F %%A in (module.list) do echo  %%A\r
+  )\r
+) else (\r
+  @rem display match module name\r
+  echo.\r
+  if "%VERBOSE%"=="TRUE" (\r
+    findstr /I /C:"%MODULE%" module.list\r
+    if errorlevel 1 goto notfind\r
+  ) else (\r
+    findstr /I /C:"%MODULE%" module.list > NUL\r
+    if errorlevel 1 goto notfind\r
+    for /F %%A in ('findstr /I /C:"%MODULE%" module.list') do echo  %%A\r
+  )\r
+)\r
+goto end\r
+\r
+:usage\r
+echo build or clean single module based on module name after tools are built.\r
+echo.\r
+echo build [/r] [/c] [/f] [/h] [modulename]\r
+echo.\r
+echo build [/r] [modulename]\r
+echo       build single module, such as build DxeMain.\r
+echo       If /r is specified, the target will be rebuit after cleaned first.\r
+echo       if no input modulename or modulename is all, then build all\r
+echo       Specail build targets: all, fast, tools.\r
+echo       These special targets may not exist in your tip main makefile.\r
+echo       build       - build all tools and modules\r
+echo       build all   - build all tools and modules\r
+echo       build fast  - build all without FV=NULL modules\r
+echo       build tools - build all tools.\r
+echo.\r
+echo build /c    [modulename]\r
+echo build clean [modulename]\r
+echo       remove the temp generated files for single module  \r
+echo       if no input modulename, then clean all\r
+echo       Specail clean targets: all, modules, tools.\r
+echo       These special targets may not exist in your tip main makefile.\r
+echo       build /c         - clean up all build directories\r
+echo       build /c all     - clean up all build directories and binary dirs.\r
+echo       build /c modules - clean up all build directories except for tools.\r
+echo       build /c tools   - clean up only tools directory.\r
+echo.\r
+echo build /f [/a] [/v] [subname]\r
+echo       find all matched modulename with the sub string of module name.\r
+echo       option /a re-processes dsc files to update module name list.\r
+echo       option /v outputs module name and module.inf file name both.\r
+echo.\r
+echo build /h\r
+echo build /?\r
+echo       display help information. \r
+echo.\r
+goto end\r
+\r
+:notfind\r
+echo Warning!!! Your specified module name can't be found.\r
+echo Try to use /f /a options to update module name list.\r
+goto end\r
+\r
+:finderror\r
+echo Warning!!! Your specified module name can't be found.\r
+echo Try to use /f to find modules that you want to build.\r
+echo Or use /h to get the helpinfo of this script.\r
+goto end\r
+\r
+:builderror\r
+if exist error.log type error.log\r
+echo.\r
+if not exist Tools\ProcessDsc.exe (\r
+  echo.\r
+  echo Error!!! Build tools may not be ready. Try to build tools first.\r
+  echo.\r
+)\r
+del module.* > NUL 2>&1\r
+goto end\r
+\r
+:end\r
+if exist error.log del error.log\r
+echo on\r
diff --git a/EdkCompatibilityPkg/Sample/Platform/Nt32/Build/Config.env b/EdkCompatibilityPkg/Sample/Platform/Nt32/Build/Config.env
new file mode 100644 (file)
index 0000000..43d7fa9
--- /dev/null
@@ -0,0 +1,33 @@
+#/*++\r
+#   \r
+#  Copyright (c) 2006 - 2007, Intel Corporation                                                         \r
+#  All rights reserved. This program and the accompanying materials                          \r
+#  are licensed and made available under the terms and conditions of the BSD License         \r
+#  which accompanies this distribution.  The full text of the license may be found at        \r
+#  http://opensource.org/licenses/bsd-license.php                                            \r
+#                                                                                            \r
+#  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,                     \r
+#  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.             \r
+#  \r
+#  Module Name:\r
+#\r
+#    Config.env\r
+#   \r
+#  Abstract:\r
+#   \r
+#    This file is used to define platform build configuration.\r
+#    It gets included by PlatformTools.env.\r
+#   \r
+#--*/\r
+\r
+BUILD_TARGET_DIRECTORY         = Build\r
+EFI_DEBUG                      = YES\r
+EFI_DEBUG_CLEAR_MEMORY         = YES\r
+EFI_PEI_PERFORMANCE            = YES\r
+EFI_DXE_PERFORMANCE            = YES\r
+EFI_SYMBOLIC_DEBUG             = YES\r
+EFI_GENERATE_INTERMEDIATE_FILE = NO\r
+EFI_PEI_REPORT_STATUS_CODE     = YES\r
+UEFI_MODE                      = YES\r
+PI_MODE                        = YES\r
+USE_VC8                        = NO\r
diff --git a/EdkCompatibilityPkg/Sample/Platform/Nt32/Build/Makefile b/EdkCompatibilityPkg/Sample/Platform/Nt32/Build/Makefile
new file mode 100644 (file)
index 0000000..8ad8646
--- /dev/null
@@ -0,0 +1,231 @@
+#/*++\r
+#\r
+#  Copyright (c) 2004 - 2007, Intel Corporation                                                         \r
+#  All rights reserved. This program and the accompanying materials                          \r
+#  are licensed and made available under the terms and conditions of the BSD License         \r
+#  which accompanies this distribution.  The full text of the license may be found at        \r
+#  http://opensource.org/licenses/bsd-license.php                                            \r
+#                                                                                            \r
+#  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,                     \r
+#  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.             \r
+#  \r
+#  Module Name:\r
+#  \r
+#    Makefile\r
+#  \r
+#  Abstract:\r
+#   \r
+#    This makefile is used to build the NT emulation.\r
+#   \r
+#--*/\r
+\r
+#\r
+# Everything depends on EDK_SOURCE & EDK_TOOLS_PATH. Make sure it's defined\r
+#\r
+!IFNDEF EDK_SOURCE\r
+!ERROR EDK_SOURCE environmental variable not set \r
+!ENDIF\r
+\r
+!IFNDEF EDK_TOOLS_PATH\r
+!MESSAGE EDK_TOOLS_PATH environmental variable not set, default setting used\r
+!ENDIF\r
+\r
+#\r
+# Set the processor type\r
+#\r
+PROCESSOR = IA32\r
+\r
+#\r
+# Define a toolchain so we can pick up the basic defines from\r
+# the EFI tool setup file.\r
+#\r
+TOOLCHAIN = TOOLCHAIN_MSVC\r
+\r
+!INCLUDE PlatformTools.env\r
+\r
+#\r
+# Default target\r
+#\r
+all : customer\r
+\r
+#\r
+# Target to build customer config\r
+#\r
+customer : tempstamp_file build_tools makefiles builds\r
+\r
+#\r
+# Target to build everything quickly\r
+#\r
+fast : build_tools fast_makefiles builds\r
+\r
+#\r
+# Create a file to store the date and time, and used by SetStamp.exe\r
+#\r
+tempstamp_file:\r
+!IF DEFINED(DATE_STAMP) && DEFINED(TIME_STAMP)\r
+  @echo $(DATE_STAMP) $(TIME_STAMP) > GenStamp.txt\r
+!ELSEIF EXIST(GenStamp.txt)\r
+  - @del GenStamp.txt\r
+!ENDIF\r
+\r
+#\r
+# Make all the EFI build tools by calling the makefile\r
+#\r
+build_tools :\r
+  -if not exist $(EDK_TOOLS_OUTPUT) mkdir $(EDK_TOOLS_OUTPUT)\r
+  -if exist $(EDK_TOOLS_BIN)\*.* copy $(EDK_TOOLS_BIN)\*.* $(EDK_TOOLS_OUTPUT)\r
+  $(MAKE) -f $(EDK_TOOLS_SOURCE)\makefile PROCESSOR=$(PROCESSOR) BUILD_DIR=$(BUILD_DIR)\r
+  $(GUIDCHK) -b $(EDK_TOOLS_OUTPUT)\GuidDatabase.txt  \r
+\r
+#\r
+# Run ProcessDsc on our main description files to generate the\r
+# makefiles and package files. Specify -v option for more verbose output.\r
+# Specify "-xref filename" to generate a cross-reference file of \r
+# basename-to-fileguid that can be used by VolInfo.\r
+#\r
+makefiles : \r
+  $(PROCESSDSC)                                    \\r
+    -d EFI_SOURCE=$(EDK_SOURCE)                    \\r
+    -d EDK_SOURCE=$(EDK_SOURCE)                    \\r
+    -d PROCESSOR=$(PROCESSOR)                      \\r
+    -d PROJECT_NAME=$(PROJECT_NAME)                \\r
+    -d COMPRESS_METHOD=$(COMPRESS_METHOD)          \\r
+    -d OEMTOOLPATH=$(EDK_TOOLS_OUTPUT)             \\r
+    -d SHELL_INF=$(SHELL_INF)                      \\r
+    -d UEFI_PREFIX=$(UEFI_PREFIX)                  \\r
+    -d PI_PREFIX=$(PI_PREFIX)                      \\r
+    -d CAPSULE_INF=$(CAPSULE_INF)                  \\r
+    -d ATAPI_PASS_THRU_INF=$(ATAPI_PASS_THRU_INF)  \\r
+    -d DEVPATH_INF=$(DEVPATH_INF)                  \\r
+    -d GRAPHICS_INF=$(GRAPHICS_INF)                \\r
+    -g $(EDK_TOOLS_OUTPUT)\GuidDatabase.txt        \\r
+    -xref FV\Guid.xref                             \\r
+    $(PROJECT_NAME).dsc\r
+    \r
+#\r
+# Build faster by not building components with FV=NULL. Override in the\r
+# DSC file by adding SKIP_FV_NULL=0 on the component lines you want built\r
+# but still have FV=NULL. For example:\r
+#\r
+# Dxe\Drivers\MyDriver\MyDriver.inf  FV=NULL  SKIP_FV_NULL=0\r
+#\r
+fast_makefiles : \r
+  $(PROCESSDSC)                                    \\r
+    -d EFI_SOURCE=$(EDK_SOURCE)                    \\r
+    -d EDK_SOURCE=$(EDK_SOURCE)                    \\r
+    -d PROCESSOR=$(PROCESSOR)                      \\r
+    -d PROJECT_NAME=$(PROJECT_NAME)                \\r
+    -d COMPRESS_METHOD=$(COMPRESS_METHOD)          \\r
+    -d OEMTOOLPATH=$(EDK_TOOLS_OUTPUT)             \\r
+    -d SHELL_INF=$(SHELL_INF)                      \\r
+    -d UEFI_PREFIX=$(UEFI_PREFIX)                  \\r
+    -d PI_PREFIX=$(PI_PREFIX)                      \\r
+    -d CAPSULE_INF=$(CAPSULE_INF)                  \\r
+    -d ATAPI_PASS_THRU_INF=$(ATAPI_PASS_THRU_INF)  \\r
+    -d DEVPATH_INF=$(DEVPATH_INF)                  \\r
+    -d GRAPHICS_INF=$(GRAPHICS_INF)                \\r
+    -g $(EDK_TOOLS_OUTPUT)\GuidDatabase.txt        \\r
+    -xref FV\Guid.xref                             \\r
+    -d SKIP_FV_NULL=1                              \\r
+    $(PROJECT_NAME).dsc\r
+\r
+#\r
+# Create the guid-to-basename cross reference file of protocols\r
+# used by volinfo for decoding dependency expressions.\r
+#\r
+protocols.xref : \r
+  -@if not exist fv mkdir FV\r
+  cd $(EDK_SOURCE)\r
+  $(GUIDCHK) -g -u $(BUILD_TARGET_DIRECTORY) -e inf -x > $(BUILD_DIR)\Fv\protocols.xref\r
+  cd $(BUILD_DIR)\r
+\r
+#\r
+# Call all the makefiles that were generated by ProcessDsc. ProcessDsc\r
+# creates the makefile.out that calls all the component makefiles.\r
+#\r
+builds :\r
+  $(MAKE) -f makefile.out\r
+\r
+#\r
+# Useful targets\r
+#\r
+\r
+#\r
+# Define a pseudo-target that skips over compiling the build tools and\r
+# also skips creation of the makefiles for the components. The user\r
+# has to be aware that any changes to INF files renders this target\r
+# invalid.\r
+#\r
+quick : builds\r
+\r
+#\r
+# Define a pseudo-target to start building with the libraries or with the \r
+# components.\r
+#\r
+libraries :\r
+  $(MAKE) -f makefile.out libraries\r
+\r
+components :\r
+  $(MAKE) -f makefile.out components\r
+\r
+#\r
+# Make a pseudo-target to simplify running of the NT emulation. \r
+#\r
+!IF "$(EFI_WIN_NT_FILE_SYSTEM)" == ""\r
+EFI_WIN_NT_FILE_SYSTEM = $(EDK_SOURCE)\Other\Maintained\Application\$(UEFI_PREFIX)Shell\bin\ia32\Apps\r
+!ELSE\r
+EFI_WIN_NT_FILE_SYSTEM = $(EFI_WIN_NT_FILE_SYSTEM)!$(EDK_SOURCE)\Other\Maintained\Application\$(UEFI_PREFIX)Shell\bin\ia32\Apps\r
+!ENDIF\r
+\r
+#\r
+# Make browse info file\r
+#\r
+bsc:\r
+  - dir /s /b *.sbr > $(PROCESSOR)\temp.rm\r
+  $(BSCMAKE) /n /o $(PROCESSOR)\$(PROJECT_NAME).bsc "@$(PROCESSOR)\temp.rm"\r
+\r
+#\r
+# Create a target to clean up all build directories\r
+#\r
+clean :\r
+  - @if exist vc??.* del vc??.* > NUL\r
+  - @if exist *.bak del *.bak > NUL\r
+  - @if exist $(PROCESSOR) rd /s /q $(PROCESSOR) > NUL\r
+  - @if exist ipf rd /s /q ipf > NUL\r
+  - @if exist ebc rd /s /q ebc > NUL\r
+  - @if exist fv rd /s /q fv > NUL\r
+  - @if exist Tools rd /s /q Tools > NUL\r
+  - @if exist makefile.out del makefile.out > NUL\r
+  - @if exist module.* del module.* > NUL\r
+  - @echo All targets cleaned\r
+\r
+#\r
+# Clean up all build directories except for tools.\r
+#\r
+cleanbuilds :\r
+  - @if exist *.bak del *.bak > NUL\r
+  - @if exist $(PROCESSOR) rd /s /q $(PROCESSOR) > NUL\r
+  - @if exist ipf rd /s /q ipf > NUL\r
+  - @if exist ebc rd /s /q ebc > NUL\r
+  - @if exist fv rd /s /q fv > NUL\r
+  - @if exist makefile.out del makefile.out > NUL\r
+  - @if exist module.* del module.* > NUL\r
+  - @echo All modules cleaned\r
+\r
+#\r
+# Clean up only the tools\r
+#\r
+cleantools :\r
+  - @if exist vc??.* del vc??.* > NUL\r
+  - @if exist Tools rd /s /q Tools > NUL\r
+  - @echo All tools cleaned\r
+\r
+#\r
+# Rebuild target, clean and build all\r
+#\r
+rebuild : clean all\r
+\r
+#\r
+# cleanall target to clean all build directories.\r
+#\r
+cleanall : clean\r
diff --git a/EdkCompatibilityPkg/Sample/Platform/Nt32/Build/Nt32.dsc b/EdkCompatibilityPkg/Sample/Platform/Nt32/Build/Nt32.dsc
new file mode 100644 (file)
index 0000000..03c14e0
--- /dev/null
@@ -0,0 +1,154 @@
+#/*++\r
+#\r
+# Copyright (c) 2004 - 2007, Intel Corporation                                                         \r
+# All rights reserved. This program and the accompanying materials                          \r
+# are licensed and made available under the terms and conditions of the BSD License         \r
+# which accompanies this distribution.  The full text of the license may be found at        \r
+# http://opensource.org/licenses/bsd-license.php                                            \r
+#                                                                                           \r
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,                     \r
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.             \r
+# \r
+#  Module Name:\r
+#\r
+#    Nt32.dsc\r
+#\r
+#  Abstract:\r
+#\r
+#    This is the build description file containing the platform \r
+#    build definitions.\r
+#\r
+#\r
+#  Notes:\r
+#    \r
+#    The info in this file is broken down into sections. The start of a section\r
+#    is designated by a "[" in the first column. So the [=====] separater ends\r
+#    a section.\r
+#    \r
+#--*/\r
+\r
+\r
+[=============================================================================]\r
+#\r
+# This section gets processed first by the utility. Define any\r
+# macros that you may use elsewhere in this description file. This is the\r
+# mechanism by which you can pass parameters and defines to the makefiles\r
+# generated for each component. You can define it here, and then make an\r
+# assignment in the [makefile.common] section. For example, if here you\r
+# define MY_VAR = my_var_value, then you can add MY_VAR = $(MY_VAR) in\r
+# the [makefile.common] section and it becomes MY_VAR = my_var_value in\r
+# the output makefiles for each component.\r
+#\r
+[Defines]\r
+PLATFORM                  = $(PROJECT_NAME)\r
+\r
+[=============================================================================]\r
+#\r
+# Include other common build descriptions\r
+#\r
+!include "$(EDK_SOURCE)\Sample\Platform\Common.dsc"\r
+!include "$(EDK_SOURCE)\Sample\Platform\Common$(PROCESSOR).dsc"\r
+\r
+[=============================================================================]\r
+#\r
+# These control the generation of the FV files\r
+#\r
+[=============================================================================]\r
+[Fv.Fv.Attributes]\r
+\r
+[Fv.Fv.options]\r
+\r
+[Build.Fv.Fv]\r
+\r
+[=============================================================================]\r
+#\r
+# These are the libraries that will be built by the master makefile\r
+#\r
+[=============================================================================]\r
+[Libraries]\r
+DEFINE EDK_PREFIX=\r
+\r
+!include "$(EDK_SOURCE)\Sample\Platform\EdkLibAll.dsc"\r
+\r
+#\r
+# EdkII Glue Library\r
+#\r
+#!include "$(EDK_SOURCE)\Sample\Platform\EdkIIGlueLibAll.dsc"\r
+\r
+[=============================================================================]\r
+#\r
+# These are platform specific libraries that must be built prior to building\r
+# certain drivers that depend upon them.\r
+#\r
+[=============================================================================]\r
+[Libraries.Platform]\r
+Sample\Platform\Nt32\Protocol\EdkNt32ProtocolLib.inf\r
+Sample\Library\Dxe\WinNt\WinNtLib.inf\r
+#Sample\Platform\Generic\MonoStatusCode\Library\Pei\MemoryStatusCode\MemoryStatusCode.inf\r
+Sample\Platform\Generic\RuntimeDxe\StatusCode\Lib\BsDataHubStatusCode\BsDataHubStatusCode.inf\r
+Sample\Platform\Generic\RuntimeDxe\StatusCode\Lib\RtMemoryStatusCode\RtMemoryStatusCode.inf\r
+Sample\Platform\Generic\RuntimeDxe\StatusCode\Lib\RtPlatformStatusCode\$(PROJECT_NAME)\RtPlatformStatusCode.inf\r
+\r
+Other\Maintained\Application\Shell\Library\EfiShellLib.inf\r
+\r
+[=============================================================================]\r
+#\r
+# These are the components that will be built by the master makefile\r
+#\r
+[=============================================================================]\r
+[Components]\r
+DEFINE PACKAGE=Default\r
+\r
+#Other\Maintained\Application\Shell\Shell.inf\r
+#Other\Maintained\Application\Shell\ShellFull.inf\r
+Other\Maintained\Application\Shell\attrib\attrib.inf\r
+Other\Maintained\Application\Shell\cls\cls.inf\r
+Other\Maintained\Application\Shell\comp\comp.inf\r
+Other\Maintained\Application\Shell\cp\cp.inf\r
+Other\Maintained\Application\Shell\date\date.inf\r
+Other\Maintained\Application\Shell\dblk\dblk.inf\r
+Other\Maintained\Application\Shell\devices\devices.inf\r
+Other\Maintained\Application\Shell\DeviceTree\devicetree.inf\r
+Other\Maintained\Application\Shell\dmem\dmem.inf\r
+Other\Maintained\Application\Shell\dmpstore\dmpstore.inf\r
+Other\Maintained\Application\Shell\drivers\drivers.inf\r
+Other\Maintained\Application\Shell\drvcfg\drvcfg.inf\r
+Other\Maintained\Application\Shell\drvdiag\drvdiag.inf\r
+Other\Maintained\Application\Shell\edit\edit.inf\r
+Other\Maintained\Application\Shell\EfiCompress\compress.inf\r
+Other\Maintained\Application\Shell\EfiDecompress\Decompress.inf\r
+Other\Maintained\Application\Shell\err\err.inf\r
+Other\Maintained\Application\Shell\guid\guid.inf\r
+Other\Maintained\Application\Shell\hexedit\hexedit.inf\r
+Other\Maintained\Application\Shell\IfConfig\IfConfig.inf\r
+Other\Maintained\Application\Shell\IpConfig\IpConfig.inf\r
+Other\Maintained\Application\Shell\load\load.inf\r
+Other\Maintained\Application\Shell\LoadPciRom\LoadPciRom.inf\r
+Other\Maintained\Application\Shell\ls\ls.inf\r
+Other\Maintained\Application\Shell\mem\mem.inf\r
+Other\Maintained\Application\Shell\memmap\memmap.inf\r
+Other\Maintained\Application\Shell\mkdir\mkdir.inf\r
+Other\Maintained\Application\Shell\mm\mm.inf\r
+Other\Maintained\Application\Shell\mode\mode.inf\r
+Other\Maintained\Application\Shell\mount\mount.inf\r
+Other\Maintained\Application\Shell\mv\mv.inf\r
+Other\Maintained\Application\Shell\newshell\nshell.inf\r
+Other\Maintained\Application\Shell\openinfo\openinfo.inf\r
+Other\Maintained\Application\Shell\pci\pci.inf\r
+Other\Maintained\Application\Shell\Ping\Ping.inf\r
+Other\Maintained\Application\Shell\reset\reset.inf\r
+Other\Maintained\Application\Shell\rm\rm.inf\r
+Other\Maintained\Application\Shell\sermode\sermode.inf\r
+Other\Maintained\Application\Shell\SmbiosView\Smbiosview.inf\r
+Other\Maintained\Application\Shell\stall\stall.inf\r
+Other\Maintained\Application\Shell\TelnetMgmt\TelnetMgmt.inf\r
+Other\Maintained\Application\Shell\time\time.inf\r
+Other\Maintained\Application\Shell\touch\touch.inf\r
+Other\Maintained\Application\Shell\type\type.inf\r
+Other\Maintained\Application\Shell\tzone\timezone.inf\r
+Other\Maintained\Application\Shell\unload\unload.inf\r
+Other\Maintained\Application\Shell\ver\Ver.inf\r
+Other\Maintained\Application\Shell\vol\Vol.inf\r
+\r
+[=============================================================================]\r
+\r
diff --git a/EdkCompatibilityPkg/Sample/Platform/Nt32/Build/PlatformTools.env b/EdkCompatibilityPkg/Sample/Platform/Nt32/Build/PlatformTools.env
new file mode 100644 (file)
index 0000000..ec799ab
--- /dev/null
@@ -0,0 +1,68 @@
+#/*++\r
+#   \r
+#  Copyright (c) 2004 - 2007, Intel Corporation                                                         \r
+#  All rights reserved. This program and the accompanying materials                          \r
+#  are licensed and made available under the terms and conditions of the BSD License         \r
+#  which accompanies this distribution.  The full text of the license may be found at        \r
+#  http://opensource.org/licenses/bsd-license.php                                            \r
+#                                                                                            \r
+#  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,                     \r
+#  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.             \r
+#  \r
+#  Module Name:\r
+#\r
+#    PlatformTools.env\r
+#   \r
+#  Abstract:\r
+#   \r
+#    This file is used to define platform specific environment variables.\r
+#    It gets included by every makefile.\r
+#   \r
+#--*/\r
+\r
+!INCLUDE Config.env\r
+\r
+#\r
+# Set the project name\r
+#\r
+PROJECT_NAME = Nt32\r
+\r
+#\r
+# Set the build directory\r
+#\r
+BUILD_DIR = $(EDK_SOURCE)\Sample\Platform\$(PROJECT_NAME)\$(BUILD_TARGET_DIRECTORY)\r
+\r
+!IF "$(UEFI_MODE)" == "YES"\r
+GRAPHICS_INF = Sample\Bus\WinNtThunk\Gop\Dxe\WinNtGop.inf\r
+!ELSE\r
+GRAPHICS_INF = Sample\Bus\WinNtThunk\Uga\Dxe\WinNtUga.inf\r
+!ENDIF\r
+\r
+#\r
+# Define compiler names\r
+#\r
+!IFNDEF EDK_TOOLS_PATH\r
+EFI_ASL_LOCAL           = YES\r
+!ELSE \r
+EFI_ASSEMBLER_NAME      = Masm611\r
+EFI_ASL_LOCAL           = NO\r
+!ENDIF\r
+\r
+#\r
+# These flags are specific to this platform.  If a flag is not specific to this \r
+# platform the flag should be placed in the CommonTools.env file.\r
+# Processor architecture specific and global macros can be found in \r
+# CommonTools.env, macros named xxx_ARCH_FLAGS and xxx_STD_FLAGS respectively.\r
+#\r
+C_PROJ_FLAGS          = /D UNICODE /D NEW_PEI_HOBS\r
+ASM_PROJ_FLAGS        = /Cx /Zd /Fl$*.lst /DEFI_NT_EMULATOR\r
+LINK_PROJ_FLAGS       =\r
+LIB_PROJ_FLAGS        =\r
+EBC_C_PROJ_FLAGS      =\r
+EBC_LINK_PROJ_FLAGS   =\r
+EBC_LIB_PROJ_FLAGS    =\r
+\r
+#\r
+# Include processor architecture specific and general Tiano build flags.\r
+#\r
+!INCLUDE $(EDK_SOURCE)\Sample\CommonTools.env\r
diff --git a/EdkCompatibilityPkg/Sample/Platform/Nt32/Build/build.bat b/EdkCompatibilityPkg/Sample/Platform/Nt32/Build/build.bat
new file mode 100644 (file)
index 0000000..c224c2e
--- /dev/null
@@ -0,0 +1,304 @@
+@rem #/*++\r
+@rem #  \r
+@rem #  Copyright (c) 2007, Intel Corporation                                                         \r
+@rem #  All rights reserved. This program and the accompanying materials                          \r
+@rem #  are licensed and made available under the terms and conditions of the BSD License         \r
+@rem #  which accompanies this distribution.  The full text of the license may be found at        \r
+@rem #  http://opensource.org/licenses/bsd-license.php                                            \r
+@rem #                                                                                            \r
+@rem #  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,                     \r
+@rem #  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.             \r
+@rem #  \r
+@rem #  Module Name:\r
+@rem #  \r
+@rem #    build.bat\r
+@rem #  \r
+@rem #  Abstract:\r
+@rem #    \r
+@rem #    This script provides single module build, clean and find function\r
+@rem #    based on module name.\r
+@rem #    \r
+@rem #    The auto-generated module.list file records all module names \r
+@rem #    described in the current platform.dsc.\r
+@rem #    \r
+@rem #--*/ \r
+\r
+@echo off\r
+\r
+setlocal\r
+@rem initilize local variable\r
+set FUNCTION=build\r
+set MODULE=\r
+set UPDATE=\r
+set VERBOSE=\r
+\r
+:parse\r
+if /I "%1"=="/c" (\r
+  set FUNCTION=clean\r
+  shift\r
+  goto parse\r
+)\r
+if /I "%1"=="clean" (\r
+  set FUNCTION=clean\r
+  shift\r
+  goto parse\r
+)\r
+if /I "%1"=="/r" (\r
+  set FUNCTION=rebuild\r
+  shift\r
+  goto parse\r
+)\r
+if /I "%1"=="/h" (\r
+  set FUNCTION=usage\r
+  shift\r
+  goto parse\r
+)\r
+if /I "%1"=="/?" (\r
+  set FUNCTION=usage\r
+  shift\r
+  goto parse\r
+)\r
+if /I "%1"=="/f" (\r
+  set FUNCTION=find\r
+  shift\r
+  goto parse\r
+)\r
+if /I "%1"=="/a" (\r
+  set UPDATE=TRUE\r
+  shift\r
+  goto parse\r
+)\r
+if /I "%1"=="/v" (\r
+  set VERBOSE=TRUE\r
+  shift\r
+  goto parse\r
+)\r
+if not "%1"=="" (\r
+  set MODULE=%1\r
+  shift\r
+  goto parse\r
+) else (\r
+  @rem no other paramters\r
+  if "%FUNCTION%"=="rebuild" goto build\r
+  goto %FUNCTION%\r
+)\r
+\r
+:build\r
+set StartTime=%time%\r
+@rem if no input, build all\r
+if "%MODULE%"=="" (\r
+  if "%FUNCTION%"=="rebuild" (\r
+    nmake -nologo -f Makefile clean\r
+  )\r
+  nmake -nologo -f Makefile all\r
+  goto endtime\r
+)\r
+@rem then try to build special targets: all, fast, tools.\r
+if /I "%MODULE%"=="all" (\r
+  @rem build all modules and tools.\r
+  if "%FUNCTION%"=="rebuild" (\r
+    nmake -nologo -f Makefile cleanall\r
+  )\r
+  nmake -nologo -f Makefile all\r
+  goto endtime\r
+)\r
+if /I "%MODULE%"=="fast" (\r
+  @rem build fast target to skip FV=NULL modules.\r
+  if "%FUNCTION%"=="rebuild" (\r
+    nmake -nologo -f Makefile clean\r
+  )\r
+  nmake -nologo -f Makefile fast\r
+  goto endtime\r
+)\r
+if /I "%MODULE%"=="tools" (\r
+  @rem build all tools.\r
+  if "%FUNCTION%"=="rebuild" (\r
+    nmake -nologo -f Makefile cleantools\r
+  )\r
+  nmake -nologo -f Makefile build_tools\r
+  echo.\r
+  echo All tools are built.\r
+  goto endtime\r
+)\r
+@rem build single module, update build makefiles\r
+if "%FUNCTION%"=="rebuild" (\r
+  nmake -nologo -f module.mak %MODULE%Clean 2>NUL\r
+)\r
+nmake -nologo -f Makefile flashmap > NUL 2>&1\r
+nmake -nologo -f Makefile makefiles\r
+if errorlevel 1 goto builderror\r
+@rem check whether input module name is described in current dsc file. \r
+findstr /I /C:" %MODULE% " module.list > NUL\r
+if errorlevel 1 (\r
+  echo.\r
+  echo.\r
+  findstr /I /C:"%MODULE%" module.list > NUL\r
+  if errorlevel 1 goto finderror\r
+  for /F %%A in ('findstr /I /C:"%MODULE%" module.list') do echo  %%A\r
+  echo.\r
+  echo Warning!!! Your specified module name can't be found. \r
+  echo One of the above modules may be what you want to build.\r
+  goto end\r
+)\r
+@rem build this module\r
+nmake -nologo -f module.mak %MODULE%Build \r
+echo.\r
+if "%FUNCTION%"=="rebuild" (\r
+  echo Module %MODULE% is rebuilt.\r
+) else (\r
+  echo Module %MODULE% is built.\r
+)\r
+:endtime\r
+@rem output build time.\r
+set EndTime=%time%\r
+echo.\r
+echo Start time %StartTime%\r
+echo End   time %EndTime%\r
+goto end\r
+\r
+:clean\r
+@rem if no input, default clean all build directories.\r
+if "%MODULE%"=="" (\r
+  nmake -nologo -f Makefile clean\r
+  goto end\r
+)\r
+@rem first try to clean special tasks: all, modules and tools\r
+if /I "%MODULE%"=="all" (\r
+  nmake -nologo -f Makefile cleanall\r
+  goto end\r
+)\r
+if /I "%MODULE%"=="modules" (\r
+  nmake -nologo -f Makefile cleanbuilds\r
+  goto end\r
+)\r
+if /I "%MODULE%"=="tools" (\r
+  nmake -nologo -f Makefile cleantools\r
+  goto end\r
+)\r
+@rem clean single module  \r
+@rem check whether input module name is in module.list file. \r
+if not exist module.list (\r
+  echo Module list info doesn't exist.\r
+  echo Processing dsc file to generate module list info.\r
+  nmake -nologo -f Makefile flashmap > NUL 2>&1\r
+  nmake -nologo -f Makefile makefiles > error.log 2>&1\r
+  if errorlevel 1 goto builderror\r
+)\r
+findstr /I /C:" %MODULE% " module.list > NUL\r
+if errorlevel 1 (\r
+  echo.\r
+  findstr /I /C:"%MODULE%" module.list > NUL\r
+  if errorlevel 1 goto finderror\r
+  for /F %%A in ('findstr /I /C:"%MODULE%" module.list') do echo  %%A\r
+  echo.\r
+  echo Warning!!! Your specified module name can't be found. \r
+  echo One of the above modules may be what you want to clean. \r
+  goto end\r
+)\r
+@rem clean this module \r
+nmake -nologo -f module.mak %MODULE%Clean 2>NUL\r
+echo.\r
+echo Module %MODULE% is cleaned.\r
+goto end\r
+\r
+:find\r
+@rem find match module name by subname.\r
+if "%UPDATE%"=="TRUE" (\r
+  echo Processing dsc file to update module list info.\r
+  nmake -nologo -f Makefile flashmap > NUL 2>&1\r
+  nmake -nologo -f Makefile makefiles > error.log 2>&1\r
+  if errorlevel 1 goto builderror\r
+)\r
+if not exist module.list (\r
+  echo Module list info doesn't exist.\r
+  echo Processing dsc file to generate module list info.\r
+  nmake -nologo -f Makefile flashmap > NUL 2>&1\r
+  nmake -nologo -f Makefile makefiles > error.log 2>&1\r
+  if errorlevel 1 goto builderror\r
+)\r
+if "%MODULE%"=="" (\r
+  @rem display all\r
+  echo.\r
+  if "%VERBOSE%"=="TRUE" ( \r
+    type module.list\r
+  ) else (\r
+    @rem only output module name without module.inf file name\r
+    for /F %%A in (module.list) do echo  %%A\r
+  )\r
+) else (\r
+  @rem display match module name\r
+  echo.\r
+  if "%VERBOSE%"=="TRUE" (\r
+    findstr /I /C:"%MODULE%" module.list\r
+    if errorlevel 1 goto notfind\r
+  ) else (\r
+    findstr /I /C:"%MODULE%" module.list > NUL\r
+    if errorlevel 1 goto notfind\r
+    for /F %%A in ('findstr /I /C:"%MODULE%" module.list') do echo  %%A\r
+  )\r
+)\r
+goto end\r
+\r
+:usage\r
+echo build or clean single module based on module name after tools are built.\r
+echo.\r
+echo build [/r] [/c] [/f] [/h] [modulename]\r
+echo.\r
+echo build [/r] [modulename]\r
+echo       build single module, such as build DxeMain.\r
+echo       If /r is specified, the target will be rebuit after cleaned first.\r
+echo       if no input modulename or modulename is all, then build all\r
+echo       Specail build targets: all, fast, tools.\r
+echo       These special targets may not exist in your tip main makefile.\r
+echo       build       - build all tools and modules\r
+echo       build all   - build all tools and modules\r
+echo       build fast  - build all without FV=NULL modules\r
+echo       build tools - build all tools.\r
+echo.\r
+echo build /c    [modulename]\r
+echo build clean [modulename]\r
+echo       remove the temp generated files for single module  \r
+echo       if no input modulename, then clean all\r
+echo       Specail clean targets: all, modules, tools.\r
+echo       These special targets may not exist in your tip main makefile.\r
+echo       build /c         - clean up all build directories\r
+echo       build /c all     - clean up all build directories and binary dirs.\r
+echo       build /c modules - clean up all build directories except for tools.\r
+echo       build /c tools   - clean up only tools directory.\r
+echo.\r
+echo build /f [/a] [/v] [subname]\r
+echo       find all matched modulename with the sub string of module name.\r
+echo       option /a re-processes dsc files to update module name list.\r
+echo       option /v outputs module name and module.inf file name both.\r
+echo.\r
+echo build /h\r
+echo build /?\r
+echo       display help information. \r
+echo.\r
+goto end\r
+\r
+:notfind\r
+echo Warning!!! Your specified module name can't be found.\r
+echo Try to use /f /a options to update module name list.\r
+goto end\r
+\r
+:finderror\r
+echo Warning!!! Your specified module name can't be found.\r
+echo Try to use /f to find modules that you want to build.\r
+echo Or use /h to get the helpinfo of this script.\r
+goto end\r
+\r
+:builderror\r
+if exist error.log type error.log\r
+echo.\r
+if not exist Tools\ProcessDsc.exe (\r
+  echo.\r
+  echo Error!!! Build tools may not be ready. Try to build tools first.\r
+  echo.\r
+)\r
+del module.* > NUL 2>&1\r
+goto end\r
+\r
+:end\r
+if exist error.log del error.log\r
+echo on\r
diff --git a/EdkCompatibilityPkg/Sample/Platform/X64/Build/Config.env b/EdkCompatibilityPkg/Sample/Platform/X64/Build/Config.env
new file mode 100644 (file)
index 0000000..b846afe
--- /dev/null
@@ -0,0 +1,33 @@
+#/*++\r
+#   \r
+#  Copyright (c) 2006 - 2007, Intel Corporation                                                         \r
+#  All rights reserved. This program and the accompanying materials                          \r
+#  are licensed and made available under the terms and conditions of the BSD License         \r
+#  which accompanies this distribution.  The full text of the license may be found at        \r
+#  http://opensource.org/licenses/bsd-license.php                                            \r
+#                                                                                            \r
+#  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,                     \r
+#  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.             \r
+#  \r
+#  Module Name:\r
+#\r
+#    Config.env\r
+#   \r
+#  Abstract:\r
+#   \r
+#    This file is used to define platform build configuration.\r
+#    It gets included by PlatformTools.env.\r
+#   \r
+#--*/\r
+\r
+BUILD_TARGET_DIRECTORY         = Build\r
+EFI_DEBUG                      = NO\r
+EFI_DEBUG_CLEAR_MEMORY         = NO\r
+EFI_PEI_PERFORMANCE            = NO\r
+EFI_DXE_PERFORMANCE            = NO\r
+EFI_SYMBOLIC_DEBUG             = NO\r
+EFI_GENERATE_INTERMEDIATE_FILE = NO\r
+UEFI_MODE                      = YES\r
+USE_VC8                        = NO\r
+USE_VC8_X64                    = NO\r
+USE_NEWDDK                     = YES\r
diff --git a/EdkCompatibilityPkg/Sample/Platform/X64/Build/Makefile b/EdkCompatibilityPkg/Sample/Platform/X64/Build/Makefile
new file mode 100644 (file)
index 0000000..bbb1ad3
--- /dev/null
@@ -0,0 +1,147 @@
+#/*++\r
+#\r
+#  Copyright (c) 2006 - 2007, Intel Corporation                                                         \r
+#  All rights reserved. This program and the accompanying materials                          \r
+#  are licensed and made available under the terms and conditions of the BSD License         \r
+#  which accompanies this distribution.  The full text of the license may be found at        \r
+#  http://opensource.org/licenses/bsd-license.php                                            \r
+#                                                                                            \r
+#  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,                     \r
+#  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.             \r
+#  \r
+#  Module Name:  \r
+#    Makefile\r
+#  \r
+#  Abstract:\r
+#    Makefile for this build tip\r
+#   \r
+#--*/\r
+\r
+#\r
+# Everything depends on EDK_SOURCE being set. \r
+#\r
+!IFNDEF EDK_SOURCE\r
+!ERROR EDK_SOURCE environmental variable not set \r
+!ENDIF\r
+\r
+!IFNDEF EDK_TOOLS_PATH\r
+!MESSAGE EDK_TOOLS_PATH environmental variable not set, default setting used\r
+!ENDIF\r
+\r
+#\r
+# Set the processor type\r
+#\r
+PROCESSOR = IA32\r
+\r
+#\r
+# Define a toolchain so we can pick up the basic defines from\r
+# the EFI tool setup file.\r
+#\r
+TOOLCHAIN = TOOLCHAIN_MSVC\r
+\r
+#\r
+# Include the platform-specific settings file\r
+#\r
+!INCLUDE PlatformTools.env\r
+\r
+#\r
+# Default target to create the makefiles and then build the drivers\r
+#\r
+all : build_tools makefiles builds\r
+\r
+#\r
+# Make all the build tools by calling the makefile\r
+#\r
+build_tools :\r
+  -if not exist $(EDK_TOOLS_OUTPUT) mkdir $(EDK_TOOLS_OUTPUT)\r
+  -if exist $(EDK_TOOLS_BIN)\*.* copy $(EDK_TOOLS_BIN)\*.* $(EDK_TOOLS_OUTPUT)\r
+  $(MAKE) -f $(EDK_TOOLS_SOURCE)\makefile PROCESSOR=$(PROCESSOR) BUILD_DIR=$(BUILD_DIR)\r
+  $(GUIDCHK) -b $(EDK_TOOLS_OUTPUT)\GuidDatabase.txt\r
+\r
+PROCESSOR=X64\r
+\r
+#\r
+# Run ProcessDsc on our main description files to generate the\r
+# makefiles and package files. Specify -v option for more verbose output.\r
+# Specify "-xref filename" to generate a cross-reference file of \r
+# basename-to-fileguid that can be used by VolInfo.\r
+#\r
+makefiles : \r
+  $(PROCESSDSC)                             \\r
+    -d EFI_SOURCE=$(EDK_SOURCE)             \\r
+    -d EDK_SOURCE=$(EDK_SOURCE)             \\r
+    -d PROCESSOR=$(PROCESSOR)               \\r
+    -d PROJECT_NAME=$(PROJECT_NAME)         \\r
+    -d PROJECT_FAMILY=$(PROJECT_FAMILY)     \\r
+    -d UEFI_PREFIX=$(UEFI_PREFIX)           \\r
+    -d PI_PREFIX=$(PI_PREFIX)               \\r
+    -d COMPRESS_METHOD=$(COMPRESS_METHOD)   \\r
+    -d OEMTOOLPATH=$(EDK_TOOLS_OUTPUT)      \\r
+    -g $(EDK_TOOLS_OUTPUT)\GuidDatabase.txt \\r
+    $(PROJECT_NAME).dsc\r
+\r
+#\r
+# Call all the makefiles that were generated by ProcessDsc. ProcessDsc\r
+# creates the makefile.out that calls all the component makefiles.\r
+#\r
+builds :\r
+  $(MAKE) -f makefile.out libraries\r
+  $(MAKE) -f makefile.out components\r
+\r
+#\r
+# Define a pseudo-target to start building with the libraries or with the \r
+# components.\r
+#\r
+libraries :\r
+  $(MAKE) -f makefile.out libraries \r
+\r
+components :\r
+  $(MAKE) -f makefile.out components \r
+\r
+#\r
+# Create a target to clean up all build directories\r
+#\r
+clean :\r
+  - @if exist vc??.* del vc??.* > NUL\r
+  - @if exist *.bak del *.bak > NUL\r
+  - @if exist ia32 rd /s/q ia32 > NUL\r
+  - @if exist ipf rd /s /q ipf > NUL\r
+  - @if exist ebc rd /s /q ebc > NUL\r
+  - @if exist x64 rd /s /q x64 > NUL\r
+  - @if exist fv rd /s /q fv > NUL\r
+  - @if exist Tools rd /s /q Tools > NUL\r
+  - @if exist makefile.out del makefile.out > NUL\r
+  - @if exist module.* del module.* > NUL\r
+  - @echo All targets cleaned\r
+\r
+#\r
+# Clean up all build directories except for tools.\r
+#\r
+cleanbuilds :\r
+  - @if exist *.bak del *.bak > NUL\r
+  - @if exist ia32 rd /s/q ia32 > NUL\r
+  - @if exist ipf rd /s /q ipf > NUL\r
+  - @if exist ebc rd /s /q ebc > NUL\r
+  - @if exist x64 rd /s /q x64 > NUL\r
+  - @if exist fv rd /s /q fv > NUL\r
+  - @if exist makefile.out del makefile.out > NUL\r
+  - @if exist module.* del module.* > NUL\r
+  - @echo All modules cleaned\r
+\r
+#\r
+# Clean up only the tools\r
+#\r
+cleantools :\r
+  - @if exist vc??.* del vc??.* > NUL\r
+  - @if exist Tools rd /s /q Tools > NUL\r
+  - @echo All tools cleaned\r
+\r
+#\r
+# Rebuild target, clean and build all\r
+#\r
+rebuild : clean all\r
+\r
+#\r
+# cleanall target to clean all build directories.\r
+#\r
+cleanall : clean\r
diff --git a/EdkCompatibilityPkg/Sample/Platform/X64/Build/PlatformTools.env b/EdkCompatibilityPkg/Sample/Platform/X64/Build/PlatformTools.env
new file mode 100644 (file)
index 0000000..79882f3
--- /dev/null
@@ -0,0 +1,65 @@
+#/*++\r
+#   \r
+#  Copyright (c) 2006, Intel Corporation                                                         \r
+#  All rights reserved. This program and the accompanying materials                          \r
+#  are licensed and made available under the terms and conditions of the BSD License         \r
+#  which accompanies this distribution.  The full text of the license may be found at        \r
+#  http://opensource.org/licenses/bsd-license.php                                            \r
+#                                                                                            \r
+#  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,                     \r
+#  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.             \r
+#  \r
+#  Module Name:\r
+#\r
+#    PlatformTools.env\r
+#   \r
+#  Abstract: \r
+#    This file is used to define platform specific environment variables.\r
+#    It gets included by every makefile.\r
+#   \r
+#--*/\r
+\r
+!INCLUDE Config.env\r
+\r
+#\r
+# Set the project name\r
+#\r
+PROJECT_NAME = X64\r
+\r
+#\r
+# Set the build directory\r
+#\r
+BUILD_DIR = $(EDK_SOURCE)\Sample\Platform\$(PROJECT_NAME)\$(BUILD_TARGET_DIRECTORY)\r
+\r
+#\r
+# Define compiler names\r
+#\r
+!IFNDEF EDK_TOOLS_PATH\r
+EFI_ASL_LOCAL           = YES\r
+!ELSE\r
+EFI_ASSEMBLER_NAME      = Masm611\r
+EFI_COMPILER_X64_NAME   = AMD64\r
+EFI_ASL_LOCAL           = NO\r
+!ENDIF\r
+\r
+#\r
+# These flags are specific to this platform.  If a flag is not specific to this \r
+# platform the flag should be placed in the CommonTools.env file.\r
+# Processor architecture specific and global macros can be found in \r
+# CommonTools.env, macros named xxx_ARCH_FLAGS and xxx_STD_FLAGS respectively.\r
+#\r
+C_PROJ_FLAGS          = /O1\r
+ASM_PROJ_FLAGS        =\r
+LINK_PROJ_FLAGS       = /ALIGN:32\r
+LIB_PROJ_FLAGS        =\r
+EBC_C_PROJ_FLAGS      =\r
+EBC_LINK_PROJ_FLAGS   =\r
+EBC_LIB_PROJ_FLAGS    =\r
+\r
+#\r
+# Include processor architecture specific and general Tiano build flags.\r
+#\r
+!INCLUDE $(EDK_SOURCE)\Sample\CommonTools.env\r
+\r
+\r
+\r
diff --git a/EdkCompatibilityPkg/Sample/Platform/X64/Build/X64.dsc b/EdkCompatibilityPkg/Sample/Platform/X64/Build/X64.dsc
new file mode 100644 (file)
index 0000000..4dd85ae
--- /dev/null
@@ -0,0 +1,106 @@
+#/*++\r
+#\r
+# Copyright (c) 2006 - 2007, Intel Corporation                                                         \r
+# All rights reserved. This program and the accompanying materials                          \r
+# are licensed and made available under the terms and conditions of the BSD License         \r
+# which accompanies this distribution.  The full text of the license may be found at        \r
+# http://opensource.org/licenses/bsd-license.php                                            \r
+#                                                                                           \r
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,                     \r
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.             \r
+# \r
+#  Module Name:\r
+#\r
+#    X64.dsc\r
+#\r
+#  Abstract:\r
+#\r
+#    This is the build description file containing the platform \r
+#    build definitions.\r
+#\r
+#\r
+#  Notes:\r
+#    \r
+#    The info in this file is broken down into sections. The start of a section\r
+#    is designated by a "[" in the first column. So the [=====] separater ends\r
+#    a section.\r
+#    \r
+#--*/\r
+\r
+\r
+[=============================================================================]\r
+#\r
+# This section gets processed first by the utility. Define any\r
+# macros that you may use elsewhere in this description file. This is the\r
+# mechanism by which you can pass parameters and defines to the makefiles\r
+# generated for each component. You can define it here, and then make an\r
+# assignment in the [makefile.common] section. For example, if here you\r
+# define MY_VAR = my_var_value, then you can add MY_VAR = $(MY_VAR) in\r
+# the [makefile.common] section and it becomes MY_VAR = my_var_value in\r
+# the output makefiles for each component.\r
+#\r
+[Defines]\r
+PLATFORM                  = $(PROJECT_NAME)\r
+\r
+[=============================================================================]\r
+#\r
+# Include other common build descriptions\r
+#\r
+!include "$(EDK_SOURCE)\Sample\Platform\Common.dsc"\r
+!include "$(EDK_SOURCE)\Sample\Platform\Common$(PROCESSOR).dsc"\r
+\r
+[=============================================================================]\r
+[Fv.Fv.Attributes]\r
+\r
+[Fv.Fv.options]\r
+\r
+[Build.Fv.Fv]\r
+\r
+[=============================================================================]\r
+#\r
+# These are the libraries that will be built by the master makefile\r
+#\r
+[=============================================================================]\r
+[Libraries]\r
+DEFINE EDK_PREFIX=\r
+\r
+DEFINE PROCESSOR=IA32\r
+\r
+!include "$(EDK_SOURCE)\Sample\Platform\EdkLib32.dsc"\r
+\r
+#!include "$(EDK_SOURCE)\Sample\Platform\EdkIIGlueLib32.dsc"\r
+\r
+DEFINE PROCESSOR=X64\r
+\r
+!include "$(EDK_SOURCE)\Sample\Platform\EdkLibAll.dsc"\r
+\r
+#!include "$(EDK_SOURCE)\Sample\Platform\EdkIIGlueLibAll.dsc"\r
+\r
+[=============================================================================]\r
+#\r
+# These are platform specific libraries that must be built prior to building\r
+# certain drivers that depend upon them.\r
+#\r
+[=============================================================================]\r
+[Libraries.Platform]\r
+\r
+DEFINE PROCESSOR=X64\r
+\r
+Sample\Platform\Generic\RuntimeDxe\StatusCode\Lib\BsDataHubStatusCode\BsDataHubStatusCode.inf\r
+Sample\Platform\Generic\RuntimeDxe\StatusCode\Lib\RtMemoryStatusCode\RtMemoryStatusCode.inf\r
+\r
+#Other\Maintained\Application\Shell\Library\EfiShellLib.inf\r
+\r
+[=============================================================================]\r
+#\r
+# These are the components that will be built by the master makefile\r
+#\r
+[=============================================================================]\r
+[Components]\r
+DEFINE PACKAGE=Default\r
+\r
+#Other\Maintained\Application\Shell\Shell.inf\r
+#Other\Maintained\Application\Shell\ShellFull.inf\r
+\r
+\r
+[=============================================================================]
\ No newline at end of file
diff --git a/EdkCompatibilityPkg/Sample/Platform/X64/Build/build.bat b/EdkCompatibilityPkg/Sample/Platform/X64/Build/build.bat
new file mode 100644 (file)
index 0000000..c224c2e
--- /dev/null
@@ -0,0 +1,304 @@
+@rem #/*++\r
+@rem #  \r
+@rem #  Copyright (c) 2007, Intel Corporation                                                         \r
+@rem #  All rights reserved. This program and the accompanying materials                          \r
+@rem #  are licensed and made available under the terms and conditions of the BSD License         \r
+@rem #  which accompanies this distribution.  The full text of the license may be found at        \r
+@rem #  http://opensource.org/licenses/bsd-license.php                                            \r
+@rem #                                                                                            \r
+@rem #  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,                     \r
+@rem #  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.             \r
+@rem #  \r
+@rem #  Module Name:\r
+@rem #  \r
+@rem #    build.bat\r
+@rem #  \r
+@rem #  Abstract:\r
+@rem #    \r
+@rem #    This script provides single module build, clean and find function\r
+@rem #    based on module name.\r
+@rem #    \r
+@rem #    The auto-generated module.list file records all module names \r
+@rem #    described in the current platform.dsc.\r
+@rem #    \r
+@rem #--*/ \r
+\r
+@echo off\r
+\r
+setlocal\r
+@rem initilize local variable\r
+set FUNCTION=build\r
+set MODULE=\r
+set UPDATE=\r
+set VERBOSE=\r
+\r
+:parse\r
+if /I "%1"=="/c" (\r
+  set FUNCTION=clean\r
+  shift\r
+  goto parse\r
+)\r
+if /I "%1"=="clean" (\r
+  set FUNCTION=clean\r
+  shift\r
+  goto parse\r
+)\r
+if /I "%1"=="/r" (\r
+  set FUNCTION=rebuild\r
+  shift\r
+  goto parse\r
+)\r
+if /I "%1"=="/h" (\r
+  set FUNCTION=usage\r
+  shift\r
+  goto parse\r
+)\r
+if /I "%1"=="/?" (\r
+  set FUNCTION=usage\r
+  shift\r
+  goto parse\r
+)\r
+if /I "%1"=="/f" (\r
+  set FUNCTION=find\r
+  shift\r
+  goto parse\r
+)\r
+if /I "%1"=="/a" (\r
+  set UPDATE=TRUE\r
+  shift\r
+  goto parse\r
+)\r
+if /I "%1"=="/v" (\r
+  set VERBOSE=TRUE\r
+  shift\r
+  goto parse\r
+)\r
+if not "%1"=="" (\r
+  set MODULE=%1\r
+  shift\r
+  goto parse\r
+) else (\r
+  @rem no other paramters\r
+  if "%FUNCTION%"=="rebuild" goto build\r
+  goto %FUNCTION%\r
+)\r
+\r
+:build\r
+set StartTime=%time%\r
+@rem if no input, build all\r
+if "%MODULE%"=="" (\r
+  if "%FUNCTION%"=="rebuild" (\r
+    nmake -nologo -f Makefile clean\r
+  )\r
+  nmake -nologo -f Makefile all\r
+  goto endtime\r
+)\r
+@rem then try to build special targets: all, fast, tools.\r
+if /I "%MODULE%"=="all" (\r
+  @rem build all modules and tools.\r
+  if "%FUNCTION%"=="rebuild" (\r
+    nmake -nologo -f Makefile cleanall\r
+  )\r
+  nmake -nologo -f Makefile all\r
+  goto endtime\r
+)\r
+if /I "%MODULE%"=="fast" (\r
+  @rem build fast target to skip FV=NULL modules.\r
+  if "%FUNCTION%"=="rebuild" (\r
+    nmake -nologo -f Makefile clean\r
+  )\r
+  nmake -nologo -f Makefile fast\r
+  goto endtime\r
+)\r
+if /I "%MODULE%"=="tools" (\r
+  @rem build all tools.\r
+  if "%FUNCTION%"=="rebuild" (\r
+    nmake -nologo -f Makefile cleantools\r
+  )\r
+  nmake -nologo -f Makefile build_tools\r
+  echo.\r
+  echo All tools are built.\r
+  goto endtime\r
+)\r
+@rem build single module, update build makefiles\r
+if "%FUNCTION%"=="rebuild" (\r
+  nmake -nologo -f module.mak %MODULE%Clean 2>NUL\r
+)\r
+nmake -nologo -f Makefile flashmap > NUL 2>&1\r
+nmake -nologo -f Makefile makefiles\r
+if errorlevel 1 goto builderror\r
+@rem check whether input module name is described in current dsc file. \r
+findstr /I /C:" %MODULE% " module.list > NUL\r
+if errorlevel 1 (\r
+  echo.\r
+  echo.\r
+  findstr /I /C:"%MODULE%" module.list > NUL\r
+  if errorlevel 1 goto finderror\r
+  for /F %%A in ('findstr /I /C:"%MODULE%" module.list') do echo  %%A\r
+  echo.\r
+  echo Warning!!! Your specified module name can't be found. \r
+  echo One of the above modules may be what you want to build.\r
+  goto end\r
+)\r
+@rem build this module\r
+nmake -nologo -f module.mak %MODULE%Build \r
+echo.\r
+if "%FUNCTION%"=="rebuild" (\r
+  echo Module %MODULE% is rebuilt.\r
+) else (\r
+  echo Module %MODULE% is built.\r
+)\r
+:endtime\r
+@rem output build time.\r
+set EndTime=%time%\r
+echo.\r
+echo Start time %StartTime%\r
+echo End   time %EndTime%\r
+goto end\r
+\r
+:clean\r
+@rem if no input, default clean all build directories.\r
+if "%MODULE%"=="" (\r
+  nmake -nologo -f Makefile clean\r
+  goto end\r
+)\r
+@rem first try to clean special tasks: all, modules and tools\r
+if /I "%MODULE%"=="all" (\r
+  nmake -nologo -f Makefile cleanall\r
+  goto end\r
+)\r
+if /I "%MODULE%"=="modules" (\r
+  nmake -nologo -f Makefile cleanbuilds\r
+  goto end\r
+)\r
+if /I "%MODULE%"=="tools" (\r
+  nmake -nologo -f Makefile cleantools\r
+  goto end\r
+)\r
+@rem clean single module  \r
+@rem check whether input module name is in module.list file. \r
+if not exist module.list (\r
+  echo Module list info doesn't exist.\r
+  echo Processing dsc file to generate module list info.\r
+  nmake -nologo -f Makefile flashmap > NUL 2>&1\r
+  nmake -nologo -f Makefile makefiles > error.log 2>&1\r
+  if errorlevel 1 goto builderror\r
+)\r
+findstr /I /C:" %MODULE% " module.list > NUL\r
+if errorlevel 1 (\r
+  echo.\r
+  findstr /I /C:"%MODULE%" module.list > NUL\r
+  if errorlevel 1 goto finderror\r
+  for /F %%A in ('findstr /I /C:"%MODULE%" module.list') do echo  %%A\r
+  echo.\r
+  echo Warning!!! Your specified module name can't be found. \r
+  echo One of the above modules may be what you want to clean. \r
+  goto end\r
+)\r
+@rem clean this module \r
+nmake -nologo -f module.mak %MODULE%Clean 2>NUL\r
+echo.\r
+echo Module %MODULE% is cleaned.\r
+goto end\r
+\r
+:find\r
+@rem find match module name by subname.\r
+if "%UPDATE%"=="TRUE" (\r
+  echo Processing dsc file to update module list info.\r
+  nmake -nologo -f Makefile flashmap > NUL 2>&1\r
+  nmake -nologo -f Makefile makefiles > error.log 2>&1\r
+  if errorlevel 1 goto builderror\r
+)\r
+if not exist module.list (\r
+  echo Module list info doesn't exist.\r
+  echo Processing dsc file to generate module list info.\r
+  nmake -nologo -f Makefile flashmap > NUL 2>&1\r
+  nmake -nologo -f Makefile makefiles > error.log 2>&1\r
+  if errorlevel 1 goto builderror\r
+)\r
+if "%MODULE%"=="" (\r
+  @rem display all\r
+  echo.\r
+  if "%VERBOSE%"=="TRUE" ( \r
+    type module.list\r
+  ) else (\r
+    @rem only output module name without module.inf file name\r
+    for /F %%A in (module.list) do echo  %%A\r
+  )\r
+) else (\r
+  @rem display match module name\r
+  echo.\r
+  if "%VERBOSE%"=="TRUE" (\r
+    findstr /I /C:"%MODULE%" module.list\r
+    if errorlevel 1 goto notfind\r
+  ) else (\r
+    findstr /I /C:"%MODULE%" module.list > NUL\r
+    if errorlevel 1 goto notfind\r
+    for /F %%A in ('findstr /I /C:"%MODULE%" module.list') do echo  %%A\r
+  )\r
+)\r
+goto end\r
+\r
+:usage\r
+echo build or clean single module based on module name after tools are built.\r
+echo.\r
+echo build [/r] [/c] [/f] [/h] [modulename]\r
+echo.\r
+echo build [/r] [modulename]\r
+echo       build single module, such as build DxeMain.\r
+echo       If /r is specified, the target will be rebuit after cleaned first.\r
+echo       if no input modulename or modulename is all, then build all\r
+echo       Specail build targets: all, fast, tools.\r
+echo       These special targets may not exist in your tip main makefile.\r
+echo       build       - build all tools and modules\r
+echo       build all   - build all tools and modules\r
+echo       build fast  - build all without FV=NULL modules\r
+echo       build tools - build all tools.\r
+echo.\r
+echo build /c    [modulename]\r
+echo build clean [modulename]\r
+echo       remove the temp generated files for single module  \r
+echo       if no input modulename, then clean all\r
+echo       Specail clean targets: all, modules, tools.\r
+echo       These special targets may not exist in your tip main makefile.\r
+echo       build /c         - clean up all build directories\r
+echo       build /c all     - clean up all build directories and binary dirs.\r
+echo       build /c modules - clean up all build directories except for tools.\r
+echo       build /c tools   - clean up only tools directory.\r
+echo.\r
+echo build /f [/a] [/v] [subname]\r
+echo       find all matched modulename with the sub string of module name.\r
+echo       option /a re-processes dsc files to update module name list.\r
+echo       option /v outputs module name and module.inf file name both.\r
+echo.\r
+echo build /h\r
+echo build /?\r
+echo       display help information. \r
+echo.\r
+goto end\r
+\r
+:notfind\r
+echo Warning!!! Your specified module name can't be found.\r
+echo Try to use /f /a options to update module name list.\r
+goto end\r
+\r
+:finderror\r
+echo Warning!!! Your specified module name can't be found.\r
+echo Try to use /f to find modules that you want to build.\r
+echo Or use /h to get the helpinfo of this script.\r
+goto end\r
+\r
+:builderror\r
+if exist error.log type error.log\r
+echo.\r
+if not exist Tools\ProcessDsc.exe (\r
+  echo.\r
+  echo Error!!! Build tools may not be ready. Try to build tools first.\r
+  echo.\r
+)\r
+del module.* > NUL 2>&1\r
+goto end\r
+\r
+:end\r
+if exist error.log del error.log\r
+echo on\r