Gentoo Archives: gentoo-commits

From: Martin Mokrejs <mmokrejs@×××××××××××××××.cz>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] proj/sci:master commit in: sci-biology/amos/, sci-biology/amos/files/
Date: Tue, 31 Mar 2015 20:19:10
Message-Id: 1427833118.8e3157e581a2503912b86bb5e48fb73e82c26cc9.mmokrejs@gentoo
1 commit: 8e3157e581a2503912b86bb5e48fb73e82c26cc9
2 Author: Martin Mokrejš <mmokrejs <AT> fold <DOT> natur <DOT> cuni <DOT> cz>
3 AuthorDate: Tue Mar 31 20:18:38 2015 +0000
4 Commit: Martin Mokrejs <mmokrejs <AT> fold <DOT> natur <DOT> cuni <DOT> cz>
5 CommitDate: Tue Mar 31 20:18:38 2015 +0000
6 URL: https://gitweb.gentoo.org/proj/sci.git/commit/?id=8e3157e5
7
8 sci-biology/amos: fix installation process and dependencies
9
10 Package-Manager: portage-2.2.18
11
12 sci-biology/amos/ChangeLog | 9 ++-
13 sci-biology/amos/amos-3.1.0-r2.ebuild | 66 ++++++++++++++++++++++
14 sci-biology/amos/amos-9999.ebuild | 27 ++++++++-
15 sci-biology/amos/files/amos-3.1.0-gcc-4.7.patch | 15 +++++
16 ...mos-3.1.0-goBambus2.py-indent-and-cleanup.patch | 25 ++++++++
17 5 files changed, 138 insertions(+), 4 deletions(-)
18
19 diff --git a/sci-biology/amos/ChangeLog b/sci-biology/amos/ChangeLog
20 index 7d1df6d..9bdce77 100644
21 --- a/sci-biology/amos/ChangeLog
22 +++ b/sci-biology/amos/ChangeLog
23 @@ -1,7 +1,14 @@
24 # ChangeLog for sci-biology/amos
25 -# Copyright 1999-2013 Gentoo Foundation; Distributed under the GPL v2
26 +# Copyright 1999-2015 Gentoo Foundation; Distributed under the GPL v2
27 # $Header: $
28
29 +*amos-3.1.0-r2 (31 Mar 2015)
30 +
31 + 31 Mar 2015; Martin Mokrejs <mmokrejs@×××××××××××××××.cz>
32 + +amos-3.1.0-r2.ebuild, +files/amos-3.1.0-gcc-4.7.patch,
33 + +files/amos-3.1.0-goBambus2.py-indent-and-cleanup.patch, amos-9999.ebuild:
34 + sci-biology/amos: fix installation process and dependencies
35 +
36 29 Dec 2013; Justin Lecher <jlec@g.o> -amos-3.1.0-r1.ebuild,
37 amos-9999.ebuild, -files/amos-3.1.0-gcc-4.7.patch,
38 -files/amos-3.1.0-goBambus2.py-indent-and-cleanup.patch,
39
40 diff --git a/sci-biology/amos/amos-3.1.0-r2.ebuild b/sci-biology/amos/amos-3.1.0-r2.ebuild
41 new file mode 100644
42 index 0000000..b814791
43 --- /dev/null
44 +++ b/sci-biology/amos/amos-3.1.0-r2.ebuild
45 @@ -0,0 +1,66 @@
46 +# Copyright 1999-2015 Gentoo Foundation
47 +# Distributed under the terms of the GNU General Public License v2
48 +# $Header: /var/cvsroot/gentoo-x86/sci-biology/amos/amos-3.1.0-r1.ebuild,v 1.1 2013/12/29 00:24:16 jlec Exp $
49 +
50 +EAPI=5
51 +
52 +PYTHON_COMPAT=( python{2_6,2_7} )
53 +
54 +inherit eutils python-r1
55 +
56 +DESCRIPTION="A Modular, Open-Source whole genome assembler"
57 +HOMEPAGE="http://amos.sourceforge.net/"
58 +SRC_URI="mirror://sourceforge/${PN}/${P}.tar.gz"
59 +
60 +LICENSE="Artistic"
61 +SLOT="0"
62 +KEYWORDS="~amd64 ~x86"
63 +IUSE="qt4"
64 +
65 +DEPEND="
66 + dev-libs/boost
67 + qt4? ( dev-qt/qtcore:4 )"
68 +RDEPEND="${DEPEND}
69 + dev-lang/perl
70 + dev-perl/DBI
71 + dev-perl/Statistics-Descriptive
72 + sci-biology/blat
73 + sci-biology/mummer"
74 +
75 +MAKEOPTS+=" -j1"
76 +
77 +src_prepare() {
78 + epatch \
79 + "${FILESDIR}"/${P}-gcc-4.7.patch \
80 + "${FILESDIR}"/${P}-goBambus2.py-indent-and-cleanup.patch
81 +}
82 +
83 +# amos-3.1.0-r2/work/amos-3.1.0/src/Bambus/Untangler/DotLib.pm
84 +# amos-3.1.0-r2/work/amos-3.1.0/src/Bambus/Untangler/AsmLib.pm
85 +# amos-3.1.0-r2/work/amos-3.1.0/src/PerlModules/FASTAreader.pm
86 +# amos-3.1.0-r2/work/amos-3.1.0/src/PerlModules/AmosFoundation.pm
87 +# amos-3.1.0-r2/work/amos-3.1.0/src/PerlModules/Foundation.pm
88 +# amos-3.1.0-r2/work/amos-3.1.0/src/PerlModules/AmosLib.pm
89 +# amos-3.1.0-r2/work/amos-3.1.0/src/PerlModules/FASTArecord.pm
90 +# amos-3.1.0-r2/work/amos-3.1.0/src/PerlModules/ParseFasta.pm
91 +# amos-3.1.0-r2/work/amos-3.1.0/src/PerlModules/xfig.pm
92 +# amos-3.1.0-r2/work/amos-3.1.0/src/PerlModules/FASTAwriter.pm
93 +# amos-3.1.0-r2/work/amos-3.1.0/src/PerlModules/FASTAgrammar.pm
94 +# amos-3.1.0-r2/work/amos-3.1.0/src/PerlModules/FASTAiterator.pm
95 +
96 +# --with-jellyfish location of Jellyfish headers
97 +
98 +src_install() {
99 + default
100 + python_replicate_script "${ED}"/usr/bin/goBambus2
101 + # bambus needs TIGR::FASTAreader.pm and others
102 + # configure --libdir sadly copies both *.a files and *.pm into /usr/lib64/AMOS/ and /usr/lib64/TIGR/, work around it
103 + mkdir -p "${D}"/usr/share/"${PN}"/perl/AMOS || die
104 + mv "${D}"/usr/lib64/AMOS/*.pm "${D}"/usr/share/"${PN}"/perl/AMOS || die
105 + mkdir -p "${D}"/usr/share/"${PN}"/perl/TIGR || die
106 + mv "${D}"/usr/lib64/TIGR/*.pm "${D}"/usr/share/"${PN}"/perl/TIGR || die
107 + echo "PERL5LIB=/usr/share/${PN}/perl" > "${S}/99${PN}"
108 + doenvd "${S}/99${PN}" || die
109 + # move also /usr/lib64/AMOS/AMOS.py to /usr/bin
110 + mv "${D}"/usr/lib64/AMOS/*.py "${D}"/usr/bin || die
111 +}
112
113 diff --git a/sci-biology/amos/amos-9999.ebuild b/sci-biology/amos/amos-9999.ebuild
114 index baecc2f..610c3d6 100644
115 --- a/sci-biology/amos/amos-9999.ebuild
116 +++ b/sci-biology/amos/amos-9999.ebuild
117 @@ -1,4 +1,4 @@
118 -# Copyright 1999-2014 Gentoo Foundation
119 +# Copyright 1999-2015 Gentoo Foundation
120 # Distributed under the terms of the GNU General Public License v2
121 # $Header: $
122
123 @@ -16,11 +16,32 @@ EGIT_REPO_URI="git://amos.git.sourceforge.net/gitroot/amos/amos"
124 LICENSE="Artistic"
125 SLOT="0"
126 KEYWORDS=""
127 -IUSE=""
128 +IUSE="mpi qt4"
129
130 DEPEND="
131 + mpi? ( virtual/mpi )
132 dev-libs/boost
133 - dev-qt/qtcore:4"
134 + qt4? ( dev-qt/qtcore:4 )
135 + sci-biology/blat
136 + sci-biology/jellyfish"
137 RDEPEND="${DEPEND}
138 dev-perl/DBI
139 + dev-perl/Statistics-Descriptive
140 sci-biology/mummer"
141 +
142 +# --with-jellyfish location of Jellyfish headers
143 +
144 +src_install() {
145 + default
146 + python_replicate_script "${ED}"/usr/bin/goBambus2
147 + # bambus needs TIGR::FASTAreader.pm and others
148 + # configure --libdir sadly copies both *.a files and *.pm into /usr/lib64/AMOS/ and /usr/lib64/TIGR/, work around it
149 + mkdir -p "${D}/usr/share/${PN}/perl/AMOS" || die
150 + mv "${D}"/usr/lib64/AMOS/*.pm "${D}/usr/share/${PN}/perl/AMOS" || die
151 + mkdir -p "${D}"/usr/share/"${PN}"/perl/TIGR || die
152 + mv "${D}"/usr/lib64/TIGR/*.pm "${D}"/usr/share/"${PN}"/perl/TIGR || die
153 + echo "PERL5LIB=/usr/share/${PN}/perl" > "${S}/99${PN}"
154 + doenvd "${S}/99${PN}" || die
155 + # move also /usr/lib64/AMOS/AMOS.py to /usr/bin
156 + mv "${D}"/usr/lib64/AMOS/*.py "${D}"/usr/bin || die
157 +}
158
159 diff --git a/sci-biology/amos/files/amos-3.1.0-gcc-4.7.patch b/sci-biology/amos/files/amos-3.1.0-gcc-4.7.patch
160 new file mode 100644
161 index 0000000..de2a411
162 --- /dev/null
163 +++ b/sci-biology/amos/files/amos-3.1.0-gcc-4.7.patch
164 @@ -0,0 +1,15 @@
165 + src/Align/find-tandem.cc | 1 +
166 + 1 files changed, 1 insertions(+), 0 deletions(-)
167 +
168 +diff --git a/src/Align/find-tandem.cc b/src/Align/find-tandem.cc
169 +index ddf1cab..a29e21e 100644
170 +--- a/src/Align/find-tandem.cc
171 ++++ b/src/Align/find-tandem.cc
172 +@@ -7,6 +7,7 @@
173 + #include <vector>
174 + #include <ctime>
175 + #include <sys/time.h>
176 ++#include <unistd.h>
177 + using namespace std;
178 +
179 + const int OFFSET_TABLE_SIZE = 100;
180
181 diff --git a/sci-biology/amos/files/amos-3.1.0-goBambus2.py-indent-and-cleanup.patch b/sci-biology/amos/files/amos-3.1.0-goBambus2.py-indent-and-cleanup.patch
182 new file mode 100644
183 index 0000000..97a8f59
184 --- /dev/null
185 +++ b/sci-biology/amos/files/amos-3.1.0-goBambus2.py-indent-and-cleanup.patch
186 @@ -0,0 +1,25 @@
187 +--- amos-3.1.0/src/Pipeline/goBambus2.py.orig 2013-09-11 01:05:29.850090457 +0200
188 ++++ amos-3.1.0/src/Pipeline/goBambus2.py 2013-09-11 01:07:03.250090701 +0200
189 +@@ -1,7 +1,7 @@
190 + #pipeline script for assembly + Bambus 2
191 + #contributed by Todd J Treangen
192 +
193 +-import string, sys, os, subprocess#, spincursor
194 ++import sys, os, subprocess#, spincursor
195 +
196 + RED = "\033[0;31m"
197 + GREEN = "\033[0;32m"
198 +@@ -360,7 +360,7 @@
199 + print "\t\t%s...failed%s"%(RED,NONE)
200 + sys.exit(1)
201 +
202 +- p = subprocess.Popen(AMOSDIR+"OutputResults -b %s -prefix %s %s"%(amosbank, prefix+".scaff.linear"), shell=True, stdin=subprocess.PIPE, stdout=vtext, stderr=logfile)
203 ++ p = subprocess.Popen(AMOSDIR+"OutputResults -b %s -prefix %s %s"%(amosbank, prefix+".scaff.linear"), shell=True, stdin=subprocess.PIPE, stdout=vtext, stderr=logfile)
204 +
205 + if xopt_dict["verbose"] == 1:
206 + print "10) running OutputResults"
207 +@@ -388,4 +388,3 @@
208 + else:
209 + print "\t\t%s...failed%s"%(RED,NONE)
210 + sys.exit(1)
211 +-)