slimbootloader/PayloadPkg/PayloadPkg.dsc

121 lines
5.7 KiB
Plaintext
Raw Permalink Normal View History

Use LF line endings in the repository Convert the line endings stored for all text files in the repository to LF. The majority previously used DOS-style CRLF line endings. Add a .gitattributes file to enforce this and treat certain extensions as never being text files. Update PatchCheck.py to insist on LF line endings rather than CRLF. However, its other checks fail on this commit due to lots of pre-existing complaints that it only notices because the line endings have changed. Silicon/QemuSocPkg/FspBin/Patches/0001-Build-QEMU-FSP-2.0-binaries.patch needs to be treated as binary since it contains a mixture of line endings. This change has implications depending on the client platform you are using the repository from: * Windows The usual configuration for Git on Windows means that text files will be checked out to the work tree with DOS-style CRLF line endings. If that's not the case then you can configure Git to do so for the entire machine with: git config --global core.autocrlf true or for just the repository with: git config core.autocrlf true Line endings will be normalised to LF when they are committed to the repository. If you commit a text file with only LF line endings then it will be converted to CRLF line endings in your work tree. * Linux, MacOS and other Unices The usual configuration for Git on such platforms is to check files out of the repository with LF line endings. This is probably the right thing for you. In the unlikely even that you are using Git on Unix but editing or compiling on Windows for some reason then you may need to tweak your configuration to force the use of CRLF line endings as described above. * General For more information see https://docs.github.com/en/get-started/getting-started-with-git/configuring-git-to-handle-line-endings . Fixes: https://github.com/slimbootloader/slimbootloader/issues/1400 Signed-off-by: Mike Crowe <mac@mcrowe.com>
2021-11-10 19:36:23 +08:00
## @file
# Provides driver and definitions to build payload module.
#
# Copyright (c) 2020, Intel Corporation. All rights reserved.<BR>
# SPDX-License-Identifier: BSD-2-Clause-Patent
#
##
################################################################################
#
# Defines Section - statements that will be processed to create a Makefile.
#
################################################################################
[Defines]
PLATFORM_NAME = PayloadPkg
PLATFORM_GUID = 5BCB969A-9151-45E0-BE14-048954BD2E8E
PLATFORM_VERSION = 0.1
DSC_SPECIFICATION = 0x00010005
OUTPUT_DIRECTORY = Build/PayloadPkg
SUPPORTED_ARCHITECTURES = IA32|X64
BUILD_TARGETS = DEBUG|RELEASE|NOOPT
SKUID_IDENTIFIER = DEFAULT
################################################################################
#
# SKU Identification section - list of all SKU IDs supported by this Platform.
#
################################################################################
[SkuIds]
0|DEFAULT # The entry: 0|DEFAULT is reserved and always required.
################################################################################
#
# Library Class section - list of all Library Classes needed by this Platform.
#
################################################################################
[LibraryClasses]
BaseLib | MdePkg/Library/BaseLib/BaseLib.inf
BaseMemoryLib | MdePkg/Library/BaseMemoryLibSse2/BaseMemoryLibSse2.inf
IoLib | MdePkg/Library/BaseIoLibIntrinsic/BaseIoLibIntrinsic.inf
PrintLib | MdePkg/Library/BasePrintLib/BasePrintLib.inf
SynchronizationLib|MdePkg/Library/BaseSynchronizationLib/BaseSynchronizationLib.inf
HobLib | BootloaderCommonPkg/Library/HobLib/HobLib.inf
DebugLogBufferLib | BootloaderCommonPkg/Library/DebugLogBufferLib/DebugLogBufferLib.inf
SerialPortLib | BootloaderCommonPkg/Library/SerialPortLib/SerialPortLib.inf
DebugLib | BootloaderCommonPkg/Library/BootloaderDebugLib/BootloaderDebugLib.inf
PcdLib | BootloaderCommonPkg/Library/PcdLib/PcdLib.inf
RegisterFilterLib|MdePkg/Library/RegisterFilterLibNull/RegisterFilterLibNull.inf
Use LF line endings in the repository Convert the line endings stored for all text files in the repository to LF. The majority previously used DOS-style CRLF line endings. Add a .gitattributes file to enforce this and treat certain extensions as never being text files. Update PatchCheck.py to insist on LF line endings rather than CRLF. However, its other checks fail on this commit due to lots of pre-existing complaints that it only notices because the line endings have changed. Silicon/QemuSocPkg/FspBin/Patches/0001-Build-QEMU-FSP-2.0-binaries.patch needs to be treated as binary since it contains a mixture of line endings. This change has implications depending on the client platform you are using the repository from: * Windows The usual configuration for Git on Windows means that text files will be checked out to the work tree with DOS-style CRLF line endings. If that's not the case then you can configure Git to do so for the entire machine with: git config --global core.autocrlf true or for just the repository with: git config core.autocrlf true Line endings will be normalised to LF when they are committed to the repository. If you commit a text file with only LF line endings then it will be converted to CRLF line endings in your work tree. * Linux, MacOS and other Unices The usual configuration for Git on such platforms is to check files out of the repository with LF line endings. This is probably the right thing for you. In the unlikely even that you are using Git on Unix but editing or compiling on Windows for some reason then you may need to tweak your configuration to force the use of CRLF line endings as described above. * General For more information see https://docs.github.com/en/get-started/getting-started-with-git/configuring-git-to-handle-line-endings . Fixes: https://github.com/slimbootloader/slimbootloader/issues/1400 Signed-off-by: Mike Crowe <mac@mcrowe.com>
2021-11-10 19:36:23 +08:00
ConsoleInLib | BootloaderCommonPkg/Library/ConsoleInLib/ConsoleInLib.inf
ConsoleOutLib | BootloaderCommonPkg/Library/ConsoleOutLib/ConsoleOutLib.inf
GraphicsLib | BootloaderCommonPkg/Library/GraphicsLib/GraphicsLib.inf
MemoryAllocationLib | BootloaderCommonPkg/Library/FullMemoryAllocationLib/FullMemoryAllocationLib.inf
ModuleEntryLib | BootloaderCommonPkg/Library/ModuleEntryLib/ModuleEntryLib.inf
TimeStampLib | BootloaderCommonPkg/Library/TimeStampLib/TimeStampLib.inf
LoaderPerformanceLib | BootloaderCommonPkg/Library/LoaderPerformanceLib/LoaderPerformanceLib.inf
BootloaderCommonLib | BootloaderCommonPkg/Library/BootloaderCommonLib/BootloaderCommonLib.inf
UsbKbLib | BootloaderCommonPkg/Library/UsbKbLib/UsbKbLibNull.inf
PayloadSupportLib | PayloadPkg/Library/PayloadSupportLib/PayloadSupportLib.inf
DebugPrintErrorLevelLib | PayloadPkg/Library/DebugPrintErrorLevelLib/DebugPrintErrorLevelLib.inf
BootloaderLib | PayloadPkg/Library/PayloadLib/PayloadLib.inf
PayloadEntryLib | PayloadPkg/Library/PayloadEntryLib/PayloadEntryLib.inf
PlatformHookLib | PayloadPkg/Library/PlatformHookLib/PlatformHookLib.inf
PagingLib|BootloaderCommonPkg/Library/PagingLib/PagingLib.inf
ThunkLib|BootloaderCommonPkg/Library/ThunkLib/ThunkLib.inf
LitePeCoffLib|BootloaderCommonPkg/Library/LitePeCoffLib/LitePeCoffLib.inf
DebugAgentLib|BootloaderCommonPkg/Library/DebugAgentLib/DebugAgentLibNull.inf
TimerLib|BootloaderCommonPkg/Library/AcpiTimerLib/AcpiTimerLib.inf
DebugPortLib|BootloaderCommonPkg/Library/DebugPortLib/DebugPortLibNull.inf
[PcdsPatchableInModule]
gEfiMdePkgTokenSpaceGuid.PcdDebugPrintErrorLevel | 0x8000004F
# Following will be initialized at runtime
gPayloadTokenSpaceGuid.PcdGlobalDataAddress | 0
gPayloadTokenSpaceGuid.PcdPayloadHobList | 0
gEfiMdePkgTokenSpaceGuid.PcdPciExpressBaseAddress | 0
gPlatformCommonLibTokenSpaceGuid.PcdAcpiPmTimerBase | 0
gPlatformCommonLibTokenSpaceGuid.PcdSerialUseMmio | 0
gPlatformCommonLibTokenSpaceGuid.PcdSerialRegisterBase | 0
gPlatformCommonLibTokenSpaceGuid.PcdSerialBaudRate | 0
gPlatformCommonLibTokenSpaceGuid.PcdSerialRegisterStride | 0
gPlatformCommonLibTokenSpaceGuid.PcdSerialClockRate | 0
[PcdsFixedAtBuild]
!if $(TARGET) == RELEASE
# Use this PCD to control the debug message that goes into binary image
gEfiMdePkgTokenSpaceGuid.PcdFixedDebugPrintErrorLevel | 0x80080003
gEfiMdePkgTokenSpaceGuid.PcdDebugPropertyMask | 0x23
!else
gEfiMdePkgTokenSpaceGuid.PcdDebugPropertyMask | 0x27
!endif
gPayloadTokenSpaceGuid.PcdPayloadHeapSize | 0x02000000
gPayloadTokenSpaceGuid.PcdPayloadStackSize | 0x00010000
[Components]
PayloadPkg/HelloWorld/HelloWorld.inf
[BuildOptions.Common.EDKII]
# Enable link-time optimization when building with GCC49
*_GCC49_IA32_CC_FLAGS = -flto
*_GCC49_IA32_DLINK_FLAGS = -flto
*_GCC5_IA32_CC_FLAGS = -fno-pic
*_GCC5_IA32_DLINK_FLAGS = -no-pie
*_GCC5_IA32_ASLCC_FLAGS = -fno-pic
*_GCC5_IA32_ASLDLINK_FLAGS = -no-pie
# Force synchronous PDB writes for parallel builds
*_VS2015x86_IA32_CC_FLAGS = /FS
*_XCODE5_IA32_CC_FLAGS = -flto
*_*_*_CC_FLAGS = -DDISABLE_NEW_DEPRECATED_INTERFACES
!if $(TARGET) == NOOPT
# GCC: -O0 results in too big size. Override it to -O1 with lto
*_GCC49_*_CC_FLAGS = -O1
*_GCC49_*_DLINK_FLAGS = -O1
*_GCC5_*_CC_FLAGS = -flto -O1
*_GCC5_*_DLINK_FLAGS = -flto -O1
# VS: Use default /Od for now
!endif