sci-biology/maq: Modernise to EAPI 6
authorDavid Seifert <soap@gentoo.org>
Mon, 6 Feb 2017 20:48:02 +0000 (21:48 +0100)
committerDavid Seifert <soap@gentoo.org>
Mon, 6 Feb 2017 21:26:35 +0000 (22:26 +0100)
Package-Manager: Portage-2.3.3, Repoman-2.3.1
Closes: https://github.com/gentoo/gentoo/pull/3856

sci-biology/maq/files/maq-0.7.1-remove-64bit-flag.patch [new file with mode: 0644]
sci-biology/maq/maq-0.7.1-r2.ebuild [new file with mode: 0644]

diff --git a/sci-biology/maq/files/maq-0.7.1-remove-64bit-flag.patch b/sci-biology/maq/files/maq-0.7.1-remove-64bit-flag.patch
new file mode 100644 (file)
index 0000000..3bcbc2b
--- /dev/null
@@ -0,0 +1,19 @@
+Do not hardcode -m64 into the build system
+
+--- a/configure.ac
++++ b/configure.ac
+@@ -21,12 +21,12 @@
+                                                  [ext_CFLAGS="-arch x86_64 -arch i386 -arch ppc64 -arch ppc"],
+                                                  [ext_CFLAGS="-arch i386 -arch ppc"]);;
+         0) CFLAGS="-m64"
+-               AC_COMPILE_IFELSE([AC_LANG_PROGRAM], [ext_CFLAGS="-m64"], []);;
++               AC_COMPILE_IFELSE([AC_LANG_PROGRAM], [ext_CFLAGS=""], []);;
+       esac;;
+   *)
+     AC_MSG_CHECKING([if gcc accepts -m64])
+     CFLAGS="-m64"
+-    AC_COMPILE_IFELSE([AC_LANG_PROGRAM], [ext_CFLAGS="-m64"; AC_MSG_RESULT([yes])],
++    AC_COMPILE_IFELSE([AC_LANG_PROGRAM], [ext_CFLAGS=""; AC_MSG_RESULT([yes])],
+                                         [ext_CFLAGS="-D_FILE_OFFSET_BITS=64"; AC_MSG_RESULT([no])]);;
+ esac
+ AC_ARG_ENABLE(experimental, [  --enable-experimental   enable experimental features],
diff --git a/sci-biology/maq/maq-0.7.1-r2.ebuild b/sci-biology/maq/maq-0.7.1-r2.ebuild
new file mode 100644 (file)
index 0000000..fb01400
--- /dev/null
@@ -0,0 +1,43 @@
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=6
+
+inherit autotools
+
+DESCRIPTION="Mapping and Assembly with Qualities, mapping NGS reads to reference genomes"
+HOMEPAGE="http://maq.sourceforge.net/"
+SRC_URI="
+       mirror://sourceforge/${PN}/${P}.tar.bz2
+       mirror://sourceforge/${PN}/calib-36.dat.gz"
+
+LICENSE="GPL-3"
+SLOT="0"
+IUSE=""
+KEYWORDS="~amd64 ~x86 ~amd64-linux ~x86-linux"
+
+RDEPEND="sys-libs/zlib"
+DEPEND="${RDEPEND}"
+
+PATCHES=(
+       "${FILESDIR}"/${P}-flags.patch
+       "${FILESDIR}"/${P}-bfr-overfl.patch
+       "${FILESDIR}"/${P}-gcc-4.7.patch
+       "${FILESDIR}"/${P}-remove-64bit-flag.patch
+)
+
+src_prepare() {
+       default
+       eautoreconf
+}
+
+src_install() {
+       default
+
+       insinto /usr/share/${PN}
+       doins "${WORKDIR}"/*.dat
+
+       doman maq.1
+       dodoc ${PN}.pdf
+}