mirror of
https://git.yoctoproject.org/meta-arm
synced 2026-07-16 15:57:19 +00:00
arm/scp-firmware: merge bb/inc
There's no other recipe that uses scp-firmware.inc, so merge it into the recipe for clarity. Change-Id: Ife1874b54c8b2be2704e1d0f5a7013ff89b8ca6e Signed-off-by: Ross Burton <ross.burton@arm.com> Signed-off-by: Jon Mason <jon.mason@arm.com>
This commit is contained in:
@@ -1,73 +0,0 @@
|
|||||||
SUMMARY = "SCP and MCP Firmware"
|
|
||||||
|
|
||||||
PROVIDES += "virtual/control-processor-firmware"
|
|
||||||
|
|
||||||
SCP_BUILD_RELEASE ?= "1"
|
|
||||||
SCP_COMPILE_VERBOSE ?= "0"
|
|
||||||
SCP_PLATFORM ?= "invalid"
|
|
||||||
SCP_COMPILER ?= "arm-none-eabi"
|
|
||||||
SCP_LOG_LEVEL ?= "WARN"
|
|
||||||
|
|
||||||
DEPENDS += "virtual/arm-none-eabi-gcc-native"
|
|
||||||
|
|
||||||
SCP_BUILD_STR = "${@bb.utils.contains('SCP_BUILD_RELEASE', '1', 'release', 'debug', d)}"
|
|
||||||
SCP_COMP_STR = "${@bb.utils.contains('SCP_COMPILE_VERBOSE', '0', '', 'V=1', d)}"
|
|
||||||
|
|
||||||
inherit python3native
|
|
||||||
inherit deploy
|
|
||||||
|
|
||||||
B = "${WORKDIR}/build"
|
|
||||||
S = "${WORKDIR}/src"
|
|
||||||
|
|
||||||
# Allow platform specific copying of only scp or both scp & mcp, default to both
|
|
||||||
FW_TARGETS ?= "scp mcp"
|
|
||||||
|
|
||||||
COMPATIBLE_MACHINE ?= "invalid"
|
|
||||||
|
|
||||||
LDFLAGS[unexport] = "1"
|
|
||||||
|
|
||||||
# The gcc-arm-none-eabi version does not support -fmacro-prefix-max
|
|
||||||
DEBUG_PREFIX_MAP_pn-scp = "\
|
|
||||||
-fdebug-prefix-map=${WORKDIR}=/usr/src/debug/${PN}/${EXTENDPE}${PV}-${PR} \
|
|
||||||
-fdebug-prefix-map=${STAGING_DIR_HOST}= \
|
|
||||||
-fdebug-prefix-map=${STAGING_DIR_NATIVE}= \
|
|
||||||
"
|
|
||||||
|
|
||||||
# No configure
|
|
||||||
do_configure[noexec] = "1"
|
|
||||||
|
|
||||||
EXTRA_OEMAKE = "${SCP_COMP_STR} \
|
|
||||||
BUILD_PATH='${B}' \
|
|
||||||
PRODUCT='${SCP_PLATFORM}' \
|
|
||||||
MODE='${SCP_BUILD_STR}' \
|
|
||||||
LOG_LEVEL='${SCP_LOG_LEVEL}' \
|
|
||||||
CC='${SCP_COMPILER}-gcc' \
|
|
||||||
AR='${SCP_COMPILER}-ar' \
|
|
||||||
SIZE='${SCP_COMPILER}-size' \
|
|
||||||
OBJCOPY='${SCP_COMPILER}-objcopy' \
|
|
||||||
"
|
|
||||||
|
|
||||||
do_compile() {
|
|
||||||
oe_runmake -C "${S}" ${EXTRA_OEMAKE}
|
|
||||||
}
|
|
||||||
do_compile[cleandirs] += "${B}"
|
|
||||||
|
|
||||||
do_install() {
|
|
||||||
install -d ${D}/firmware
|
|
||||||
for FW in ${FW_TARGETS}; do
|
|
||||||
for TYPE in ramfw romfw; do
|
|
||||||
install -D "${B}/product/${SCP_PLATFORM}/${FW}_${TYPE}/release/bin/${FW}_${TYPE}.bin" "${D}/firmware/"
|
|
||||||
done
|
|
||||||
done
|
|
||||||
}
|
|
||||||
|
|
||||||
FILES_${PN} = "/firmware"
|
|
||||||
SYSROOT_DIRS += "/firmware"
|
|
||||||
# Skip QA check for relocations in .text of elf binaries
|
|
||||||
INSANE_SKIP_${PN} = "textrel"
|
|
||||||
|
|
||||||
do_deploy() {
|
|
||||||
# Copy the images to deploy directory
|
|
||||||
cp -rf ${D}/firmware/* ${DEPLOYDIR}/
|
|
||||||
}
|
|
||||||
addtask deploy after do_install
|
|
||||||
@@ -1,3 +1,4 @@
|
|||||||
|
SUMMARY = "SCP and MCP Firmware"
|
||||||
DESCRIPTION = "Firmware for SCP and MCP software reference implementation"
|
DESCRIPTION = "Firmware for SCP and MCP software reference implementation"
|
||||||
HOMEPAGE = "https://github.com/ARM-software/SCP-firmware"
|
HOMEPAGE = "https://github.com/ARM-software/SCP-firmware"
|
||||||
|
|
||||||
@@ -17,4 +18,74 @@ SRCREV_scp = "fd7c83561a7d76c7681d5d017fb23aa3664c028c"
|
|||||||
SRCREV_cmsis = "refs/tags/5.2.0"
|
SRCREV_cmsis = "refs/tags/5.2.0"
|
||||||
SRCREV_FORMAT = "scp_cmsis"
|
SRCREV_FORMAT = "scp_cmsis"
|
||||||
|
|
||||||
require scp-firmware.inc
|
PROVIDES += "virtual/control-processor-firmware"
|
||||||
|
|
||||||
|
SCP_BUILD_RELEASE ?= "1"
|
||||||
|
SCP_COMPILE_VERBOSE ?= "0"
|
||||||
|
SCP_PLATFORM ?= "invalid"
|
||||||
|
SCP_COMPILER ?= "arm-none-eabi"
|
||||||
|
SCP_LOG_LEVEL ?= "WARN"
|
||||||
|
|
||||||
|
DEPENDS += "virtual/arm-none-eabi-gcc-native"
|
||||||
|
|
||||||
|
SCP_BUILD_STR = "${@bb.utils.contains('SCP_BUILD_RELEASE', '1', 'release', 'debug', d)}"
|
||||||
|
SCP_COMP_STR = "${@bb.utils.contains('SCP_COMPILE_VERBOSE', '0', '', 'V=1', d)}"
|
||||||
|
|
||||||
|
inherit python3native
|
||||||
|
inherit deploy
|
||||||
|
|
||||||
|
B = "${WORKDIR}/build"
|
||||||
|
S = "${WORKDIR}/src"
|
||||||
|
|
||||||
|
# Allow platform specific copying of only scp or both scp & mcp, default to both
|
||||||
|
FW_TARGETS ?= "scp mcp"
|
||||||
|
|
||||||
|
COMPATIBLE_MACHINE ?= "invalid"
|
||||||
|
|
||||||
|
LDFLAGS[unexport] = "1"
|
||||||
|
|
||||||
|
# The gcc-arm-none-eabi version does not support -fmacro-prefix-max
|
||||||
|
DEBUG_PREFIX_MAP_pn-scp = "\
|
||||||
|
-fdebug-prefix-map=${WORKDIR}=/usr/src/debug/${PN}/${EXTENDPE}${PV}-${PR} \
|
||||||
|
-fdebug-prefix-map=${STAGING_DIR_HOST}= \
|
||||||
|
-fdebug-prefix-map=${STAGING_DIR_NATIVE}= \
|
||||||
|
"
|
||||||
|
|
||||||
|
# No configure
|
||||||
|
do_configure[noexec] = "1"
|
||||||
|
|
||||||
|
EXTRA_OEMAKE = "${SCP_COMP_STR} \
|
||||||
|
BUILD_PATH='${B}' \
|
||||||
|
PRODUCT='${SCP_PLATFORM}' \
|
||||||
|
MODE='${SCP_BUILD_STR}' \
|
||||||
|
LOG_LEVEL='${SCP_LOG_LEVEL}' \
|
||||||
|
CC='${SCP_COMPILER}-gcc' \
|
||||||
|
AR='${SCP_COMPILER}-ar' \
|
||||||
|
SIZE='${SCP_COMPILER}-size' \
|
||||||
|
OBJCOPY='${SCP_COMPILER}-objcopy' \
|
||||||
|
"
|
||||||
|
|
||||||
|
do_compile() {
|
||||||
|
oe_runmake -C "${S}" ${EXTRA_OEMAKE}
|
||||||
|
}
|
||||||
|
do_compile[cleandirs] += "${B}"
|
||||||
|
|
||||||
|
do_install() {
|
||||||
|
install -d ${D}/firmware
|
||||||
|
for FW in ${FW_TARGETS}; do
|
||||||
|
for TYPE in ramfw romfw; do
|
||||||
|
install -D "${B}/product/${SCP_PLATFORM}/${FW}_${TYPE}/release/bin/${FW}_${TYPE}.bin" "${D}/firmware/"
|
||||||
|
done
|
||||||
|
done
|
||||||
|
}
|
||||||
|
|
||||||
|
FILES_${PN} = "/firmware"
|
||||||
|
SYSROOT_DIRS += "/firmware"
|
||||||
|
# Skip QA check for relocations in .text of elf binaries
|
||||||
|
INSANE_SKIP_${PN} = "textrel"
|
||||||
|
|
||||||
|
do_deploy() {
|
||||||
|
# Copy the images to deploy directory
|
||||||
|
cp -rf ${D}/firmware/* ${DEPLOYDIR}/
|
||||||
|
}
|
||||||
|
addtask deploy after do_install
|
||||||
|
|||||||
Reference in New Issue
Block a user