From: "Sam James" <sam@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] repo/gentoo:master commit in: dev-util/gperf/files/, dev-util/gperf/
Date: Thu, 8 Sep 2022 03:17:30 +0000 (UTC) [thread overview]
Message-ID: <1662607039.c9c6ed9355576ee71fee1988a08ec9258162a1d4.sam@gentoo> (raw)
commit: c9c6ed9355576ee71fee1988a08ec9258162a1d4
Author: Sam James <sam <AT> gentoo <DOT> org>
AuthorDate: Thu Sep 8 03:17:19 2022 +0000
Commit: Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Thu Sep 8 03:17:19 2022 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=c9c6ed93
dev-util/gperf: fix strncmp declaration
Closes: https://bugs.gentoo.org/869134
Signed-off-by: Sam James <sam <AT> gentoo.org>
.../files/gperf-3.1-strncmp-decl-mismatch.patch | 28 ++++++++++++++++++++++
dev-util/gperf/gperf-3.1-r1.ebuild | 24 +++++++++++++++++++
2 files changed, 52 insertions(+)
diff --git a/dev-util/gperf/files/gperf-3.1-strncmp-decl-mismatch.patch b/dev-util/gperf/files/gperf-3.1-strncmp-decl-mismatch.patch
new file mode 100644
index 000000000000..67380fb0279c
--- /dev/null
+++ b/dev-util/gperf/files/gperf-3.1-strncmp-decl-mismatch.patch
@@ -0,0 +1,28 @@
+https://bugs.gentoo.org/869134
+
+From 09844ce4ca3d5975469640cea9c5414d5c0baa44 Mon Sep 17 00:00:00 2001
+From: Bruno Haible <bruno@clisp.org>
+Date: Thu, 8 Sep 2022 04:45:03 +0200
+Subject: [PATCH] Fix a warning regarding strncmp.
+
+Reported by Sam James in <https://savannah.gnu.org/bugs/?63031>.
+
+* lib/getopt.c (strncmp): Declare with a prototype.
+--- a/lib/getopt.c
++++ b/lib/getopt.c
+@@ -194,7 +194,6 @@ static char *posixly_correct;
+ whose names are inconsistent. */
+
+ extern char *getenv ();
+-extern int strncmp ();
+
+ static char *
+ my_index (const char *str, int chr)
+@@ -209,6 +208,7 @@ my_index (const char *str, int chr)
+ }
+
+ extern int strcmp (const char *, const char *);
++extern int strncmp (const char *, const char *, size_t);
+ extern size_t strlen (const char *);
+
+ #endif /* not __GNU_LIBRARY__ */
diff --git a/dev-util/gperf/gperf-3.1-r1.ebuild b/dev-util/gperf/gperf-3.1-r1.ebuild
new file mode 100644
index 000000000000..bdabce4d841e
--- /dev/null
+++ b/dev-util/gperf/gperf-3.1-r1.ebuild
@@ -0,0 +1,24 @@
+# Copyright 1999-2022 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+DESCRIPTION="A perfect hash function generator"
+HOMEPAGE="https://www.gnu.org/software/gperf/"
+SRC_URI="mirror://gnu/gperf/${P}.tar.gz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~x64-cygwin ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris ~x86-winnt"
+
+PATCHES=(
+ "${FILESDIR}"/${P}-strncmp-decl-mismatch.patch
+)
+
+src_prepare() {
+ sed -i \
+ -e "/^CPPFLAGS /s:=:+=:" \
+ */Makefile.in || die #444078
+
+ default
+}
next reply other threads:[~2022-09-08 3:17 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-09-08 3:17 Sam James [this message]
-- strict thread matches above, loose matches on Subject: below --
2022-12-06 9:31 [gentoo-commits] repo/gentoo:master commit in: dev-util/gperf/files/, dev-util/gperf/ Sam James
2025-04-09 14:47 Sam James
2025-04-17 1:44 Sam James
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1662607039.c9c6ed9355576ee71fee1988a08ec9258162a1d4.sam@gentoo \
--to=sam@gentoo.org \
--cc=gentoo-commits@lists.gentoo.org \
--cc=gentoo-dev@lists.gentoo.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox