From 4b3494d8a1a7338cab7dcea568cb75003a5a7f0c Mon Sep 17 00:00:00 2001 From: panxiaohe Date: Fri, 30 Jul 2021 14:22:10 +0800 Subject: [PATCH] Support -fno-common in vala-mix2 test --- automake.spec | 6 ++- ...support-fno-common-in-vala-mix2-test.patch | 38 +++++++++++++++++++ 2 files changed, 43 insertions(+), 1 deletion(-) create mode 100644 tests-support-fno-common-in-vala-mix2-test.patch diff --git a/automake.spec b/automake.spec index 57e9094..259d3e3 100644 --- a/automake.spec +++ b/automake.spec @@ -4,7 +4,7 @@ Name: automake Version: 1.16.2 -Release: 2 +Release: 3 Summary: A tool for automatically generating Makefile.in files License: GPLv2+ and GFDL and Public Domain and MIT URL: http://www.gnu.org/software/automake/ @@ -13,6 +13,7 @@ Source1: http://git.savannah.gnu.org/cgit/config.git/plain/config.sub Source2: http://git.savannah.gnu.org/cgit/config.git/plain/config.guess Patch1: tests-require-etags-for-tags-lisp-space-test.patch +Patch2: tests-support-fno-common-in-vala-mix2-test.patch BuildArch: noarch @@ -75,6 +76,9 @@ fi %{_mandir}/man1/* %changelog +* Fri Jul 30 2021 panxiaohe - 1.16.2-3 +- Support -fno-common in vala-mix2 test + * Thu May 27 2021 yangzhuangzhuang - 1.16.2-2 - Fix test failed diff --git a/tests-support-fno-common-in-vala-mix2-test.patch b/tests-support-fno-common-in-vala-mix2-test.patch new file mode 100644 index 0000000..cff07ee --- /dev/null +++ b/tests-support-fno-common-in-vala-mix2-test.patch @@ -0,0 +1,38 @@ +From 74b9f0bbad27ae1b6ecfca7fb072cbad85a98a6b Mon Sep 17 00:00:00 2001 +From: Karl Berry +Date: Sat, 6 Jun 2020 15:47:33 -0700 +Subject: [PATCH] tests: support -fno-common in vala-mix2 test. + +This change fixes https://bugs.gnu.org/41726. + +* t/vala-mix2.sh: extern in .h, initialization in .c. +GCC 10 defaults to -fno-common. +--- + t/vala-mix2.sh | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +diff --git a/t/vala-mix2.sh b/t/vala-mix2.sh +index 8e6a214..933a3ff 100644 +--- a/t/vala-mix2.sh ++++ b/t/vala-mix2.sh +@@ -44,7 +44,7 @@ int main () + END + + cat > foo.h <<'END' +-int foo; ++extern int foo; + int bar (void); + int baz (void); + END +@@ -56,7 +56,7 @@ END + + cat > baz.c <<'END' + #include "foo.h" +-extern int foo = 0; ++int foo = 0; + int baz (void) { return 0; } + END + +-- +1.8.3.1 + -- Gitee