diff options
Diffstat (limited to 'meta/recipes-kernel/dtc/dtc')
5 files changed, 67 insertions, 97 deletions
diff --git a/meta/recipes-kernel/dtc/dtc/0001-dtc-Fix-Makefile-to-add-CFLAGS-not-override.patch b/meta/recipes-kernel/dtc/dtc/0001-dtc-Fix-Makefile-to-add-CFLAGS-not-override.patch deleted file mode 100644 index a2deb12d4b..0000000000 --- a/meta/recipes-kernel/dtc/dtc/0001-dtc-Fix-Makefile-to-add-CFLAGS-not-override.patch +++ /dev/null @@ -1,36 +0,0 @@ -From f0119060ef1b9bd80e2cae487df1e4aedffb0e9b Mon Sep 17 00:00:00 2001 -From: Oleksiy Obitotskyy <oobitots@cisco.com> -Date: Fri, 22 Jan 2021 09:12:48 +0200 -Subject: [PATCH] dtc: Fix Makefile to add CFLAGS not override - -Makefile override CFLAGS not extend them, so some of them -missing. Sources builds out of kernel tree and probably not all -options could be used (?). We need at least -fmacro-prefix-map/ -debug-prefix-map to eliminate absolute path in binaries. - -Upstream-Status: Pending -Signed-off-by: Oleksiy Obitotskyy <oobitots@cisco.com> ---- - Makefile | 4 ++-- - 1 file changed, 2 insertions(+), 2 deletions(-) - -diff --git a/Makefile b/Makefile -index 35d936f..b5b13cf 100644 ---- a/Makefile -+++ b/Makefile -@@ -20,10 +20,10 @@ CONFIG_LOCALVERSION = - # See libfdt_internal.h for details - ASSUME_MASK ?= 0 - --CPPFLAGS = -I libfdt -I . -DFDT_ASSUME_MASK=$(ASSUME_MASK) -+CPPFLAGS += -I libfdt -I . -DFDT_ASSUME_MASK=$(ASSUME_MASK) - WARNINGS = -Wall -Wpointer-arith -Wcast-qual -Wnested-externs \ - -Wstrict-prototypes -Wmissing-prototypes -Wredundant-decls -Wshadow --CFLAGS = -g -Os $(SHAREDLIB_CFLAGS) -Werror $(WARNINGS) $(EXTRA_CFLAGS) -+CFLAGS += -g -Os $(SHAREDLIB_CFLAGS) -Werror $(WARNINGS) $(EXTRA_CFLAGS) - - BISON = bison - LEX = flex --- -2.25.1 - diff --git a/meta/recipes-kernel/dtc/dtc/0001-fdtdump-Fix-gcc11-warning.patch b/meta/recipes-kernel/dtc/dtc/0001-fdtdump-Fix-gcc11-warning.patch deleted file mode 100644 index ec825cbf7b..0000000000 --- a/meta/recipes-kernel/dtc/dtc/0001-fdtdump-Fix-gcc11-warning.patch +++ /dev/null @@ -1,35 +0,0 @@ -From 4827e0db6c4f7dea7f4094f49d3bb48ef6dfdc2d Mon Sep 17 00:00:00 2001 -From: David Gibson <david@gibson.dropbear.id.au> -Date: Wed, 6 Jan 2021 14:52:26 +1100 -Subject: [PATCH] fdtdump: Fix gcc11 warning - -In one place, fdtdump abuses fdt_set_magic(), passing it just a small char -array instead of the full fdt header it expects. That's relying on the -fact that in fact fdt_set_magic() will only actually access the first 4 -bytes of the buffer. - -This trips a new warning in GCC 11 - and it's entirely possible it was -always UB. So, don't do that. - -Upstream-Status: Backport [https://git.kernel.org/pub/scm/utils/dtc/dtc.git/patch/?id=ca16a723fa9dde9c5da80dba567f48715000e77c] -Signed-off-by: David Gibson <david@gibson.dropbear.id.au> ---- - fdtdump.c | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/fdtdump.c b/fdtdump.c -index 9613bef..d9fb374 100644 ---- a/fdtdump.c -+++ b/fdtdump.c -@@ -217,7 +217,7 @@ int main(int argc, char *argv[]) - char *p = buf; - char *endp = buf + len; - -- fdt_set_magic(smagic, FDT_MAGIC); -+ fdt32_st(smagic, FDT_MAGIC); - - /* poor man's memmem */ - while ((endp - p) >= FDT_MAGIC_SIZE) { --- -2.30.1 - diff --git a/meta/recipes-kernel/dtc/dtc/0001-meson.build-bump-version-to-1.7.0.patch b/meta/recipes-kernel/dtc/dtc/0001-meson.build-bump-version-to-1.7.0.patch new file mode 100644 index 0000000000..79a3b92b44 --- /dev/null +++ b/meta/recipes-kernel/dtc/dtc/0001-meson.build-bump-version-to-1.7.0.patch @@ -0,0 +1,29 @@ +From 9153522103bd4ed7e3299c4d073f66bb37cb2d42 Mon Sep 17 00:00:00 2001 +From: Nikolay Letov <letov.nikolay@gmail.com> +Date: Wed, 22 Feb 2023 13:36:07 +0300 +Subject: [PATCH 1/2] meson.build: bump version to 1.7.0 + +[This was botched in the actual 1.7.0 release :( - David Gibson] + +Upstream-Status: Backport [https://git.kernel.org/pub/scm/utils/dtc/dtc.git/commit/?id=64a907f08b9bedd89833c1eee674148cff2343c6] + +Signed-off-by: Nikolay Letov <letov.nikolay@gmail.com> +Signed-off-by: Peter Marko <peter.marko@siemens.com> +--- + meson.build | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/meson.build b/meson.build +index 78251eb..d88cd9f 100644 +--- a/meson.build ++++ b/meson.build +@@ -1,5 +1,5 @@ + project('dtc', 'c', +- version: '1.6.0', ++ version: '1.7.0', + license: ['GPL2+', 'BSD-2'], + default_options: 'werror=true', + ) +-- +2.30.2 + diff --git a/meta/recipes-kernel/dtc/dtc/0002-meson-allow-building-from-shallow-clones.patch b/meta/recipes-kernel/dtc/dtc/0002-meson-allow-building-from-shallow-clones.patch new file mode 100644 index 0000000000..0284905913 --- /dev/null +++ b/meta/recipes-kernel/dtc/dtc/0002-meson-allow-building-from-shallow-clones.patch @@ -0,0 +1,38 @@ +From 4415b0baece3c4351a6d3637c2754abbefd4795d Mon Sep 17 00:00:00 2001 +From: Peter Marko <peter.marko@siemens.com> +Date: Sat, 16 Dec 2023 18:58:31 +0100 +Subject: [PATCH 2/2] meson: allow building from shallow clones + +When building from shallow clone, tag is not available +and version defaults to git hash. +Problem is that some builds check DTC version and fail the comparison. +Example is https://git.trustedfirmware.org/TF-A/trusted-firmware-a.git +Which fails to build with following error: +dtc version too old (039a994), you need at least version 1.4.4 + +Drop --always from git describe command, see +https://github.com/mesonbuild/meson/blob/1.3.0/mesonbuild/utils/universal.py#L773 +This will make it more closer to build via Makefile. + +Upstream-Status: Submitted [https://github.com/dgibson/dtc/pull/122] + +Signed-off-by: Peter Marko <peter.marko@siemens.com> +--- + meson.build | 1 + + 1 file changed, 1 insertion(+) + +diff --git a/meson.build b/meson.build +index 78251eb..fc0c92a 100644 +--- a/meson.build ++++ b/meson.build +@@ -56,6 +56,7 @@ py = py.find_installation(required: get_option('python')) + swig = find_program('swig', required: get_option('python')) + + version_gen_h = vcs_tag( ++ command: ['git', 'describe', '--dirty=+'], + input: 'version_gen.h.in', + output: 'version_gen.h', + ) +-- +2.30.2 + diff --git a/meta/recipes-kernel/dtc/dtc/make_install.patch b/meta/recipes-kernel/dtc/dtc/make_install.patch deleted file mode 100644 index ea9359e815..0000000000 --- a/meta/recipes-kernel/dtc/dtc/make_install.patch +++ /dev/null @@ -1,26 +0,0 @@ -From e9852b9d206df1e42aa4c8afec55a0f5e099b533 Mon Sep 17 00:00:00 2001 -From: Saul Wold <sgw@linux.intel.com> -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) - |