[Armadeus-commitlog] armadeus branch, master, updated. armadeus-7.0-244-g6e33f21ca
Brought to you by:
sszy
|
From: Sébastien S. <ss...@us...> - 2021-04-06 17:01:31
|
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "armadeus".
The branch, master has been updated
via 6e33f21ca6e7119a142206c9c12adf8be5c68625 (commit)
via 63315f93cc2955dee7677e97e9662ca74c5721ff (commit)
from 5a080fe7aff54ede5fb1bae0eacb0fb0d944d3f4 (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
commit 6e33f21ca6e7119a142206c9c12adf8be5c68625
Author: Sébastien Szymanski <seb...@ar...>
Date: Tue Apr 6 12:09:20 2021 +0200
[LINUX] 4.9.legacy: patches to fix building with recent make
commit 63315f93cc2955dee7677e97e9662ca74c5721ff
Author: Sébastien Szymanski <seb...@ar...>
Date: Tue Apr 6 10:39:38 2021 +0200
[LINUX] 4.9.legacy: patch to fix kernel building on host with GCC 10
-----------------------------------------------------------------------
Summary of changes:
...-Remove-redundant-YYLOC-global-declaratio.patch | 70 +++++++++++
...ix-escaping-in-.cmd-files-for-future-Make.patch | 133 +++++++++++++++++++++
...-fix-escaping-in-.cmd-files-for-future-Ma.patch | 62 ++++++++++
3 files changed, 265 insertions(+)
create mode 100644 patches/linux/4.9.mx6_legacy/0817-scripts-dtc-Remove-redundant-YYLOC-global-declaratio.patch
create mode 100644 patches/linux/4.9.mx6_legacy/0818-Kbuild-fix-escaping-in-.cmd-files-for-future-Make.patch
create mode 100644 patches/linux/4.9.mx6_legacy/0819-tools-build-fix-escaping-in-.cmd-files-for-future-Ma.patch
diff --git a/patches/linux/4.9.mx6_legacy/0817-scripts-dtc-Remove-redundant-YYLOC-global-declaratio.patch b/patches/linux/4.9.mx6_legacy/0817-scripts-dtc-Remove-redundant-YYLOC-global-declaratio.patch
new file mode 100644
index 000000000..0ae83d291
--- /dev/null
+++ b/patches/linux/4.9.mx6_legacy/0817-scripts-dtc-Remove-redundant-YYLOC-global-declaratio.patch
@@ -0,0 +1,70 @@
+From 8e8ab8554aa4988db5e1028fbd02c51af676a7f2 Mon Sep 17 00:00:00 2001
+From: Dirk Mueller <dmu...@su...>
+Date: Tue, 14 Jan 2020 18:53:41 +0100
+Subject: [PATCH 1/1] scripts/dtc: Remove redundant YYLOC global declaration
+
+commit e33a814e772cdc36436c8c188d8c42d019fda639 upstream.
+
+gcc 10 will default to -fno-common, which causes this error at link
+time:
+
+ (.text+0x0): multiple definition of `yylloc'; dtc-lexer.lex.o (symbol from plugin):(.text+0x0): first defined here
+
+This is because both dtc-lexer as well as dtc-parser define the same
+global symbol yyloc. Before with -fcommon those were merged into one
+defintion. The proper solution would be to to mark this as "extern",
+however that leads to:
+
+ dtc-lexer.l:26:16: error: redundant redeclaration of 'yylloc' [-Werror=redundant-decls]
+ 26 | extern YYLTYPE yylloc;
+ | ^~~~~~
+In file included from dtc-lexer.l:24:
+dtc-parser.tab.h:127:16: note: previous declaration of 'yylloc' was here
+ 127 | extern YYLTYPE yylloc;
+ | ^~~~~~
+cc1: all warnings being treated as errors
+
+which means the declaration is completely redundant and can just be
+dropped.
+
+Signed-off-by: Dirk Mueller <dmu...@su...>
+Signed-off-by: David Gibson <da...@gi...>
+[robh: cherry-pick from upstream]
+Cc: st...@vg...
+Signed-off-by: Rob Herring <ro...@ke...>
+[nc: Also apply to dtc-lexer.lex.c_shipped due to a lack of
+ e039139be8c2, where dtc-lexer.l started being used]
+Signed-off-by: Nathan Chancellor <nat...@gm...>
+Signed-off-by: Greg Kroah-Hartman <gr...@li...>
+---
+ scripts/dtc/dtc-lexer.l | 1 -
+ scripts/dtc/dtc-lexer.lex.c_shipped | 1 -
+ 2 files changed, 2 deletions(-)
+
+diff --git a/scripts/dtc/dtc-lexer.l b/scripts/dtc/dtc-lexer.l
+index 790fbf6cf2d7..e4e0f6a8d07b 100644
+--- a/scripts/dtc/dtc-lexer.l
++++ b/scripts/dtc/dtc-lexer.l
+@@ -38,7 +38,6 @@ LINECOMMENT "//".*\n
+ #include "srcpos.h"
+ #include "dtc-parser.tab.h"
+
+-YYLTYPE yylloc;
+ extern bool treesource_error;
+
+ /* CAUTION: this will stop working if we ever use yyless() or yyunput() */
+diff --git a/scripts/dtc/dtc-lexer.lex.c_shipped b/scripts/dtc/dtc-lexer.lex.c_shipped
+index ba525c2f9fc2..750f7a4e3ece 100644
+--- a/scripts/dtc/dtc-lexer.lex.c_shipped
++++ b/scripts/dtc/dtc-lexer.lex.c_shipped
+@@ -637,7 +637,6 @@ char *yytext;
+ #include "srcpos.h"
+ #include "dtc-parser.tab.h"
+
+-YYLTYPE yylloc;
+ extern bool treesource_error;
+
+ /* CAUTION: this will stop working if we ever use yyless() or yyunput() */
+--
+2.26.3
+
diff --git a/patches/linux/4.9.mx6_legacy/0818-Kbuild-fix-escaping-in-.cmd-files-for-future-Make.patch b/patches/linux/4.9.mx6_legacy/0818-Kbuild-fix-escaping-in-.cmd-files-for-future-Make.patch
new file mode 100644
index 000000000..ad45c7e74
--- /dev/null
+++ b/patches/linux/4.9.mx6_legacy/0818-Kbuild-fix-escaping-in-.cmd-files-for-future-Make.patch
@@ -0,0 +1,133 @@
+From b5d7d7d919f1708f2645739d37dc19747ac0ab5b Mon Sep 17 00:00:00 2001
+From: Rasmus Villemoes <li...@ra...>
+Date: Sun, 8 Apr 2018 23:35:28 +0200
+Subject: [PATCH 1/1] Kbuild: fix # escaping in .cmd files for future Make
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+commit 9564a8cf422d7b58f6e857e3546d346fa970191e upstream.
+
+I tried building using a freshly built Make (4.2.1-69-g8a731d1), but
+already the objtool build broke with
+
+orc_dump.c: In function âorc_dumpâ:
+orc_dump.c:106:2: error: âelf_getshnumâ is deprecated [-Werror=deprecated-declarations]
+ if (elf_getshdrnum(elf, &nr_sections)) {
+
+Turns out that with that new Make, the backslash was not removed, so cpp
+didn't see a #include directive, grep found nothing, and
+-DLIBELF_USE_DEPRECATED was wrongly put in CFLAGS.
+
+Now, that new Make behaviour is documented in their NEWS file:
+
+ * WARNING: Backward-incompatibility!
+ Number signs (#) appearing inside a macro reference or function invocation
+ no longer introduce comments and should not be escaped with backslashes:
+ thus a call such as:
+ foo := $(shell echo '#')
+ is legal. Previously the number sign needed to be escaped, for example:
+ foo := $(shell echo '\#')
+ Now this latter will resolve to "\#". If you want to write makefiles
+ portable to both versions, assign the number sign to a variable:
+ C := \#
+ foo := $(shell echo '$C')
+ This was claimed to be fixed in 3.81, but wasn't, for some reason.
+ To detect this change search for 'nocomment' in the .FEATURES variable.
+
+This also fixes up the two make-cmd instances to replace # with $(pound)
+rather than with \#. There might very well be other places that need
+similar fixup in preparation for whatever future Make release contains
+the above change, but at least this builds an x86_64 defconfig with the
+new make.
+
+Link: https://bugzilla.kernel.org/show_bug.cgi?id=197847
+Cc: Randy Dunlap <rd...@in...>
+Signed-off-by: Rasmus Villemoes <li...@ra...>
+Signed-off-by: Masahiro Yamada <yam...@so...>
+Signed-off-by: Greg Kroah-Hartman <gr...@li...>
+---
+ scripts/Kbuild.include | 5 +++--
+ tools/build/Build.include | 5 +++--
+ tools/objtool/Makefile | 2 +-
+ tools/scripts/Makefile.include | 2 ++
+ 4 files changed, 9 insertions(+), 5 deletions(-)
+
+diff --git a/scripts/Kbuild.include b/scripts/Kbuild.include
+index 179219845dfc..63774307a751 100644
+--- a/scripts/Kbuild.include
++++ b/scripts/Kbuild.include
+@@ -8,6 +8,7 @@ squote := '
+ empty :=
+ space := $(empty) $(empty)
+ space_escape := _-_SPACE_-_
++pound := \#
+
+ ###
+ # Name of target with a '.' as filename prefix. foo/bar.o => foo/.bar.o
+@@ -241,11 +242,11 @@ endif
+
+ # Replace >$< with >$$< to preserve $ when reloading the .cmd file
+ # (needed for make)
+-# Replace >#< with >\#< to avoid starting a comment in the .cmd file
++# Replace >#< with >$(pound)< to avoid starting a comment in the .cmd file
+ # (needed for make)
+ # Replace >'< with >'\''< to be able to enclose the whole string in '...'
+ # (needed for the shell)
+-make-cmd = $(call escsq,$(subst \#,\\\#,$(subst $$,$$$$,$(cmd_$(1)))))
++make-cmd = $(call escsq,$(subst $(pound),$$(pound),$(subst $$,$$$$,$(cmd_$(1)))))
+
+ # Find any prerequisites that is newer than target or that does not exist.
+ # PHONY targets skipped in both cases.
+diff --git a/tools/build/Build.include b/tools/build/Build.include
+index 1dcb95e76f70..b8165545ddf6 100644
+--- a/tools/build/Build.include
++++ b/tools/build/Build.include
+@@ -12,6 +12,7 @@
+ # Convenient variables
+ comma := ,
+ squote := '
++pound := \#
+
+ ###
+ # Name of target with a '.' as filename prefix. foo/bar.o => foo/.bar.o
+@@ -43,11 +44,11 @@ echo-cmd = $(if $($(quiet)cmd_$(1)),\
+ ###
+ # Replace >$< with >$$< to preserve $ when reloading the .cmd file
+ # (needed for make)
+-# Replace >#< with >\#< to avoid starting a comment in the .cmd file
++# Replace >#< with >$(pound)< to avoid starting a comment in the .cmd file
+ # (needed for make)
+ # Replace >'< with >'\''< to be able to enclose the whole string in '...'
+ # (needed for the shell)
+-make-cmd = $(call escsq,$(subst \#,\\\#,$(subst $$,$$$$,$(cmd_$(1)))))
++make-cmd = $(call escsq,$(subst $(pound),$$(pound),$(subst $$,$$$$,$(cmd_$(1)))))
+
+ ###
+ # Find any prerequisites that is newer than target or that does not exist.
+diff --git a/tools/objtool/Makefile b/tools/objtool/Makefile
+index e6acc281dd37..8ae824dbfca3 100644
+--- a/tools/objtool/Makefile
++++ b/tools/objtool/Makefile
+@@ -35,7 +35,7 @@ CFLAGS += -Wall -Werror $(WARNINGS) -fomit-frame-pointer -O2 -g $(INCLUDES)
+ LDFLAGS += -lelf $(LIBSUBCMD)
+
+ # Allow old libelf to be used:
+-elfshdr := $(shell echo '\#include <libelf.h>' | $(CC) $(CFLAGS) -x c -E - | grep elf_getshdr)
++elfshdr := $(shell echo '$(pound)include <libelf.h>' | $(CC) $(CFLAGS) -x c -E - | grep elf_getshdr)
+ CFLAGS += $(if $(elfshdr),,-DLIBELF_USE_DEPRECATED)
+
+ AWK = awk
+diff --git a/tools/scripts/Makefile.include b/tools/scripts/Makefile.include
+index 19edc1a7a232..7ea4438b801d 100644
+--- a/tools/scripts/Makefile.include
++++ b/tools/scripts/Makefile.include
+@@ -92,3 +92,5 @@ ifneq ($(silent),1)
+ QUIET_INSTALL = @printf ' INSTALL %s\n' $1;
+ endif
+ endif
++
++pound := \#
+--
+2.26.3
+
diff --git a/patches/linux/4.9.mx6_legacy/0819-tools-build-fix-escaping-in-.cmd-files-for-future-Ma.patch b/patches/linux/4.9.mx6_legacy/0819-tools-build-fix-escaping-in-.cmd-files-for-future-Ma.patch
new file mode 100644
index 000000000..88f6110cf
--- /dev/null
+++ b/patches/linux/4.9.mx6_legacy/0819-tools-build-fix-escaping-in-.cmd-files-for-future-Ma.patch
@@ -0,0 +1,62 @@
+From 36c038f0a97edc9f76000f6238a37c8dd16781cb Mon Sep 17 00:00:00 2001
+From: Paul Menzel <pm...@mo...>
+Date: Tue, 5 Jun 2018 19:00:22 +0200
+Subject: [PATCH 1/1] tools build: fix # escaping in .cmd files for future Make
+
+commit 9feeb638cde083c737e295c0547f1b4f28e99583 upstream.
+
+In 2016 GNU Make made a backwards incompatible change to the way '#'
+characters were handled in Makefiles when used inside functions or
+macros:
+
+http://git.savannah.gnu.org/cgit/make.git/commit/?id=c6966b323811c37acedff05b57
+
+Due to this change, when attempting to run `make prepare' I get a
+spurious make syntax error:
+
+ /home/earnest/linux/tools/objtool/.fixdep.o.cmd:1: *** missing separator. Stop.
+
+When inspecting `.fixdep.o.cmd' it includes two lines which use
+unescaped comment characters at the top:
+
+ \# cannot find fixdep (/home/earnest/linux/tools/objtool//fixdep)
+ \# using basic dep data
+
+This is because `tools/build/Build.include' prints these '\#'
+characters:
+
+ printf '\# cannot find fixdep (%s)\n' $(fixdep) > $(dot-target).cmd; \
+ printf '\# using basic dep data\n\n' >> $(dot-target).cmd; \
+
+This completes commit 9564a8cf422d ("Kbuild: fix # escaping in .cmd files
+for future Make").
+
+Link: https://bugzilla.kernel.org/show_bug.cgi?id=197847
+Cc: Randy Dunlap <rd...@in...>
+Cc: Rasmus Villemoes <li...@ra...>
+Cc: st...@vg...
+Signed-off-by: Paul Menzel <pm...@mo...>
+Signed-off-by: Masahiro Yamada <yam...@so...>
+Signed-off-by: Greg Kroah-Hartman <gr...@li...>
+---
+ tools/build/Build.include | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/tools/build/Build.include b/tools/build/Build.include
+index b8165545ddf6..ab02f8df0d56 100644
+--- a/tools/build/Build.include
++++ b/tools/build/Build.include
+@@ -63,8 +63,8 @@ dep-cmd = $(if $(wildcard $(fixdep)),
+ $(fixdep) $(depfile) $@ '$(make-cmd)' > $(dot-target).tmp; \
+ rm -f $(depfile); \
+ mv -f $(dot-target).tmp $(dot-target).cmd, \
+- printf '\# cannot find fixdep (%s)\n' $(fixdep) > $(dot-target).cmd; \
+- printf '\# using basic dep data\n\n' >> $(dot-target).cmd; \
++ printf '$(pound) cannot find fixdep (%s)\n' $(fixdep) > $(dot-target).cmd; \
++ printf '$(pound) using basic dep data\n\n' >> $(dot-target).cmd; \
+ cat $(depfile) >> $(dot-target).cmd; \
+ printf '%s\n' 'cmd_$@ := $(make-cmd)' >> $(dot-target).cmd)
+
+--
+2.26.3
+
hooks/post-receive
--
armadeus
|