Hi,

I had to patch up our own u-boot recipe as shown in the attached patch to make v2018.03 compile for qemu-x86.

The thing is that the build of pylibfdt became unconditional since 15b97f5c5e ('pylibfdt: move pylibfdt to scripts/dtc/pylibfdt and refactor makefile')

In my case u-boot/pylibfdt failed to find the correct (native) headers, because python setuptools / distutils looks into STAGING_{LIB,INC}DIR when compiling the native extension for libfdt. I didn't find any other way to specificy this in either the u-boot Makefile or some other magic environment variable.

// Martin

On 2018-04-09 02:54, Khem Raj wrote:

On Sun, Apr 8, 2018 at 4:10 PM Marek Vasut <ma...@denx.de <mailto:ma...@denx.de>> wrote:

    This upgrades the U-Boot from 2018.01 to 2018.03 release and drops
    patches accepted upstream, getting the patch count to zero.



It fails for me if I have libfdt installed on build host
It seems build is doing the include dance which goes all the way into hosts system include directories



    Signed-off-by: Marek Vasut <ma...@denx.de <mailto:ma...@denx.de>>
    Cc: Otavio Salvador <ota...@ossystems.com.br
    <mailto:ota...@ossystems.com.br>>
    Cc: Ross Burton <ross.bur...@intel.com <mailto:ross.bur...@intel.com>>
    Cc: Richard Purdie <richard.pur...@linuxfoundation.org
    <mailto:richard.pur...@linuxfoundation.org>>
    ---
      .../u-boot/files/MPC8315ERDB-enable-DHCP.patch        | 19
    -------------------
      ...t-common_2018.01.inc => u-boot-common_2018.03.inc} |  6 ++----
      ...fw-utils_2018.01.bb <http://fw-utils_2018.01.bb> =>
    u-boot-fw-utils_2018.03.bb <http://u-boot-fw-utils_2018.03.bb>} |  0
      ...t-mkimage_2018.01.bb <http://t-mkimage_2018.01.bb> =>
    u-boot-mkimage_2018.03.bb <http://u-boot-mkimage_2018.03.bb>} |  0
      .../u-boot/{u-boot_2018.01.bb <http://u-boot_2018.01.bb> =>
    u-boot_2018.03.bb <http://u-boot_2018.03.bb>}   |  0
      5 files changed, 2 insertions(+), 23 deletions(-)
      delete mode 100644
    meta/recipes-bsp/u-boot/files/MPC8315ERDB-enable-DHCP.patch
      rename meta/recipes-bsp/u-boot/{u-boot-common_2018.01.inc =>
    u-boot-common_2018.03.inc} (68%)
      rename meta/recipes-bsp/u-boot/{u-boot-fw-utils_2018.01.bb
    <http://u-boot-fw-utils_2018.01.bb> => u-boot-fw-utils_2018.03.bb
    <http://u-boot-fw-utils_2018.03.bb>} (100%)
      rename meta/recipes-bsp/u-boot/{u-boot-mkimage_2018.01.bb
    <http://u-boot-mkimage_2018.01.bb> => u-boot-mkimage_2018.03.bb
    <http://u-boot-mkimage_2018.03.bb>} (100%)
      rename meta/recipes-bsp/u-boot/{u-boot_2018.01.bb
    <http://u-boot_2018.01.bb> => u-boot_2018.03.bb
    <http://u-boot_2018.03.bb>} (100%)

    diff --git
    a/meta/recipes-bsp/u-boot/files/MPC8315ERDB-enable-DHCP.patch
    b/meta/recipes-bsp/u-boot/files/MPC8315ERDB-enable-DHCP.patch
    deleted file mode 100644
    index ecaa1796a4..0000000000
    --- a/meta/recipes-bsp/u-boot/files/MPC8315ERDB-enable-DHCP.patch
    +++ /dev/null
    @@ -1,19 +0,0 @@
    -Enabled dhcp client functionality for Yocto reference
    -hardware MPC8315E-RDB.
    -
    -Upstream-Status: Pending
    -
    -Signed-off-by: Ed Bartosh <ed.bart...@linux.intel.com
    <mailto:ed.bart...@linux.intel.com>>
    -
    -Index: git/configs/MPC8315ERDB_defconfig
    -===================================================================
    ---- git.orig/configs/MPC8315ERDB_defconfig
    -+++ git/configs/MPC8315ERDB_defconfig
    -@@ -12,6 +12,7 @@ CONFIG_CMD_PCI=y
    - CONFIG_CMD_SATA=y
    - CONFIG_CMD_USB=y
    - # CONFIG_CMD_SETEXPR is not set
    -+CONFIG_CMD_DHCP=y
    - CONFIG_CMD_MII=y
    - CONFIG_CMD_PING=y
    - CONFIG_CMD_DATE=y
    diff --git a/meta/recipes-bsp/u-boot/u-boot-common_2018.01.inc
    b/meta/recipes-bsp/u-boot/u-boot-common_2018.03.inc
    similarity index 68%
    rename from meta/recipes-bsp/u-boot/u-boot-common_2018.01.inc
    rename to meta/recipes-bsp/u-boot/u-boot-common_2018.03.inc
    index d2073ea0c7..8ffae365a9 100644
    --- a/meta/recipes-bsp/u-boot/u-boot-common_2018.01.inc
    +++ b/meta/recipes-bsp/u-boot/u-boot-common_2018.03.inc
    @@ -7,10 +7,8 @@ PE = "1"

      # We use the revision in order to avoid having to fetch it from the
      # repo during parse
    -SRCREV = "f3dd87e0b98999a78e500e8c6d2b063ebadf535a"
    +SRCREV = "f95ab1fb6e37f0601f397091bb011edf7a98b890"

    -SRC_URI = "git://git.denx.de/u-boot.git
    <http://git.denx.de/u-boot.git> \
    -    file://MPC8315ERDB-enable-DHCP.patch \
    -"
    +SRC_URI = "git://git.denx.de/u-boot.git
    <http://git.denx.de/u-boot.git>"

      S = "${WORKDIR}/git"
    diff --git a/meta/recipes-bsp/u-boot/u-boot-fw-utils_2018.01.bb
    <http://u-boot-fw-utils_2018.01.bb>
    b/meta/recipes-bsp/u-boot/u-boot-fw-utils_2018.03.bb
    <http://u-boot-fw-utils_2018.03.bb>
    similarity index 100%
    rename from meta/recipes-bsp/u-boot/u-boot-fw-utils_2018.01.bb
    <http://u-boot-fw-utils_2018.01.bb>
    rename to meta/recipes-bsp/u-boot/u-boot-fw-utils_2018.03.bb
    <http://u-boot-fw-utils_2018.03.bb>
    diff --git a/meta/recipes-bsp/u-boot/u-boot-mkimage_2018.01.bb
    <http://u-boot-mkimage_2018.01.bb>
    b/meta/recipes-bsp/u-boot/u-boot-mkimage_2018.03.bb
    <http://u-boot-mkimage_2018.03.bb>
    similarity index 100%
    rename from meta/recipes-bsp/u-boot/u-boot-mkimage_2018.01.bb
    <http://u-boot-mkimage_2018.01.bb>
    rename to meta/recipes-bsp/u-boot/u-boot-mkimage_2018.03.bb
    <http://u-boot-mkimage_2018.03.bb>
    diff --git a/meta/recipes-bsp/u-boot/u-boot_2018.01.bb
    <http://u-boot_2018.01.bb>
    b/meta/recipes-bsp/u-boot/u-boot_2018.03.bb <http://u-boot_2018.03.bb>
    similarity index 100%
    rename from meta/recipes-bsp/u-boot/u-boot_2018.01.bb
    <http://u-boot_2018.01.bb>
    rename to meta/recipes-bsp/u-boot/u-boot_2018.03.bb
    <http://u-boot_2018.03.bb>
    --
    2.16.2

    --
    _______________________________________________
    Openembedded-core mailing list
    Openembedded-core@lists.openembedded.org
    <mailto:Openembedded-core@lists.openembedded.org>
    http://lists.openembedded.org/mailman/listinfo/openembedded-core



>From f037effcf106808fdb42ab84e1424e0d616104a0 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Martin=20Hundeb=C3=B8ll?= <m...@prevas.dk>
Date: Tue, 3 Apr 2018 15:36:50 +0200
Subject: [PATCH] u-boot-pil: fix cross compile for qemux86
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

Signed-off-by: Martin Hundebøll <m...@prevas.dk>
---
 recipes-bsp/u-boot/u-boot-pil_git.bb | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/recipes-bsp/u-boot/u-boot-pil_git.bb b/recipes-bsp/u-boot/u-boot-pil_git.bb
index e57ed8c..b5a3f09 100644
--- a/recipes-bsp/u-boot/u-boot-pil_git.bb
+++ b/recipes-bsp/u-boot/u-boot-pil_git.bb
@@ -1,5 +1,6 @@
 DESCRIPTION = "PIL U-Boot"
 
+inherit pythonnative
 require recipes-bsp/u-boot/u-boot.inc
 
 DEPENDS += "bc-native dtc-native swig-native"
@@ -13,4 +14,9 @@ LIC_FILES_CHKSUM = "file://Licenses/gpl-2.0.txt;md5=b234ee4d69f5fce4486a80fdaf4a
 SRC_URI = "git://${TOPDIR}/src/u-boot;protocol=file;nobranch=1"
 SRCREV ?= "9fa7d5863214935fe0f2aca5a4c5edfe25deb848"
 
+do_compile_prepend() {
+    export STAGING_LIBDIR="${STAGING_LIBDIR_NATIVE}"
+    export STAGING_INCDIR="${STAGING_INCDIR_NATIVE}"
+}
+
 S = "${WORKDIR}/git"
-- 
2.17.0

-- 
_______________________________________________
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core

Reply via email to