summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSam James <sam@gentoo.org>2023-04-20 23:28:33 +0100
committerSam James <sam@gentoo.org>2023-04-20 23:29:55 +0100
commit836dfe489e3087ef00970829697777315ec1f7f6 (patch)
treef29ee680b810f7a627d50a046a0d3fa99d1319bb /dev-libs
parentdev-python/matplotlib: Stabilize 3.7.1 x86, #880781 (diff)
downloadgentoo-836dfe489e3087ef00970829697777315ec1f7f6.tar.gz
gentoo-836dfe489e3087ef00970829697777315ec1f7f6.tar.bz2
gentoo-836dfe489e3087ef00970829697777315ec1f7f6.zip
dev-libs/libmcrypt: fix -Wimplicit-int
Signed-off-by: Sam James <sam@gentoo.org>
Diffstat (limited to 'dev-libs')
-rw-r--r--dev-libs/libmcrypt/files/libmcrypt-2.5.8-implicit-int.patch31
-rw-r--r--dev-libs/libmcrypt/libmcrypt-2.5.8-r6.ebuild (renamed from dev-libs/libmcrypt/libmcrypt-2.5.8-r5.ebuild)3
2 files changed, 33 insertions, 1 deletions
diff --git a/dev-libs/libmcrypt/files/libmcrypt-2.5.8-implicit-int.patch b/dev-libs/libmcrypt/files/libmcrypt-2.5.8-implicit-int.patch
new file mode 100644
index 000000000000..f504014011e3
--- /dev/null
+++ b/dev-libs/libmcrypt/files/libmcrypt-2.5.8-implicit-int.patch
@@ -0,0 +1,31 @@
+Add return and argument types to fake prototypes in mcrypt_symb.c.
+This avoids build failures with future compilers that do not support
+implicit function declarations.
+
+--- a/lib/Makefile.am
++++ b/lib/Makefile.am
+@@ -23,8 +23,8 @@ mcrypt_symb.c: mcrypt_internal.h
+ @echo "/* This is automatically created. Don't touch... */" >> mcrypt_symb.c
+ @echo "" >> mcrypt_symb.c
+ -@for i in $(EXTRA_ALGOS); do \
+- if test -f ../modules/algorithms/$$i.c; then cat ../modules/algorithms/$$i.c 2>/dev/null|grep define|grep LTX|awk '{print "extern "$$3"();";}' >> mcrypt_symb.c 2>/dev/null; fi; \
+- if test -f ../modules/modes/$$i.c; then cat ../modules/modes/$$i.c 2>/dev/null|grep define|grep LTX|awk '{print "extern "$$3"();";}' >> mcrypt_symb.c 2>/dev/null; fi; \
++ if test -f ../modules/algorithms/$$i.c; then cat ../modules/algorithms/$$i.c 2>/dev/null|grep define|grep LTX|awk '{print "extern void "$$3"(void);";}' >> mcrypt_symb.c 2>/dev/null; fi; \
++ if test -f ../modules/modes/$$i.c; then cat ../modules/modes/$$i.c 2>/dev/null|grep define|grep LTX|awk '{print "extern void "$$3"(void);";}' >> mcrypt_symb.c 2>/dev/null; fi; \
+ done
+ @echo "" >> mcrypt_symb.c
+ @echo "const mcrypt_preloaded mps[] = {" >> mcrypt_symb.c
+--- a/lib/Makefile.in
++++ b/lib/Makefile.in
+@@ -561,8 +561,8 @@ mcrypt_symb.c: mcrypt_internal.h
+ @echo "/* This is automatically created. Don't touch... */" >> mcrypt_symb.c
+ @echo "" >> mcrypt_symb.c
+ -@for i in $(EXTRA_ALGOS); do \
+- if test -f ../modules/algorithms/$$i.c; then cat ../modules/algorithms/$$i.c 2>/dev/null|grep define|grep LTX|awk '{print "extern "$$3"();";}' >> mcrypt_symb.c 2>/dev/null; fi; \
+- if test -f ../modules/modes/$$i.c; then cat ../modules/modes/$$i.c 2>/dev/null|grep define|grep LTX|awk '{print "extern "$$3"();";}' >> mcrypt_symb.c 2>/dev/null; fi; \
++ if test -f ../modules/algorithms/$$i.c; then cat ../modules/algorithms/$$i.c 2>/dev/null|grep define|grep LTX|awk '{print "extern void "$$3"(void);";}' >> mcrypt_symb.c 2>/dev/null; fi; \
++ if test -f ../modules/modes/$$i.c; then cat ../modules/modes/$$i.c 2>/dev/null|grep define|grep LTX|awk '{print "extern void "$$3"(void);";}' >> mcrypt_symb.c 2>/dev/null; fi; \
+ done
+ @echo "" >> mcrypt_symb.c
+ @echo "const mcrypt_preloaded mps[] = {" >> mcrypt_symb.c
+
diff --git a/dev-libs/libmcrypt/libmcrypt-2.5.8-r5.ebuild b/dev-libs/libmcrypt/libmcrypt-2.5.8-r6.ebuild
index 54637cd96a4f..3f96b287c0eb 100644
--- a/dev-libs/libmcrypt/libmcrypt-2.5.8-r5.ebuild
+++ b/dev-libs/libmcrypt/libmcrypt-2.5.8-r6.ebuild
@@ -1,4 +1,4 @@
-# Copyright 1999-2022 Gentoo Authors
+# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
@@ -25,6 +25,7 @@ PATCHES=(
# http://sourceforge.net/tracker/index.php?func=detail&aid=1872801&group_id=87941&atid=584895
"${FILESDIR}/${P}-uninitialized.patch"
"${FILESDIR}/${P}-prototypes.patch"
+ "${FILESDIR}/${P}-implicit-int.patch"
)
src_prepare() {