From 4f848a33b321ab2cf3bdab543d31a42e20d4492b Mon Sep 17 00:00:00 2001 From: Leon Anavi Date: Wed, 21 Nov 2018 12:59:47 +0200 Subject: fdtoverlay: Provide fdtoverlay-native MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Add a recipe for building fdtoverlay native from the source code of newer dtc without upgrading the version of the main dtc recipe. Bug-AGL: SPEC-1775 Change-Id: I251b22e0ecd4d2de088340daf19b602670668d55 Suggested-by: Jan-Simon Möller Signed-off-by: Leon Anavi (cherry picked from commit 6f78dc25c34e52f6cc064dbbcb09559427ce9216) --- .../recipes-kernel/fdtoverlay/fdtoverlay.inc | 26 ++++++++++++++++++++++ .../fdtoverlay/fdtoverlay/make_install.patch | 26 ++++++++++++++++++++++ .../recipes-kernel/fdtoverlay/fdtoverlay_1.4.7.bb | 10 +++++++++ 3 files changed, 62 insertions(+) create mode 100644 meta-agl-bsp/meta-raspberrypi/recipes-kernel/fdtoverlay/fdtoverlay.inc create mode 100644 meta-agl-bsp/meta-raspberrypi/recipes-kernel/fdtoverlay/fdtoverlay/make_install.patch create mode 100644 meta-agl-bsp/meta-raspberrypi/recipes-kernel/fdtoverlay/fdtoverlay_1.4.7.bb diff --git a/meta-agl-bsp/meta-raspberrypi/recipes-kernel/fdtoverlay/fdtoverlay.inc b/meta-agl-bsp/meta-raspberrypi/recipes-kernel/fdtoverlay/fdtoverlay.inc new file mode 100644 index 000000000..e769a1864 --- /dev/null +++ b/meta-agl-bsp/meta-raspberrypi/recipes-kernel/fdtoverlay/fdtoverlay.inc @@ -0,0 +1,26 @@ +SUMMARY = "fdtoverlay from the device tree compiler" +HOMEPAGE = "https://devicetree.org/" +DESCRIPTION = "fdtoverlay is a tool to apply a number of overlays to a base blob." +SECTION = "bootloader" +LICENSE = "GPLv2 | BSD" +DEPENDS = "flex-native bison-native" + +SRC_URI = "git://git.kernel.org/pub/scm/utils/dtc/dtc.git \ + file://make_install.patch \ + " +UPSTREAM_CHECK_GITTAGREGEX = "v(?P\d+(\.\d+)+)" + +EXTRA_OEMAKE='NO_PYTHON=1 PREFIX="${prefix}" LIBDIR="${libdir}" DESTDIR="${D}"' + +S = "${WORKDIR}/git" + +do_compile () { + oe_runmake fdtoverlay +} + +do_install () { + install -d ${D}/${bindir} + install -m 0755 ${S}/fdtoverlay ${D}/${bindir}/fdtoverlay +} + +FILES_${PN} = "${bindir}/fdtoverlay" diff --git a/meta-agl-bsp/meta-raspberrypi/recipes-kernel/fdtoverlay/fdtoverlay/make_install.patch b/meta-agl-bsp/meta-raspberrypi/recipes-kernel/fdtoverlay/fdtoverlay/make_install.patch new file mode 100644 index 000000000..ea9359e81 --- /dev/null +++ b/meta-agl-bsp/meta-raspberrypi/recipes-kernel/fdtoverlay/fdtoverlay/make_install.patch @@ -0,0 +1,26 @@ +From e9852b9d206df1e42aa4c8afec55a0f5e099b533 Mon Sep 17 00:00:00 2001 +From: Saul Wold +Date: Thu, 3 Nov 2011 08:35:47 -0700 +Subject: [PATCH] dtc: Add patch to correctly install shared libraries and + +Upstream-Status: Inappropriate [configuration] + +--- + Makefile | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +diff --git a/Makefile b/Makefile +index d8ebc4f..f5e01be 100644 +--- a/Makefile ++++ b/Makefile +@@ -205,8 +205,8 @@ install-bin: all $(SCRIPTS) + install-lib: all + @$(VECHO) INSTALL-LIB + $(INSTALL) -d $(DESTDIR)$(LIBDIR) +- $(INSTALL_LIB) $(LIBFDT_lib) $(DESTDIR)$(LIBDIR) +- ln -sf $(notdir $(LIBFDT_lib)) $(DESTDIR)$(LIBDIR)/$(LIBFDT_soname) ++ $(INSTALL) $(LIBFDT_lib) $(DESTDIR)$(LIBDIR)/$(LIBFDT_soname) ++ ln -sf $(LIBFDT_soname) $(DESTDIR)$(LIBDIR)/$(notdir $(LIBFDT_lib)) + ln -sf $(LIBFDT_soname) $(DESTDIR)$(LIBDIR)/libfdt.$(SHAREDLIB_EXT) + $(INSTALL_DATA) $(LIBFDT_archive) $(DESTDIR)$(LIBDIR) + diff --git a/meta-agl-bsp/meta-raspberrypi/recipes-kernel/fdtoverlay/fdtoverlay_1.4.7.bb b/meta-agl-bsp/meta-raspberrypi/recipes-kernel/fdtoverlay/fdtoverlay_1.4.7.bb new file mode 100644 index 000000000..91981987d --- /dev/null +++ b/meta-agl-bsp/meta-raspberrypi/recipes-kernel/fdtoverlay/fdtoverlay_1.4.7.bb @@ -0,0 +1,10 @@ +require fdtoverlay.inc + +LIC_FILES_CHKSUM = "file://GPL;md5=94d55d512a9ba36caa9b7df079bae19f \ + file://libfdt/libfdt.h;beginline=3;endline=52;md5=fb360963151f8ec2d6c06b055bcbb68c" + +SRCREV = "88f18909db731a627456f26d779445f84e449536" + +S = "${WORKDIR}/git" + +BBCLASSEXTEND = "native nativesdk" -- cgit 1.2.3-korg