summaryrefslogtreecommitdiff
path: root/poky/meta/recipes-bsp/u-boot
diff options
context:
space:
mode:
authorAndrew Geissler <geissonator@yahoo.com>2020-04-13 21:39:40 +0300
committerAndrew Geissler <geissonator@yahoo.com>2020-05-05 16:30:44 +0300
commit82c905dc58a36aeae40b1b273a12f63fb1973cf4 (patch)
tree38caf00263451b5036435cdc36e035b25d32e623 /poky/meta/recipes-bsp/u-boot
parent83ecb75644b3d677c274188f9ac0b2374d6f6925 (diff)
downloadopenbmc-82c905dc58a36aeae40b1b273a12f63fb1973cf4.tar.xz
meta-openembedded and poky: subtree updates
Squash of the following due to dependencies among them and OpenBMC changes: meta-openembedded: subtree update:d0748372d2..9201611135 meta-openembedded: subtree update:9201611135..17fd382f34 poky: subtree update:9052e5b32a..2e11d97b6c poky: subtree update:2e11d97b6c..a8544811d7 The change log was too large for the jenkins plugin to handle therefore it has been removed. Here is the first and last commit of each subtree: meta-openembedded:d0748372d2 cppzmq: bump to version 4.6.0 meta-openembedded:17fd382f34 mpv: Remove X11 dependency poky:9052e5b32a package_ipk: Remove pointless comment to trigger rebuild poky:a8544811d7 pbzip2: Fix license warning Change-Id: If0fc6c37629642ee207a4ca2f7aa501a2c673cd6 Signed-off-by: Andrew Geissler <geissonator@yahoo.com>
Diffstat (limited to 'poky/meta/recipes-bsp/u-boot')
-rw-r--r--poky/meta/recipes-bsp/u-boot/files/0001-include-env.h-Ensure-ulong-is-defined.patch31
-rw-r--r--poky/meta/recipes-bsp/u-boot/libubootenv_0.2.bb27
-rw-r--r--poky/meta/recipes-bsp/u-boot/u-boot-common.inc4
-rw-r--r--poky/meta/recipes-bsp/u-boot/u-boot-fw-utils_2019.10.bb36
-rw-r--r--poky/meta/recipes-bsp/u-boot/u-boot-tools.inc (renamed from poky/meta/recipes-bsp/u-boot/u-boot-tools_2019.10.bb)9
-rw-r--r--poky/meta/recipes-bsp/u-boot/u-boot-tools_2020.04.bb2
-rw-r--r--poky/meta/recipes-bsp/u-boot/u-boot.inc72
-rw-r--r--poky/meta/recipes-bsp/u-boot/u-boot_2020.04.bb (renamed from poky/meta/recipes-bsp/u-boot/u-boot_2019.10.bb)0
8 files changed, 94 insertions, 87 deletions
diff --git a/poky/meta/recipes-bsp/u-boot/files/0001-include-env.h-Ensure-ulong-is-defined.patch b/poky/meta/recipes-bsp/u-boot/files/0001-include-env.h-Ensure-ulong-is-defined.patch
deleted file mode 100644
index b9118164df..0000000000
--- a/poky/meta/recipes-bsp/u-boot/files/0001-include-env.h-Ensure-ulong-is-defined.patch
+++ /dev/null
@@ -1,31 +0,0 @@
-From 0565a080d153d5baaaacfeb5045a832e126f4f9e Mon Sep 17 00:00:00 2001
-From: Alistair Francis <alistair.francis@wdc.com>
-Date: Mon, 14 Oct 2019 17:37:30 -0700
-Subject: [PATCH] include/env.h: Ensure ulong is defined
-
-To fix these failures when building with musl:
- include/env.h:166:1: error: unknown type name 'ulong'; did you mean 'long'?
-ensure that ulong is defined.
-
-Upstream-Status: Pending
-Signed-off-by: Alistair Francis <alistair.francis@wdc.com>
----
- include/env.h | 2 ++
- 1 file changed, 2 insertions(+)
-
-diff --git a/include/env.h b/include/env.h
-index b72239f6a5..5ca49a3456 100644
---- a/include/env.h
-+++ b/include/env.h
-@@ -13,6 +13,8 @@
- #include <stdbool.h>
- #include <linux/types.h>
-
-+typedef unsigned long ulong;
-+
- struct environment_s;
-
- /* Value for environment validity */
---
-2.23.0
-
diff --git a/poky/meta/recipes-bsp/u-boot/libubootenv_0.2.bb b/poky/meta/recipes-bsp/u-boot/libubootenv_0.2.bb
new file mode 100644
index 0000000000..3251d0f05b
--- /dev/null
+++ b/poky/meta/recipes-bsp/u-boot/libubootenv_0.2.bb
@@ -0,0 +1,27 @@
+SUMMARY = "U-Boot libraries and tools to access environment"
+DEPENDS += "mtd-utils"
+
+DESCRIPTION = "This package contains tools and libraries to read \
+and modify U-Boot environment. \
+It provides a hardware-independent replacement for fw_printenv/setenv utilities \
+provided by U-Boot"
+
+HOMEPAGE = "https://github.com/sbabic/libubootenv"
+LICENSE = "LGPL-2.1"
+LIC_FILES_CHKSUM = "file://Licenses/lgpl-2.1.txt;md5=4fbd65380cdd255951079008b364516c"
+SECTION = "libs"
+
+PV = "0.2+git${SRCPV}"
+SRC_URI = "git://github.com/sbabic/libubootenv;protocol=https"
+SRCREV = "f4b9cde3815abe84a98079cedd515283ea08c16b"
+
+S = "${WORKDIR}/git"
+
+inherit cmake lib_package
+
+EXTRA_OECMAKE = "-DCMAKE_BUILD_TYPE=Release"
+
+PROVIDES += "u-boot-fw-utils"
+RPROVIDES_${PN}-bin += "u-boot-fw-utils"
+
+BBCLASSEXTEND = "native"
diff --git a/poky/meta/recipes-bsp/u-boot/u-boot-common.inc b/poky/meta/recipes-bsp/u-boot/u-boot-common.inc
index c3e458e925..f4790532b4 100644
--- a/poky/meta/recipes-bsp/u-boot/u-boot-common.inc
+++ b/poky/meta/recipes-bsp/u-boot/u-boot-common.inc
@@ -12,9 +12,11 @@ PE = "1"
# We use the revision in order to avoid having to fetch it from the
# repo during parse
-SRCREV = "61ba1244b548463dbfb3c5285b6b22e7c772c5bd"
+SRCREV = "1079ec0a77c3fda510f07860b2549c47f3a46c21"
SRC_URI = "git://git.denx.de/u-boot.git \
"
S = "${WORKDIR}/git"
+B = "${WORKDIR}/build"
+do_configure[cleandirs] = "${B}"
diff --git a/poky/meta/recipes-bsp/u-boot/u-boot-fw-utils_2019.10.bb b/poky/meta/recipes-bsp/u-boot/u-boot-fw-utils_2019.10.bb
deleted file mode 100644
index 04321b7b66..0000000000
--- a/poky/meta/recipes-bsp/u-boot/u-boot-fw-utils_2019.10.bb
+++ /dev/null
@@ -1,36 +0,0 @@
-require u-boot-common.inc
-
-SUMMARY = "U-Boot bootloader fw_printenv/setenv utilities"
-DEPENDS += "mtd-utils"
-
-SRC_URI += "file://0001-include-env.h-Ensure-ulong-is-defined.patch"
-
-INSANE_SKIP_${PN} = "already-stripped"
-EXTRA_OEMAKE_class-target = 'CROSS_COMPILE=${TARGET_PREFIX} CC="${CC} ${CFLAGS} ${LDFLAGS}" HOSTCC="${BUILD_CC} ${BUILD_CFLAGS} ${BUILD_LDFLAGS}" V=1'
-EXTRA_OEMAKE_class-cross = 'HOSTCC="${CC} ${CFLAGS} ${LDFLAGS}" V=1'
-
-inherit uboot-config
-
-do_compile () {
- oe_runmake ${UBOOT_MACHINE}
- oe_runmake envtools
-}
-
-do_install () {
- install -d ${D}${base_sbindir}
- install -d ${D}${sysconfdir}
- install -m 755 ${S}/tools/env/fw_printenv ${D}${base_sbindir}/fw_printenv
- install -m 755 ${S}/tools/env/fw_printenv ${D}${base_sbindir}/fw_setenv
- install -m 0644 ${S}/tools/env/fw_env.config ${D}${sysconfdir}/fw_env.config
-}
-
-do_install_class-cross () {
- install -d ${D}${bindir_cross}
- install -m 755 ${S}/tools/env/fw_printenv ${D}${bindir_cross}/fw_printenv
- install -m 755 ${S}/tools/env/fw_printenv ${D}${bindir_cross}/fw_setenv
-}
-
-SYSROOT_DIRS_append_class-cross = " ${bindir_cross}"
-
-PACKAGE_ARCH = "${MACHINE_ARCH}"
-BBCLASSEXTEND = "cross"
diff --git a/poky/meta/recipes-bsp/u-boot/u-boot-tools_2019.10.bb b/poky/meta/recipes-bsp/u-boot/u-boot-tools.inc
index bede984ef7..8ae290acc6 100644
--- a/poky/meta/recipes-bsp/u-boot/u-boot-tools_2019.10.bb
+++ b/poky/meta/recipes-bsp/u-boot/u-boot-tools.inc
@@ -1,5 +1,3 @@
-require u-boot-common.inc
-
SUMMARY = "U-Boot bootloader tools"
DEPENDS += "openssl"
@@ -25,14 +23,14 @@ SED_CONFIG_EFI_armeb = ''
SED_CONFIG_EFI_aarch64 = ''
do_compile () {
- oe_runmake sandbox_defconfig
+ oe_runmake -C ${S} sandbox_defconfig O=${B}
# Disable CONFIG_CMD_LICENSE, license.h is not used by tools and
# generating it requires bin2header tool, which for target build
# is built with target tools and thus cannot be executed on host.
- sed -i -e "s/CONFIG_CMD_LICENSE=.*/# CONFIG_CMD_LICENSE is not set/" ${SED_CONFIG_EFI} .config
+ sed -i -e "s/CONFIG_CMD_LICENSE=.*/# CONFIG_CMD_LICENSE is not set/" ${SED_CONFIG_EFI} ${B}/.config
- oe_runmake cross_tools NO_SDL=1
+ oe_runmake -C ${S} cross_tools NO_SDL=1 O=${B}
}
do_install () {
@@ -65,3 +63,4 @@ RDEPENDS_${PN} += "${PN}-mkimage ${PN}-mkenvimage"
RDEPENDS_${PN}_class-native = ""
BBCLASSEXTEND = "native nativesdk"
+
diff --git a/poky/meta/recipes-bsp/u-boot/u-boot-tools_2020.04.bb b/poky/meta/recipes-bsp/u-boot/u-boot-tools_2020.04.bb
new file mode 100644
index 0000000000..7eaf721ca8
--- /dev/null
+++ b/poky/meta/recipes-bsp/u-boot/u-boot-tools_2020.04.bb
@@ -0,0 +1,2 @@
+require u-boot-common.inc
+require u-boot-tools.inc
diff --git a/poky/meta/recipes-bsp/u-boot/u-boot.inc b/poky/meta/recipes-bsp/u-boot/u-boot.inc
index 9a754fd09b..80f828df52 100644
--- a/poky/meta/recipes-bsp/u-boot/u-boot.inc
+++ b/poky/meta/recipes-bsp/u-boot/u-boot.inc
@@ -1,19 +1,17 @@
SUMMARY = "Universal Boot Loader for embedded devices"
PROVIDES = "virtual/bootloader"
-B = "${WORKDIR}/build"
-
PACKAGE_ARCH = "${MACHINE_ARCH}"
DEPENDS += "kern-tools-native"
-inherit uboot-config uboot-extlinux-config uboot-sign deploy cml1
+inherit uboot-config uboot-extlinux-config uboot-sign deploy cml1 python3native
-DEPENDS += "swig-native python-native"
+DEPENDS += "swig-native"
EXTRA_OEMAKE = 'CROSS_COMPILE=${TARGET_PREFIX} CC="${TARGET_PREFIX}gcc ${TOOLCHAIN_OPTIONS}" V=1'
EXTRA_OEMAKE += 'HOSTCC="${BUILD_CC} ${BUILD_CFLAGS} ${BUILD_LDFLAGS}"'
-EXTRA_OEMAKE += 'PYTHON2=nativepython STAGING_INCDIR=${STAGING_INCDIR_NATIVE} STAGING_LIBDIR=${STAGING_LIBDIR_NATIVE}'
+EXTRA_OEMAKE += 'STAGING_INCDIR=${STAGING_INCDIR_NATIVE} STAGING_LIBDIR=${STAGING_LIBDIR_NATIVE}'
PACKAGECONFIG ??= "openssl"
# u-boot will compile its own tools during the build, with specific
@@ -87,6 +85,8 @@ do_configure () {
fi
merge_config.sh -m .config ${@" ".join(find_cfgs(d))}
cml1_do_configure
+ else
+ DEVTOOL_DISABLE_MENUCONFIG=true
fi
}
@@ -122,6 +122,11 @@ do_compile () {
cp ${B}/${config}/${binary} ${B}/${config}/u-boot-${type}.${UBOOT_SUFFIX}
fi
done
+
+ # Generate the uboot-initial-env
+ oe_runmake -C ${S} O=${B}/${config} u-boot-initial-env
+ cp ${B}/${config}/u-boot-initial-env ${B}/${config}/u-boot-initial-env-${type}
+
unset k
fi
done
@@ -130,6 +135,9 @@ do_compile () {
unset i
else
oe_runmake -C ${S} O=${B} ${UBOOT_MAKE_TARGET}
+
+ # Generate the uboot-initial-env
+ oe_runmake -C ${S} O=${B} u-boot-initial-env
fi
}
@@ -143,19 +151,28 @@ do_install () {
j=$(expr $j + 1);
if [ $j -eq $i ]
then
- install -d ${D}/boot
- install -m 644 ${B}/${config}/u-boot-${type}.${UBOOT_SUFFIX} ${D}/boot/u-boot-${type}-${PV}-${PR}.${UBOOT_SUFFIX}
+ install -D -m 644 ${B}/${config}/u-boot-${type}.${UBOOT_SUFFIX} ${D}/boot/u-boot-${type}-${PV}-${PR}.${UBOOT_SUFFIX}
ln -sf u-boot-${type}-${PV}-${PR}.${UBOOT_SUFFIX} ${D}/boot/${UBOOT_BINARY}-${type}
ln -sf u-boot-${type}-${PV}-${PR}.${UBOOT_SUFFIX} ${D}/boot/${UBOOT_BINARY}
+
+ # Install the uboot-initial-env
+ install -D -m 644 ${B}/${config}/u-boot-initial-env-${type} ${D}/${sysconfdir}/${PN}-initial-env-${MACHINE}-${type}-${PV}-${PR}
+ ln -sf ${PN}-initial-env-${MACHINE}-${type}-${PV}-${PR} ${D}/${sysconfdir}/${PN}-initial-env-${MACHINE}-${type}
+ ln -sf ${PN}-initial-env-${MACHINE}-${type}-${PV}-${PR} ${D}/${sysconfdir}/${PN}-initial-env-${type}
+ ln -sf ${PN}-initial-env-${MACHINE}-${type}-${PV}-${PR} ${D}/${sysconfdir}/${PN}-initial-env
fi
done
unset j
done
unset i
else
- install -d ${D}/boot
- install -m 644 ${B}/${UBOOT_BINARY} ${D}/boot/${UBOOT_IMAGE}
+ install -D -m 644 ${B}/${UBOOT_BINARY} ${D}/boot/${UBOOT_IMAGE}
ln -sf ${UBOOT_IMAGE} ${D}/boot/${UBOOT_BINARY}
+
+ # Install the uboot-initial-env
+ install -D -m 644 ${B}/u-boot-initial-env ${D}/${sysconfdir}/${PN}-initial-env-${MACHINE}-${PV}-${PR}
+ ln -sf ${PN}-initial-env-${MACHINE}-${PV}-${PR} ${D}/${sysconfdir}/${PN}-initial-env-${MACHINE}
+ ln -sf ${PN}-initial-env-${MACHINE}-${PV}-${PR} ${D}/${sysconfdir}/${PN}-initial-env
fi
if [ -n "${UBOOT_ELF}" ]
@@ -224,7 +241,16 @@ do_install () {
}
-FILES_${PN} = "/boot ${sysconfdir} ${datadir}"
+PACKAGE_BEFORE_PN += "${PN}-env"
+
+RPROVIDES_${PN}-env += "u-boot-default-env"
+FILES_${PN}-env = " \
+ ${sysconfdir}/${PN}-initial-env* \
+ ${sysconfdir}/fw_env.config \
+"
+
+FILES_${PN} = "/boot ${datadir}"
+RDEPENDS_${PN} += "${PN}-env"
do_deploy () {
if [ -n "${UBOOT_CONFIG}" ]
@@ -235,25 +261,43 @@ do_deploy () {
j=$(expr $j + 1);
if [ $j -eq $i ]
then
- install -d ${DEPLOYDIR}
- install -m 644 ${B}/${config}/u-boot-${type}.${UBOOT_SUFFIX} ${DEPLOYDIR}/u-boot-${type}-${PV}-${PR}.${UBOOT_SUFFIX}
+ install -D -m 644 ${B}/${config}/u-boot-${type}.${UBOOT_SUFFIX} ${DEPLOYDIR}/u-boot-${type}-${PV}-${PR}.${UBOOT_SUFFIX}
cd ${DEPLOYDIR}
ln -sf u-boot-${type}-${PV}-${PR}.${UBOOT_SUFFIX} ${UBOOT_SYMLINK}-${type}
ln -sf u-boot-${type}-${PV}-${PR}.${UBOOT_SUFFIX} ${UBOOT_SYMLINK}
ln -sf u-boot-${type}-${PV}-${PR}.${UBOOT_SUFFIX} ${UBOOT_BINARY}-${type}
ln -sf u-boot-${type}-${PV}-${PR}.${UBOOT_SUFFIX} ${UBOOT_BINARY}
+
+ # Deploy the uboot-initial-env
+ install -D -m 644 ${B}/${config}/u-boot-initial-env-${type} ${DEPLOYDIR}/${PN}-initial-env-${MACHINE}-${type}-${PV}-${PR}
+ cd ${DEPLOYDIR}
+ ln -sf ${PN}-initial-env-${MACHINE}-${type}-${PV}-${PR} ${PN}-initial-env-${MACHINE}-${type}
+ ln -sf ${PN}-initial-env-${MACHINE}-${type}-${PV}-${PR} ${PN}-initial-env-${type}
fi
done
unset j
done
unset i
else
- install -d ${DEPLOYDIR}
- install -m 644 ${B}/${UBOOT_BINARY} ${DEPLOYDIR}/${UBOOT_IMAGE}
+ install -D -m 644 ${B}/${UBOOT_BINARY} ${DEPLOYDIR}/${UBOOT_IMAGE}
+
cd ${DEPLOYDIR}
rm -f ${UBOOT_BINARY} ${UBOOT_SYMLINK}
ln -sf ${UBOOT_IMAGE} ${UBOOT_SYMLINK}
ln -sf ${UBOOT_IMAGE} ${UBOOT_BINARY}
+
+ # Deploy the uboot-initial-env
+ install -D -m 644 ${B}/u-boot-initial-env ${DEPLOYDIR}/${PN}-initial-env-${MACHINE}-${PV}-${PR}
+ cd ${DEPLOYDIR}
+ ln -sf ${PN}-initial-env-${MACHINE}-${PV}-${PR} ${PN}-initial-env-${MACHINE}
+ ln -sf ${PN}-initial-env-${MACHINE}-${PV}-${PR} ${PN}-initial-env
+ fi
+
+ if [ -e ${WORKDIR}/fw_env.config ] ; then
+ install -D -m 644 ${WORKDIR}/fw_env.config ${DEPLOYDIR}/fw_env.config-${MACHINE}-${PV}-${PR}
+ cd ${DEPLOYDIR}
+ ln -sf fw_env.config-${MACHINE}-${PV}-${PR} fw_env.config-${MACHINE}
+ ln -sf fw_env.config-${MACHINE}-${PV}-${PR} fw_env.config
fi
if [ -n "${UBOOT_ELF}" ]
diff --git a/poky/meta/recipes-bsp/u-boot/u-boot_2019.10.bb b/poky/meta/recipes-bsp/u-boot/u-boot_2020.04.bb
index 02d67c0db2..02d67c0db2 100644
--- a/poky/meta/recipes-bsp/u-boot/u-boot_2019.10.bb
+++ b/poky/meta/recipes-bsp/u-boot/u-boot_2020.04.bb