From 836dfe489e3087ef00970829697777315ec1f7f6 Mon Sep 17 00:00:00 2001 From: Sam James Date: Thu, 20 Apr 2023 23:28:33 +0100 Subject: dev-libs/libmcrypt: fix -Wimplicit-int Signed-off-by: Sam James --- .../files/libmcrypt-2.5.8-implicit-int.patch | 31 ++++++++++++++++ dev-libs/libmcrypt/libmcrypt-2.5.8-r5.ebuild | 41 --------------------- dev-libs/libmcrypt/libmcrypt-2.5.8-r6.ebuild | 42 ++++++++++++++++++++++ 3 files changed, 73 insertions(+), 41 deletions(-) create mode 100644 dev-libs/libmcrypt/files/libmcrypt-2.5.8-implicit-int.patch delete mode 100644 dev-libs/libmcrypt/libmcrypt-2.5.8-r5.ebuild create mode 100644 dev-libs/libmcrypt/libmcrypt-2.5.8-r6.ebuild (limited to 'dev-libs') 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-r5.ebuild deleted file mode 100644 index 54637cd96a4f..000000000000 --- a/dev-libs/libmcrypt/libmcrypt-2.5.8-r5.ebuild +++ /dev/null @@ -1,41 +0,0 @@ -# Copyright 1999-2022 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=8 - -inherit autotools - -DESCRIPTION="Provides an uniform interface to access several encryption algorithms" -HOMEPAGE="https://mcrypt.sourceforge.net" -SRC_URI="mirror://sourceforge/mcrypt/${P}.tar.gz" - -LICENSE="GPL-2+ LGPL-2.1+" -SLOT="0" -KEYWORDS="~alpha amd64 ~arm ~arm64 ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 sparc x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~sparc-solaris ~x86-solaris" - -DOCS=( - AUTHORS NEWS README THANKS TODO ChangeLog - doc/README.config doc/README.key doc/README.xtea - doc/example.c -) - -PATCHES=( - "${FILESDIR}/${P}-rotate-mask.patch" - "${FILESDIR}/${P}-autoconf-2.70.patch" #775113 - # http://sourceforge.net/tracker/index.php?func=detail&aid=1872801&group_id=87941&atid=584895 - "${FILESDIR}/${P}-uninitialized.patch" - "${FILESDIR}/${P}-prototypes.patch" -) - -src_prepare() { - default - mv configure.in configure.ac - mv libltdl/configure.in libltdl/configure.ac - sed -i 's/AM_CONFIG_HEADER/AC_CONFIG_HEADERS/g' configure.ac libltdl/configure.ac || die - eautoreconf # need new libtool for interix (elibtoolize would suffice for freebsd) -} - -src_install() { - default - find "${ED}" -type f -name '*.la' -delete || die -} diff --git a/dev-libs/libmcrypt/libmcrypt-2.5.8-r6.ebuild b/dev-libs/libmcrypt/libmcrypt-2.5.8-r6.ebuild new file mode 100644 index 000000000000..3f96b287c0eb --- /dev/null +++ b/dev-libs/libmcrypt/libmcrypt-2.5.8-r6.ebuild @@ -0,0 +1,42 @@ +# Copyright 1999-2023 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +inherit autotools + +DESCRIPTION="Provides an uniform interface to access several encryption algorithms" +HOMEPAGE="https://mcrypt.sourceforge.net" +SRC_URI="mirror://sourceforge/mcrypt/${P}.tar.gz" + +LICENSE="GPL-2+ LGPL-2.1+" +SLOT="0" +KEYWORDS="~alpha amd64 ~arm ~arm64 ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 sparc x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~sparc-solaris ~x86-solaris" + +DOCS=( + AUTHORS NEWS README THANKS TODO ChangeLog + doc/README.config doc/README.key doc/README.xtea + doc/example.c +) + +PATCHES=( + "${FILESDIR}/${P}-rotate-mask.patch" + "${FILESDIR}/${P}-autoconf-2.70.patch" #775113 + # 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() { + default + mv configure.in configure.ac + mv libltdl/configure.in libltdl/configure.ac + sed -i 's/AM_CONFIG_HEADER/AC_CONFIG_HEADERS/g' configure.ac libltdl/configure.ac || die + eautoreconf # need new libtool for interix (elibtoolize would suffice for freebsd) +} + +src_install() { + default + find "${ED}" -type f -name '*.la' -delete || die +} -- cgit v1.2.3-65-gdbad