From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id 92B20158020 for ; Fri, 18 Nov 2022 01:03:07 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id C0DFCE0928; Fri, 18 Nov 2022 01:03:06 +0000 (UTC) Received: from smtp.gentoo.org (dev.gentoo.org [IPv6:2001:470:ea4a:1:5054:ff:fec7:86e4]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id A3752E0928 for ; Fri, 18 Nov 2022 01:03:06 +0000 (UTC) Received: from oystercatcher.gentoo.org (oystercatcher.gentoo.org [148.251.78.52]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id AE303340D8B for ; Fri, 18 Nov 2022 01:03:05 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id 04F3573E for ; Fri, 18 Nov 2022 01:03:04 +0000 (UTC) From: "Sam James" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Sam James" Message-ID: <1668733324.cc030538dc51e0bccceea9372bfab68cda588b8c.sam@gentoo> Subject: [gentoo-commits] repo/gentoo:master commit in: sys-devel/autoconf/, sys-devel/autoconf/files/ X-VCS-Repository: repo/gentoo X-VCS-Files: sys-devel/autoconf/autoconf-2.71-r4.ebuild sys-devel/autoconf/autoconf-2.71-r5.ebuild sys-devel/autoconf/files/autoconf-2.13-K-R-decls-clang.patch sys-devel/autoconf/files/autoconf-2.71-K-R-decls-clang-deux.patch sys-devel/autoconf/files/autoconf-2.71-K-R-decls-clang.patch X-VCS-Directories: sys-devel/autoconf/files/ sys-devel/autoconf/ X-VCS-Committer: sam X-VCS-Committer-Name: Sam James X-VCS-Revision: cc030538dc51e0bccceea9372bfab68cda588b8c X-VCS-Branch: master Date: Fri, 18 Nov 2022 01:03:04 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply X-Archives-Salt: dbe107f1-5fdc-44ae-b8a8-eed8dc498b85 X-Archives-Hash: 6c96ee8c08d0bcc99f4a5ed3e6a06d20 commit: cc030538dc51e0bccceea9372bfab68cda588b8c Author: Sam James gentoo org> AuthorDate: Fri Nov 18 00:55:29 2022 +0000 Commit: Sam James gentoo org> CommitDate: Fri Nov 18 01:02:04 2022 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=cc030538 sys-devel/autoconf: backport further Clang 16 fixes (2.71) Bug: https://bugs.gentoo.org/870412 Signed-off-by: Sam James gentoo.org> ...conf-2.71-r4.ebuild => autoconf-2.71-r5.ebuild} | 1 + .../files/autoconf-2.13-K-R-decls-clang.patch | 2 +- .../files/autoconf-2.71-K-R-decls-clang-deux.patch | 94 ++++++++++++++++++++++ .../files/autoconf-2.71-K-R-decls-clang.patch | 2 +- 4 files changed, 97 insertions(+), 2 deletions(-) diff --git a/sys-devel/autoconf/autoconf-2.71-r4.ebuild b/sys-devel/autoconf/autoconf-2.71-r5.ebuild similarity index 98% rename from sys-devel/autoconf/autoconf-2.71-r4.ebuild rename to sys-devel/autoconf/autoconf-2.71-r5.ebuild index 225cfc50a50f..3ecf3ddc5979 100644 --- a/sys-devel/autoconf/autoconf-2.71-r4.ebuild +++ b/sys-devel/autoconf/autoconf-2.71-r5.ebuild @@ -47,6 +47,7 @@ PATCHES=( "${FILESDIR}"/${P}-AC_C_BIGENDIAN-lto.patch "${FILESDIR}"/${P}-K-R-decls-clang.patch "${FILESDIR}"/${P}-make-4.4.patch + "${FILESDIR}"/${P}-K-R-decls-clang-deux.patch ) src_prepare() { diff --git a/sys-devel/autoconf/files/autoconf-2.13-K-R-decls-clang.patch b/sys-devel/autoconf/files/autoconf-2.13-K-R-decls-clang.patch index 874712cea102..42c3018aea8c 100644 --- a/sys-devel/autoconf/files/autoconf-2.13-K-R-decls-clang.patch +++ b/sys-devel/autoconf/files/autoconf-2.13-K-R-decls-clang.patch @@ -1,7 +1,7 @@ https://bugs.gentoo.org/870412 https://git.savannah.gnu.org/cgit/autoconf.git/commit/?id=8b5e2016c7ed2d67f31b03a3d2e361858ff5299b -Backport the K&R decls fix to 2.69 to avoid configure tests +Backport the K&R decls fix to 2.13 to avoid configure tests failing (often "silently", i.e. doesn't fail the build of the package overall, just leads to wrong results) with newer compilers like the upcoming Clang 16. diff --git a/sys-devel/autoconf/files/autoconf-2.71-K-R-decls-clang-deux.patch b/sys-devel/autoconf/files/autoconf-2.71-K-R-decls-clang-deux.patch new file mode 100644 index 000000000000..6a3d6580a3f6 --- /dev/null +++ b/sys-devel/autoconf/files/autoconf-2.71-K-R-decls-clang-deux.patch @@ -0,0 +1,94 @@ +https://bugs.gentoo.org/870412 +https://git.savannah.gnu.org/cgit/autoconf.git/commit/?id=bf5a75953b6d504f0405b1ca33b039b8dd39eef4 + +Backport the K&R decls fix to 2.71 to avoid configure tests +failing (often "silently", i.e. doesn't fail the build of +the package overall, just leads to wrong results) with +newer compilers like the upcoming Clang 16. + +From bf5a75953b6d504f0405b1ca33b039b8dd39eef4 Mon Sep 17 00:00:00 2001 +From: Zack Weinberg +Date: Thu, 10 Nov 2022 12:05:30 -0500 +Subject: More fixes for compilers that reject K&R function definitions. +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +This fixes all of the remaining failures exposed by running the +testsuite with GCC 12 and +CC='cc -Wimplicit-function-declaration -Wold-style-definition + -Wimplicit-int -Werror' +. + +* lib/autoconf/c.m4 (_AC_C_C89_TEST_GLOBALS): Don’t use K&R function + definitions. +* lib/autoconf/specific.m4 (AC_SYS_RESTARTABLE_SYSCALLS): Likewise. + (AC_FUNC_MKTIME): Declare functions taking no arguments as ‘fn (void)’ + not ‘fn ()’. +* lib/autoconf/c.m4 (_AC_C_C99_TEST_GLOBALS): Declare free(). +--- a/lib/autoconf/c.m4 ++++ b/lib/autoconf/c.m4 +@@ -1153,9 +1153,7 @@ struct stat; + /* Most of the following tests are stolen from RCS 5.7 src/conf.sh. */ + struct buf { int x; }; + struct buf * (*rcsopen) (struct buf *, struct stat *, int); +-static char *e (p, i) +- char **p; +- int i; ++static char *e (char **p, int i) + { + return p[i]; + } +@@ -1212,6 +1210,7 @@ extern int puts (const char *); + extern int printf (const char *, ...); + extern int dprintf (int, const char *, ...); + extern void *malloc (size_t); ++extern void free (void *); + + // Check varargs macros. These examples are taken from C99 6.10.3.5. + // dprintf is used instead of fprintf to avoid needing to declare +--- a/lib/autoconf/functions.m4 ++++ b/lib/autoconf/functions.m4 +@@ -1091,7 +1091,7 @@ static const char *tz_strings[] = { + /* Return 0 if mktime fails to convert a date in the spring-forward gap. + Based on a problem report from Andreas Jaeger. */ + static int +-spring_forward_gap () ++spring_forward_gap (void) + { + /* glibc (up to about 1998-10-07) failed this test. */ + struct tm tm; +@@ -1128,7 +1128,7 @@ mktime_test (time_t now) + } + + static int +-irix_6_4_bug () ++irix_6_4_bug (void) + { + /* Based on code from Ariel Faigon. */ + struct tm tm; +@@ -1170,7 +1170,7 @@ bigtime_test (int j) + } + + static int +-year_2050_test () ++year_2050_test (void) + { + /* The correct answer for 2050-02-01 00:00:00 in Pacific time, + ignoring leap seconds. */ +--- a/lib/autoconf/specific.m4 ++++ b/lib/autoconf/specific.m4 +@@ -361,10 +361,9 @@ AC_INCLUDES_DEFAULT + /* Some platforms explicitly require an extern "C" signal handler + when using C++. */ + #ifdef __cplusplus +-extern "C" void ucatch (int dummy) { } +-#else +-void ucatch (dummy) int dummy; { } ++extern "C" + #endif ++void ucatch (int dummy) { } + + int + main (void) +cgit v1.1 diff --git a/sys-devel/autoconf/files/autoconf-2.71-K-R-decls-clang.patch b/sys-devel/autoconf/files/autoconf-2.71-K-R-decls-clang.patch index 33cb728695bb..e2e451e86920 100644 --- a/sys-devel/autoconf/files/autoconf-2.71-K-R-decls-clang.patch +++ b/sys-devel/autoconf/files/autoconf-2.71-K-R-decls-clang.patch @@ -1,7 +1,7 @@ https://bugs.gentoo.org/870412 https://git.savannah.gnu.org/cgit/autoconf.git/commit/?id=8b5e2016c7ed2d67f31b03a3d2e361858ff5299b -Backport the K&R decls fix to 2.69 to avoid configure tests +Backport the K&R decls fix to 2.71 to avoid configure tests failing (often "silently", i.e. doesn't fail the build of the package overall, just leads to wrong results) with newer compilers like the upcoming Clang 16.