mirror of
https://git.yoctoproject.org/meta-arm
synced 2026-04-20 11:29:54 +00:00
arm/edk2-firmware: rationalise $S
Currently edk2-firmware sets S to WORKDIR/git/ and unpacks edk2 into WORKDIR/git/edk2. This isn't idiomatic and breaks tooling such as devtool which expects a git fetcher to unpack a git repository to $S. Move the edk2 unpack to $S directly, and update the recipe where required. Change-Id: Ib9571032c14a01864860e2eb5a04ed73dd382710 Signed-off-by: Ross Burton <ross.burton@arm.com> Signed-off-by: Jon Mason <jon.mason@arm.com>
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
SRC_URI = "\
|
||||
git://git.linaro.org/landing-teams/working/arm/edk2.git;name=edk2;destsuffix=git/edk2;nobranch=1 \
|
||||
git://git.linaro.org/landing-teams/working/arm/edk2-platforms.git;name=edk2-platforms;destsuffix=git/edk2/edk2-platforms;nobranch=1 \
|
||||
git://git.linaro.org/landing-teams/working/arm/edk2.git;name=edk2;destsuffix=edk2;nobranch=1 \
|
||||
git://git.linaro.org/landing-teams/working/arm/edk2-platforms.git;name=edk2-platforms;destsuffix=edk2/edk2-platforms;nobranch=1 \
|
||||
"
|
||||
|
||||
# TAGS and commit ID as per N1SDP-2020.03.26 release
|
||||
|
||||
@@ -7,13 +7,13 @@ LICENSE = "BSD-2-Clause-Patent"
|
||||
PROVIDES += "virtual/uefi-firmware"
|
||||
|
||||
# EDK2
|
||||
LIC_FILES_CHKSUM = "file://edk2/License.txt;md5=2b415520383f7964e96700ae12b4570a"
|
||||
LIC_FILES_CHKSUM = "file://License.txt;md5=2b415520383f7964e96700ae12b4570a"
|
||||
# EDK2 Platforms
|
||||
LIC_FILES_CHKSUM += "file://edk2/edk2-platforms/License.txt;md5=2b415520383f7964e96700ae12b4570a"
|
||||
LIC_FILES_CHKSUM += "file://edk2-platforms/License.txt;md5=2b415520383f7964e96700ae12b4570a"
|
||||
|
||||
SRC_URI ?= "\
|
||||
gitsm://github.com/tianocore/edk2.git;name=edk2;destsuffix=${S}/edk2;nobranch=1 \
|
||||
git://github.com/tianocore/edk2-platforms.git;name=edk2-platforms;destsuffix=${S}/edk2/edk2-platforms;nobranch=1 \
|
||||
SRC_URI = "\
|
||||
gitsm://github.com/tianocore/edk2.git;name=edk2;destsuffix=edk2;nobranch=1 \
|
||||
git://github.com/tianocore/edk2-platforms.git;name=edk2-platforms;destsuffix=edk2/edk2-platforms;nobranch=1 \
|
||||
"
|
||||
SRCREV_edk2 ?= "6ff7c838d09224dd4e4c9b5b93152d8db1b19740"
|
||||
SRCREV_edk2-platforms ?= "ed4cc8059ec551032f0d8b8c172e9ec19214a638"
|
||||
@@ -31,8 +31,9 @@ DEPENDS += "util-linux-native iasl-native"
|
||||
|
||||
inherit deploy
|
||||
|
||||
S = "${WORKDIR}/edk2"
|
||||
B = "${WORKDIR}/build"
|
||||
S = "${WORKDIR}/git"
|
||||
do_compile[cleandirs] += "${B}"
|
||||
|
||||
PACKAGE_ARCH = "${MACHINE_ARCH}"
|
||||
COMPATIBLE_MACHINE ?= "invalid"
|
||||
@@ -44,11 +45,11 @@ do_configure[noexec] = "1"
|
||||
|
||||
# Set variables as per envsetup
|
||||
export GCC5_AARCH64_PREFIX = "${STAGING_BINDIR_TOOLCHAIN}/${TARGET_PREFIX}"
|
||||
export PACKAGES_PATH = "${S}/edk2:${S}/edk2/edk2-platforms"
|
||||
export WORKSPACE = "${S}/edk2"
|
||||
export EDK_TOOLS_PATH = "${WORKSPACE}/BaseTools"
|
||||
export PACKAGES_PATH = "${S}:${S}/edk2-platforms"
|
||||
export WORKSPACE = "${B}"
|
||||
export EDK_TOOLS_PATH = "${S}/BaseTools"
|
||||
export PYTHON_COMMAND = "python3"
|
||||
export CONF_PATH = "${WORKSPACE}/Conf"
|
||||
export CONF_PATH = "${S}/Conf"
|
||||
|
||||
export BTOOLS_PATH = "${EDK_TOOLS_PATH}/BinWrappers/PosixLike"
|
||||
|
||||
@@ -59,24 +60,24 @@ do_compile() {
|
||||
sed -i -e 's: -luuid: -luuid ${BUILD_LDFLAGS}:g' ${EDK_TOOLS_PATH}/Source/C/*/GNUmakefile
|
||||
|
||||
# Copy the templates as we don't run envsetup
|
||||
cp ${EDK_TOOLS_PATH}/Conf/build_rule.template ${WORKSPACE}/Conf/build_rule.txt
|
||||
cp ${EDK_TOOLS_PATH}/Conf/tools_def.template ${WORKSPACE}/Conf/tools_def.txt
|
||||
cp ${EDK_TOOLS_PATH}/Conf/target.template ${WORKSPACE}/Conf/target.txt
|
||||
cp ${EDK_TOOLS_PATH}/Conf/build_rule.template ${S}/Conf/build_rule.txt
|
||||
cp ${EDK_TOOLS_PATH}/Conf/tools_def.template ${S}/Conf/tools_def.txt
|
||||
cp ${EDK_TOOLS_PATH}/Conf/target.template ${S}/Conf/target.txt
|
||||
|
||||
# Build basetools
|
||||
oe_runmake -C ${S}/edk2/BaseTools
|
||||
oe_runmake -C ${S}/BaseTools
|
||||
|
||||
PATH="${WORKSPACE}:${BTOOLS_PATH}:$PATH" \
|
||||
"${S}/edk2/BaseTools/BinWrappers/PosixLike/build" \
|
||||
"${S}/BaseTools/BinWrappers/PosixLike/build" \
|
||||
-a "${EDK2_ARCH}" \
|
||||
-b ${EDK2_BUILD_MODE} \
|
||||
-t ${GCC_VER} \
|
||||
-p "${S}/edk2/edk2-platforms/Platform/ARM/${EDK2_PLATFORM_DSC}"
|
||||
-p "${S}/edk2-platforms/Platform/ARM/${EDK2_PLATFORM_DSC}"
|
||||
}
|
||||
|
||||
do_install() {
|
||||
install -d ${D}/firmware
|
||||
install "${S}/edk2/Build/${EDK2_PLATFORM}/${EDK2_BUILD_MODE}_${GCC_VER}/FV/${EDK2_BIN_NAME}" "${D}/firmware/uefi.bin"
|
||||
install ${B}/Build/${EDK2_PLATFORM}/${EDK2_BUILD_MODE}_${GCC_VER}/FV/${EDK2_BIN_NAME} ${D}/firmware/uefi.bin
|
||||
}
|
||||
|
||||
FILES_${PN} = "/firmware"
|
||||
|
||||
Reference in New Issue
Block a user