From 25a6332f19e64bb862a5543f7453629781b511ce Mon Sep 17 00:00:00 2001 From: David Seifert Date: Thu, 7 Jul 2022 21:56:53 +0200 Subject: sci-biology/eugene: update EAPI 6 -> 8 Closes: https://bugs.gentoo.org/829816 Signed-off-by: David Seifert --- sci-biology/eugene/eugene-4.1d-r1.ebuild | 40 ++++++++++++ sci-biology/eugene/eugene-4.1d.ebuild | 41 ------------ sci-biology/eugene/files/eugene-3.6-plugins.patch | 58 ++++++++++------- .../eugene/files/eugene-4.1d-portable-getopt.patch | 74 ++++++++++++++++++++++ 4 files changed, 148 insertions(+), 65 deletions(-) create mode 100644 sci-biology/eugene/eugene-4.1d-r1.ebuild delete mode 100644 sci-biology/eugene/eugene-4.1d.ebuild create mode 100644 sci-biology/eugene/files/eugene-4.1d-portable-getopt.patch diff --git a/sci-biology/eugene/eugene-4.1d-r1.ebuild b/sci-biology/eugene/eugene-4.1d-r1.ebuild new file mode 100644 index 000000000000..b1d9f409c096 --- /dev/null +++ b/sci-biology/eugene/eugene-4.1d-r1.ebuild @@ -0,0 +1,40 @@ +# Copyright 1999-2022 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +inherit autotools + +DESCRIPTION="Prokaryotic and Eukaryotic gene predictor" +HOMEPAGE="http://eugene.toulouse.inra.fr/" +SRC_URI="https://mulcyber.toulouse.inra.fr/frs/download.php/1359/${P}.tar.gz" + +LICENSE="Artistic" +SLOT="0" +KEYWORDS="amd64 x86" +RESTRICT="test" + +DEPEND=" + media-libs/gd[png] + media-libs/libpng:=" +RDEPEND="${DEPEND}" + +PATCHES=( + # https://mulcyber.toulouse.inra.fr/tracker/index.php?func=detail&aid=1170 + "${FILESDIR}"/${PN}-3.6-overflow.patch + "${FILESDIR}"/${PN}-3.6-plugins.patch + "${FILESDIR}"/${PN}-4.1-format-security.patch + "${FILESDIR}"/${PN}-4.1d-fix-c++14.patch + "${FILESDIR}"/${PN}-4.1d-Wformat.patch + "${FILESDIR}"/${PN}-4.1d-portable-getopt.patch +) + +src_prepare() { + default + sed \ + -e '/SUBDIRS/ s/doc//' \ + -e '/INSTALL.*doc/ s/\(.*\)//' \ + -i Makefile.am || die + rm src/getopt.h || die + eautoreconf +} diff --git a/sci-biology/eugene/eugene-4.1d.ebuild b/sci-biology/eugene/eugene-4.1d.ebuild deleted file mode 100644 index dbf8139e9e20..000000000000 --- a/sci-biology/eugene/eugene-4.1d.ebuild +++ /dev/null @@ -1,41 +0,0 @@ -# Copyright 1999-2017 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 - -EAPI=6 - -inherit autotools - -DESCRIPTION="Prokaryotic and Eukaryotic gene predictor" -HOMEPAGE="http://eugene.toulouse.inra.fr/" -SRC_URI="https://mulcyber.toulouse.inra.fr/frs/download.php/1359/${P}.tar.gz" - -LICENSE="Artistic" -SLOT="0" -KEYWORDS="amd64 x86" -IUSE="" - -DEPEND=" - media-libs/gd[png] - media-libs/libpng:0= - " -RDEPEND="${DEPEND}" - -RESTRICT="test" - -PATCHES=( - # https://mulcyber.toulouse.inra.fr/tracker/index.php?func=detail&aid=1170 - "${FILESDIR}"/${PN}-3.6-overflow.patch - "${FILESDIR}"/${PN}-3.6-plugins.patch - "${FILESDIR}"/${PN}-4.1-format-security.patch - "${FILESDIR}"/${PN}-4.1d-fix-c++14.patch - "${FILESDIR}"/${PN}-4.1d-Wformat.patch -) - -src_prepare() { - default - sed \ - -e '/SUBDIRS/ s/doc//' \ - -e '/INSTALL.*doc/ s/\(.*\)//' \ - -i Makefile.am || die - eautoreconf -} diff --git a/sci-biology/eugene/files/eugene-3.6-plugins.patch b/sci-biology/eugene/files/eugene-3.6-plugins.patch index 1e910a13d5b1..e7424f73fc63 100644 --- a/sci-biology/eugene/files/eugene-3.6-plugins.patch +++ b/sci-biology/eugene/files/eugene-3.6-plugins.patch @@ -1,7 +1,36 @@ -http://bugs.gentoo.org/show_bug.cgi?id=297536 +https://bugs.gentoo.org/297536 ---- eugene-3.6/src/Makefile.am -+++ eugene-3.6/src/Makefile.am +--- a/configure.ac ++++ b/configure.ac +@@ -28,6 +28,7 @@ + AC_PROG_CC + AC_PROG_AWK + AC_PROG_LN_S ++AM_PROG_AR + AC_PROG_RANLIB + + +--- a/Makefile.am ++++ b/Makefile.am +@@ -137,7 +137,7 @@ + $(INSTALL) -d $(DESTDIR)/$(pkgdatadir)/web/Style + $(INSTALL) -d $(DESTDIR)/$(pkgdatadir)/web/Javascripts + $(INSTALL) -d $(DESTDIR)/$(pkgdatadir)/web/Images +- $(INSTALL) -d $(DESTDIR)/$(pkgdatadir)/plugins ++ $(INSTALL) -d $(DESTDIR)/$(libdir)/eugene/plugins + $(INSTALL) -d $(DESTDIR)/$(pkgdatadir)/cfg + $(INSTALL) -d $(DESTDIR)/$(pkgdatadir)/models + $(INSTALL) -d $(DESTDIR)/$(pkgdatadir)/models/WAM +@@ -160,6 +160,6 @@ + $(INSTALL) -m 644 $(srcdir)/web/Images/*jpg $(DESTDIR)/$(pkgdatadir)/web/Images + $(INSTALL) -m 644 $(srcdir)/cfg/*.obo $(DESTDIR)/$(pkgdatadir)/cfg + $(INSTALL) -m 644 $(srcdir)/cfg/*.par $(DESTDIR)/$(pkgdatadir)/cfg +- $(INSTALL) src/SensorPlugins/*/*.so $(DESTDIR)/$(pkgdatadir)/plugins ++ $(INSTALL) src/SensorPlugins/*/*.so $(DESTDIR)/$(libdir)/eugene/plugins + $(INSTALL) $(srcdir)/Procedures/Eval/egn_* $(DESTDIR)/$(pkgdatadir)/Procedures/Eval + $(INSTALL) $(srcdir)/Procedures/Get/egn_* $(DESTDIR)/$(pkgdatadir)/Procedures/Get +--- a/src/Makefile.am ++++ b/src/Makefile.am @@ -20,7 +20,7 @@ SUBDIRS = Parametrization GDIF . SensorPlugins @@ -11,8 +40,8 @@ http://bugs.gentoo.org/show_bug.cgi?id=297536 AM_CFLAGS = bin_PROGRAMS = eugene ---- eugene-3.6/src/MSensor.cc -+++ eugene-3.6/src/MSensor.cc +--- a/src/MSensor.cc ++++ b/src/MSensor.cc @@ -97,7 +97,7 @@ std::string use_name; @@ -22,22 +51,3 @@ http://bugs.gentoo.org/show_bug.cgi?id=297536 // On récupère les couples nom de sensor/priorité du .par PAR.ResetIter(); ---- eugene-3.6/Makefile.am -+++ eugene-3.6/Makefile.am -@@ -125,7 +125,7 @@ - $(INSTALL) -d $(DESTDIR)/$(pkgdatadir)/web/Style - $(INSTALL) -d $(DESTDIR)/$(pkgdatadir)/web/Javascripts - $(INSTALL) -d $(DESTDIR)/$(pkgdatadir)/web/Images -- $(INSTALL) -d $(DESTDIR)/$(pkgdatadir)/plugins -+ $(INSTALL) -d $(DESTDIR)/$(libdir)/eugene/plugins - $(INSTALL) -d $(DESTDIR)/$(pkgdatadir)/cfg - $(INSTALL) -d $(DESTDIR)/$(pkgdatadir)/models - $(INSTALL) -d $(DESTDIR)/$(pkgdatadir)/models/WAM -@@ -144,6 +144,6 @@ - $(INSTALL) -m 644 $(srcdir)/web/Images/*jpg $(DESTDIR)/$(pkgdatadir)/web/Images - $(INSTALL) -m 644 $(srcdir)/cfg/*.obo $(DESTDIR)/$(pkgdatadir)/cfg - $(INSTALL) -m 644 $(srcdir)/cfg/*.par $(DESTDIR)/$(pkgdatadir)/cfg -- $(INSTALL) src/SensorPlugins/*/*.so $(DESTDIR)/$(pkgdatadir)/plugins -+ $(INSTALL) src/SensorPlugins/*/*.so $(DESTDIR)/$(libdir)/eugene/plugins - $(INSTALL) $(srcdir)/Procedures/Eval/egn_* $(DESTDIR)/$(pkgdatadir)/Procedures/Eval - $(INSTALL) $(srcdir)/Procedures/Get/egn_* $(DESTDIR)/$(pkgdatadir)/Procedures/Get diff --git a/sci-biology/eugene/files/eugene-4.1d-portable-getopt.patch b/sci-biology/eugene/files/eugene-4.1d-portable-getopt.patch new file mode 100644 index 000000000000..156cb4bbdfac --- /dev/null +++ b/sci-biology/eugene/files/eugene-4.1d-portable-getopt.patch @@ -0,0 +1,74 @@ +--- a/src/Param.h ++++ b/src/Param.h +@@ -28,26 +28,14 @@ + #include + #include + #include ++#include + #ifdef HAVE_STRINGS_H + #include + #endif +-// MacOS-X has getopt() defined is stdlib and the library in the libSystem +-#ifndef __APPLE__ +-#ifdef HAVE_GETOPT_H +-#include +-#else +-#ifndef HAVE_GETOPT +-#include "getopt.h" +-#endif +-#endif +-#endif + + #include "Const.h" + #include "System.h" + +-extern char *optarg; +-extern int optind; +- + + class ltstr + { +--- a/src/SensorPlugins/MarkovIMM/GetData/CEM.cc ++++ b/src/SensorPlugins/MarkovIMM/GetData/CEM.cc +@@ -22,18 +22,11 @@ + #include "../../../../config.h" + #endif + +-#ifdef HAVE_GETOPT_H +-#include +-#else +-#ifndef HAVE_GETOPT +-#include "../../../getopt.h" +-#endif +-#endif +- + #include "../../../System.cc" + #include "../../../Const.h" + #include "../../0_SensorTk/EndianConv.h" + #include "strarray.h" ++#include "unistd.h" + #include + + // Constantes +--- a/src/SensorPlugins/MarkovIMM/GetData/TrainIMM.cc ++++ b/src/SensorPlugins/MarkovIMM/GetData/TrainIMM.cc +@@ -22,18 +22,11 @@ + #include "../../../../config.h" + #endif + +-#ifdef HAVE_GETOPT_H +-#include +-#else +-#ifndef HAVE_GETOPT +-#include "../../../getopt.h" +-#endif +-#endif +- + #include "../../../System.cc" + #include "../../../Const.h" + #include "../../0_SensorTk/EndianConv.h" + #include "strarray.h" ++#include "unistd.h" + + + // Constantes -- cgit v1.2.3-65-gdbad