Gentoo Archives: gentoo-commits

From: Justin Lecher <jlec@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] proj/sci:master commit in: sci-biology/est2uni/, sci-biology/est2uni/files/
Date: Mon, 21 Sep 2015 14:05:14
Message-Id: 1442839246.b4487963b83d55df769d8cb6552f692bf970c3d5.jlec@gentoo
1 commit: b4487963b83d55df769d8cb6552f692bf970c3d5
2 Author: Justin Lecher <jlec <AT> gentoo <DOT> org>
3 AuthorDate: Mon Sep 21 12:40:46 2015 +0000
4 Commit: Justin Lecher <jlec <AT> gentoo <DOT> org>
5 CommitDate: Mon Sep 21 12:40:46 2015 +0000
6 URL: https://gitweb.gentoo.org/proj/sci.git/commit/?id=b4487963
7
8 Drop obsolete package Sources unavailable
9
10 Signed-off-by: Justin Lecher <jlec <AT> gentoo.org>
11
12 sci-biology/est2uni/ChangeLog | 41 -
13 sci-biology/est2uni/est2uni-0.27.ebuild | 99 ---
14 sci-biology/est2uni/est2uni-9999.ebuild | 114 ---
15 .../est2uni/files/9999-est_clustering.pm.patch | 29 -
16 sci-biology/est2uni/files/9999-pipe_db.pm.patch | 15 -
17 sci-biology/est2uni/files/99est2uni | 3 -
18 sci-biology/est2uni/files/configuration.php.patch | 12 -
19 sci-biology/est2uni/files/est2uni | 3 -
20 sci-biology/est2uni/files/est_annot.pm.patch | 456 ----------
21 sci-biology/est2uni/files/est_annot_go.pm.patch | 136 ---
22 sci-biology/est2uni/files/est_annot_psnp.pm.patch | 11 -
23 .../files/est_annot_reciprocal_blast.pm.patch | 14 -
24 sci-biology/est2uni/files/est_clustering.pm.patch | 383 --------
25 sci-biology/est2uni/files/est_prepro.pm.patch | 85 --
26 .../files/installation_est2uni_perl.txt.patch | 85 --
27 sci-biology/est2uni/files/mysql_fixes.sql | 3 -
28 sci-biology/est2uni/files/pipe_db.pm.patch | 972 ---------------------
29 sci-biology/est2uni/files/tables.sql.patch | 23 -
30 sci-biology/est2uni/files/tgicl_files.patch | 26 -
31 sci-biology/est2uni/metadata.xml | 9 -
32 20 files changed, 2519 deletions(-)
33
34 diff --git a/sci-biology/est2uni/ChangeLog b/sci-biology/est2uni/ChangeLog
35 deleted file mode 100644
36 index db9015a..0000000
37 --- a/sci-biology/est2uni/ChangeLog
38 +++ /dev/null
39 @@ -1,41 +0,0 @@
40 -# ChangeLog for sci-biology/est2uni
41 -# Copyright 1999-2015 Gentoo Foundation; Distributed under the GPL v2
42 -# $Id$
43 -
44 - 23 Mar 2015; Marius Brehler <marbre@××××××××××××××.de> est2uni-0.27.ebuild:
45 - Drop keywords (php:5.3 is hardmasked)
46 -
47 - 24 Sep 2014; Justin Lecher <jlec@g.o> est2uni-0.27.ebuild:
48 - Bump to EAPI=5
49 -
50 - 06 Jan 2014; Justin Lecher <jlec@g.o> est2uni-9999.ebuild,
51 - metadata.xml:
52 - Switch from git-2 to git-r3
53 -
54 - 22 May 2012; Justin Lecher <jlec@g.o> est2uni-0.27.ebuild,
55 - est2uni-9999.ebuild:
56 - Bump to EAPI=4, remove unnecessary bits
57 -
58 - 12 Dec 2011; Martin Mokrejs <mmokrejs@×××××××××××××××.cz>
59 - est2uni-9999.ebuild:
60 - added configuration.php.patch for VHOSTS setup files/configuration.php.patch
61 - est2uni-9999.ebuild
62 -
63 - 30 Jul 2011; Martin Mokrejs <mmokrejs@×××××××××××××××.cz>
64 - +files/9999-est_clustering.pm.patch, +files/9999-pipe_db.pm.patch,
65 - +est2uni-9999.ebuild:
66 - ebuild cleanup est2uni-0.27.ebuild est2uni-9999.ebuild Manifest
67 - files/9999-est_clustering.pm.patch files/9999-pipe_db.pm.patch
68 - files/99est2uni files/est2uni files/est_annot.pm.patch
69 - files/est_annot_go.pm.patch files/est_annot_psnp.pm.patch
70 - files/est_annot_reciprocal_blast.pm.patch files/est_clustering.pm.patch
71 - files/est_prepro.pm.patch files/installation_est2uni_perl.txt.patch
72 - files/mysql_fixes.sql files/pipe_db.pm.patch files/tables.sql.patch
73 - files/tgicl_files.patch metadata.xml
74 -
75 -*est2uni-9999 (05 Jul 2011)
76 -
77 - 05 Jul 2011; Martin Mokrejs <mmokrejs@×××××××××××××××.cz>
78 - +files/9999-est_clustering.pm.patch, +files/9999-pipe_db.pm.patch,
79 - +est2uni-9999.ebuild:
80 - vim est2uni-9999.ebuild
81
82 diff --git a/sci-biology/est2uni/est2uni-0.27.ebuild b/sci-biology/est2uni/est2uni-0.27.ebuild
83 deleted file mode 100644
84 index 112176c..0000000
85 --- a/sci-biology/est2uni/est2uni-0.27.ebuild
86 +++ /dev/null
87 @@ -1,99 +0,0 @@
88 -# Copyright 1999-2015 Gentoo Foundation
89 -# Distributed under the terms of the GNU General Public License v2
90 -# $Id$
91 -
92 -EAPI=5
93 -
94 -inherit eutils perl-module webapp
95 -
96 -DESCRIPTION="Perl-based analysis pipeline including php-based web interface"
97 -HOMEPAGE="http://cichlid.umd.edu/est2uni/download.php"
98 -SRC_URI="
99 - http://cichlid.umd.edu/est2uni/est2uni_0.27.tar.gz
100 - ftp://ftp.ncbi.nih.gov/pub/UniVec/UniVec
101 - ftp://ftp.ncbi.nih.gov/pub/UniVec/UniVec_Core
102 - http://www.geneontology.org/ontology/gene_ontology.obo
103 - http://www.geneontology.org/doc/GO.terms_and_ids"
104 -
105 -SLOT="0"
106 -LICENSE="GPL-3"
107 -KEYWORDS=""
108 -IUSE=""
109 -
110 -DEPEND=""
111 -RDEPEND="${DEPEND}
112 - >=dev-db/mysql-4.1
113 - dev-lang/php:5.3
114 - dev-perl/go-perl
115 - sci-biology/bioperl
116 - sci-biology/cap3-bin
117 - sci-biology/estscan
118 - sci-biology/exonerate
119 - <sci-biology/hmmer-3.0
120 - sci-biology/lucy
121 - sci-biology/ncbi-tools
122 - sci-biology/phred
123 - sci-biology/repeatmasker
124 - sci-biology/seqclean
125 - sci-biology/tgicl
126 - www-servers/apache"
127 -
128 -S="${WORKDIR}"/est2uni
129 -
130 -src_prepare(){
131 - for f in "${FILESDIR}"/*.pm.patch "${FILESDIR}"/tgicl_files.patch; do
132 - cd perl; epatch $f
133 - done
134 -}
135 -
136 -src_compile(){
137 - $(tc-getCC) ${CFLAGS} ${LDFLAGS} external_software/sputnik/sputnik.c -o external_software/sputnik/sputnik || die
138 -}
139 -
140 -src_install(){
141 - mkdir -p "${D}"/opt/est2uni
142 - mv external_software/sputnik/sputnik "${D}"/opt/est2uni || die
143 -
144 - chmod a+rx perl/*.pl perl/*.pm || die
145 - mv perl/* "${D}"/opt/est2uni || die
146 -
147 - doenvd "${FILESDIR}"/99est2uni
148 -
149 - mkdir -p "${D}"/usr/share/webapps/"${PN}"/"${PV}"/htdocs
150 - cp -r php/* "${D}"/usr/share/webapps/"${PN}"/"${PV}"/htdocs || die
151 -
152 - mkdir -p "${D}"/opt/est2uni/test_data || die
153 - mv test_data/* "${D}"/opt/est2uni/test_data || die
154 - # mkdir -p "${D}"/usr/share/"${PN}" || die
155 - # mv test_data "${D}"/usr/share/"${PN}" || die
156 - perl-module_src_install || die
157 -
158 - webapp_src_preinst
159 - webapp_postinst_txt en "${S}"/README
160 - webapp_src_install
161 -
162 - # cp "${DISTDIR}"/UniVec_Core "${DISTDIR}"/UniVec "${D}"/usr/share/ncbi/data/ || die
163 -
164 - einfo "Please follow the pipeline installation and web configuration docs at"
165 - einfo "http://cichlid.umd.edu/est2uni/install.php"
166 - einfo "BEWARE the software is not maintained anymore by upstream but I do not"
167 - einfo "know any better available (replaced by ngs_backbone which has no web"
168 - einfo "interface yet). Consider using latest svn checkout instead of 0.27"
169 - einfo "release from 2007 or so."
170 - einfo "Possible fixes and stuff to read:"
171 - einfo "https://listas.upv.es/pipermail/est2uni/2008-January/000069.html"
172 - einfo "https://listas.upv.es/pipermail/est2uni/2008-March/000103.html"
173 - einfo "https://listas.upv.es/pipermail/est2uni/2008-March/000101.html"
174 - einfo "https://listas.upv.es/pipermail/est2uni/2008-April/000135.html"
175 - einfo "https://listas.upv.es/pipermail/est2uni/2008-April/000131.html"
176 - einfo "https://listas.upv.es/pipermail/est2uni/2008-February/000070.html"
177 - einfo "https://listas.upv.es/pipermail/est2uni/2008-April/000129.html"
178 - einfo "https://listas.upv.es/pipermail/est2uni/2008-April/000128.html"
179 - einfo "https://listas.upv.es/pipermail/est2uni/2008-May/000139.html"
180 - echo ""
181 - einfo "Current code is at http://bioinf.comav.upv.es/git///?p=est2uni;a=summary"
182 -}
183 -
184 -pkg_postinst(){
185 - webapp_pkg_postinst
186 -}
187
188 diff --git a/sci-biology/est2uni/est2uni-9999.ebuild b/sci-biology/est2uni/est2uni-9999.ebuild
189 deleted file mode 100644
190 index 89435ed..0000000
191 --- a/sci-biology/est2uni/est2uni-9999.ebuild
192 +++ /dev/null
193 @@ -1,114 +0,0 @@
194 -# Copyright 1999-2014 Gentoo Foundation
195 -# Distributed under the terms of the GNU General Public License v2
196 -# $Id$
197 -
198 -EAPI=5
199 -
200 -[ "$PV" == "9999" ] && _GIT=git-r3
201 -
202 -inherit eutils ${_GIT} perl-module webapp
203 -
204 -DESCRIPTION="Perl-based analysis pipeline including php-based web interface"
205 -HOMEPAGE="http://cichlid.umd.edu/est2uni/download.php"
206 -if [ "$PV" == "9999" ]; then
207 - EGIT_REPO_URI="git://gitolite@×××××××××××××××××.es:2203/est2uni.git"
208 - KEYWORDS=""
209 -else
210 - SRC_URI="
211 - http://cichlid.umd.edu/est2uni/est2uni.tar.gz
212 - ftp://ftp.ncbi.nih.gov/pub/UniVec/UniVec
213 - ftp://ftp.ncbi.nih.gov/pub/UniVec/UniVec_Core
214 - http://www.geneontology.org/ontology/gene_ontology.obo
215 - http://www.geneontology.org/doc/GO.terms_and_ids"
216 - KEYWORDS="~amd64 ~x86"
217 -fi
218 -
219 -SLOT="0"
220 -LICENSE="GPL-3"
221 -IUSE=""
222 -
223 -DEPEND=""
224 -RDEPEND="${DEPEND}
225 - >=dev-db/mysql-4.1
226 - dev-lang/php:5.3
227 - dev-perl/go-perl
228 - sci-biology/bioperl
229 - sci-biology/cap3-bin
230 - sci-biology/estscan
231 - sci-biology/exonerate
232 - <sci-biology/hmmer-3.0
233 - sci-biology/lucy
234 - sci-biology/ncbi-tools
235 - sci-biology/phred
236 - sci-biology/repeatmasker
237 - sci-biology/seqclean
238 - sci-biology/tgicl
239 - www-servers/apache"
240 -
241 -S="${WORKDIR}"/est2uni
242 -
243 -src_prepare(){
244 - for f in "${FILESDIR}"/9999-*.pm.patch; do
245 - cd perl || die
246 - epatch $f
247 - done
248 - cd ../php || die "Failed to chdir to ../php"
249 - epatch "${FILESDIR}"/configuration.php.patch
250 -}
251 -
252 -src_compile(){
253 - $(tc-getCC) ${CFLAGS} ${LDFLAGS} external_software/sputnik/sputnik.c -o external_software/sputnik/sputnik || die
254 -}
255 -
256 -src_install(){
257 - dodir /opt/est2uni
258 - mv external_software/sputnik/sputnik "${ED}"/opt/est2uni || die
259 -
260 - chmod a+rx perl/*.pl perl/*.pm || die
261 - mv perl/* "${ED}"/opt/est2uni || die
262 -
263 - doenvd "${FILESDIR}"/99est2uni
264 -
265 - dodir /usr/share/webapps/"${PN}"/"${PV}"/htdocs
266 - cp -r php/* "${ED}"/usr/share/webapps/"${PN}"/"${PV}"/htdocs || die
267 -
268 - dodir /opt/est2uni/test_data
269 - mv test_data/* "${ED}"/opt/est2uni/test_data || die
270 - # mkdir -p "${D}"/usr/share/"${PN}" || die
271 - # mv test_data "${D}"/usr/share/"${PN}" || die
272 - perl-module_src_install || die
273 -
274 - webapp_src_preinst
275 - webapp_postinst_txt en "${S}"/README
276 - webapp_src_install
277 - # mkdir -p /var/www/localhost/htdocs/est2uni/est2uni/temp
278 - # mkdir -p /var/www/localhost/htdocs/est2uni/est2uni/blast
279 -
280 - # cp "${DISTDIR}"/UniVec_Core "${DISTDIR}"/UniVec "${D}"/usr/share/ncbi/data/ || die
281 -
282 - einfo "Please follow the pipeline installation and web configuration docs at"
283 - einfo "http://cichlid.umd.edu/est2uni/install.php"
284 - echo ""
285 - einfo "Example changes to the config file are in ${FILESDIR}/configuration.php.patch"
286 - echo ""
287 - einfo "BEWARE the software is not maintained anymore by upstream but I do not"
288 - einfo "know any better available (replaced by ngs_backbone which has no web"
289 - einfo "interface yet). Consider using latest svn checkout instead of 0.27"
290 - einfo "release from 2007 or so."
291 - einfo "Possible fixes and stuff to read:"
292 - einfo "https://listas.upv.es/pipermail/est2uni/2008-January/000069.html"
293 - einfo "https://listas.upv.es/pipermail/est2uni/2008-March/000103.html"
294 - einfo "https://listas.upv.es/pipermail/est2uni/2008-March/000101.html"
295 - einfo "https://listas.upv.es/pipermail/est2uni/2008-April/000135.html"
296 - einfo "https://listas.upv.es/pipermail/est2uni/2008-April/000131.html"
297 - einfo "https://listas.upv.es/pipermail/est2uni/2008-February/000070.html"
298 - einfo "https://listas.upv.es/pipermail/est2uni/2008-April/000129.html"
299 - einfo "https://listas.upv.es/pipermail/est2uni/2008-April/000128.html"
300 - einfo "https://listas.upv.es/pipermail/est2uni/2008-May/000139.html"
301 - echo ""
302 - einfo "Current code is at http://bioinf.comav.upv.es/git///?p=est2uni;a=summary"
303 -}
304 -
305 -pkg_postinst(){
306 - webapp_pkg_postinst
307 -}
308
309 diff --git a/sci-biology/est2uni/files/9999-est_clustering.pm.patch b/sci-biology/est2uni/files/9999-est_clustering.pm.patch
310 deleted file mode 100644
311 index ec38e52..0000000
312 --- a/sci-biology/est2uni/files/9999-est_clustering.pm.patch
313 +++ /dev/null
314 @@ -1,29 +0,0 @@
315 ---- perl/est_prepro.pm.ori 2011-02-23 10:56:06.000000000 +0100
316 -+++ perl/est_prepro.pm 2011-02-23 19:53:13.000000000 +0100
317 -@@ -499,15 +499,17 @@
318 - $sth->bind_param(5,$unique_seq_control);
319 - # we get the clone names from the data file
320 - # if not in the data file, we guess it following user specifications in config file
321 -- unless (${%$clone}{$real_name}) {
322 -- ${%$clone}{$real_name}=get_clone_from_est($config,$real_name);
323 -- }
324 -- $sth->bind_param(6,${%$clone}{$real_name});
325 -- $$seq_info{clone}=${%$clone}{$real_name};
326 -- if (!${%$clone}{$real_name}){
327 -- print localtime().": Unable to get clone name for EST $real_name\n";
328 -- return undef;
329 -- }
330 -+ #unless (${%$clone}{$real_name}) {
331 -+ # ${%$clone}{$real_name}=get_clone_from_est($config,$real_name);
332 -+ #}
333 -+ #$sth->bind_param(6,${%$clone}{$real_name});
334 -+ #$$seq_info{clone}=${%$clone}{$real_name};
335 -+ #if (!${%$clone}{$real_name}){
336 -+ # print localtime().": Unable to get clone name for EST $real_name\n";
337 -+ # return undef;
338 -+ #}
339 -+ $sth->bind_param(6,'blah');
340 -+ $$seq_info{clone}='blah';
341 - }
342 - if (not $qual and not ($unique_seq_control eq 'raw_est' or $unique_seq_control eq 'clean_est')) {
343 - $sth->bind_param(5,$unique_seq_control)
344
345 diff --git a/sci-biology/est2uni/files/9999-pipe_db.pm.patch b/sci-biology/est2uni/files/9999-pipe_db.pm.patch
346 deleted file mode 100644
347 index 729c550..0000000
348 --- a/sci-biology/est2uni/files/9999-pipe_db.pm.patch
349 +++ /dev/null
350 @@ -1,15 +0,0 @@
351 ---- perl/pipe_db.pm 2011-02-23 18:38:47.000000000 +0100
352 -+++ pipe_db.pm 2011-02-23 19:41:06.000000000 +0100
353 -@@ -1468,10 +1468,11 @@
354 - my $tables=shift;
355 - my $ok=1;
356 -
357 -+ my %t = %$tables; # Can't use string ("38/64") as a HASH ref while "strict refs" in use at /opt/est2uni/pipe_db.pm line 1474.
358 - my $table;
359 - foreach $table(keys %$tables) {
360 - if ($ok) {
361 -- $ok=create_table($db,$table,${%{$tables}}{$table});
362 -+ $ok=create_table($db,$table,$t{$table});
363 - if ($ok) {
364 - print localtime().": Table $table created\n";
365 - } else {
366
367 diff --git a/sci-biology/est2uni/files/99est2uni b/sci-biology/est2uni/files/99est2uni
368 deleted file mode 100644
369 index 36176aa..0000000
370 --- a/sci-biology/est2uni/files/99est2uni
371 +++ /dev/null
372 @@ -1,3 +0,0 @@
373 -EST2UNI_PERL=/opt/est2uni
374 -PERL5LIB=$PERL5LIB:/opt/est2uni
375 -PATH=$PATH:/opt/est2uni
376
377 diff --git a/sci-biology/est2uni/files/configuration.php.patch b/sci-biology/est2uni/files/configuration.php.patch
378 deleted file mode 100644
379 index c973597..0000000
380 --- a/sci-biology/est2uni/files/configuration.php.patch
381 +++ /dev/null
382 @@ -1,12 +0,0 @@
383 ---- est2uni/configuration.php.example 2011-02-19 02:05:44.000000000 +0100
384 -+++ est2uni/configuration.php 2011-12-12 16:07:15.000000000 +0100
385 -@@ -16,7 +16,7 @@
386 - $config['web_master_email']="admin@×××××××.org";
387 -
388 - # base directory for web pages at this Apache installation
389 -- $config['apache_dir']="/var/www";
390 -+ $config['apache_dir']="/var/www/localhost/htdocs/est2uni";
391 -
392 - # directory name for this group of EST projects
393 - $config['group']= "";
394 -
395
396 diff --git a/sci-biology/est2uni/files/est2uni b/sci-biology/est2uni/files/est2uni
397 deleted file mode 100644
398 index 36176aa..0000000
399 --- a/sci-biology/est2uni/files/est2uni
400 +++ /dev/null
401 @@ -1,3 +0,0 @@
402 -EST2UNI_PERL=/opt/est2uni
403 -PERL5LIB=$PERL5LIB:/opt/est2uni
404 -PATH=$PATH:/opt/est2uni
405
406 diff --git a/sci-biology/est2uni/files/est_annot.pm.patch b/sci-biology/est2uni/files/est_annot.pm.patch
407 deleted file mode 100644
408 index 3a5b804..0000000
409 --- a/sci-biology/est2uni/files/est_annot.pm.patch
410 +++ /dev/null
411 @@ -1,456 +0,0 @@
412 ---- est_annot.pm.ori 2011-02-21 17:19:51.000000000 +0100
413 -+++ est_annot.pm 2011-02-23 00:06:03.000000000 +0100
414 -@@ -37,7 +37,7 @@
415 - sub store_blast_report($$$); #stores a blast report into the mysql database
416 - sub annotate_unigenes_from_db($); #adds to the unigenes table the best hits from the blast reports
417 - sub do_blast_annotation (\@$); #annotates a unigene acording to the blast results obtained for a single database
418 --sub hit_is_not_annoymous ($$); #checks if a hit has one of the annonymous tags
419 -+sub hit_is_not_anonymous ($$); #checks if a hit has one of the annonymous tags
420 - sub store_estscan_orfs($); #Stores the ESTScan results
421 - sub run_hmmer_for_unigenes ($); #runs hmmer for all the unigenes
422 - sub parse_and_store_hmmer($); #parses the hmmer result and stores it in the mysql database
423 -@@ -208,10 +208,10 @@
424 -
425 - my $dbh=open_db($db) or return 0;
426 - my $st="INSERT INTO $table VALUES (?,?,?,?,?,?);";
427 -- my $sth=$dbh->prepare($st);
428 -+ my $sth=$dbh->prepare($st) or die localtime().": Error preparing INSERT INTO $table VALUES (?,?,?,?,?,?): $DBI::errstr\n";
429 -
430 - my $num_micros=0;
431 -- open IN, "<$in_file";
432 -+ open IN, "<$in_file" or die ocaltime().": Error opening input file $in_file: $!\n";
433 - my $seq_name;
434 - my $num_micros_seq=0;
435 - while (my $line=<IN>){
436 -@@ -279,7 +279,7 @@
437 - my $cmd="$bin -u $max_unit_length -v $min_unit_length -L $min_length_of_ssr $in_file > $out_file";
438 - not (system ($cmd)) or (
439 - print localtime().": Something went wrong running Sputnik to find microsatellites\n" and
440 -- print localtime().": Command was: $cmd\n" and
441 -+ print localtime().": Command was: $cmd: $!\n" and
442 - return 0
443 - );
444 - return 1;
445 -@@ -322,7 +322,7 @@
446 - my $sth=prepare_st($dbh,$st) or return 0;
447 - execute_st($sth) or return 0;
448 - open OUT,">$outf" or (
449 -- print localtime().": There was a problem opening the file $outf as output\n" and
450 -+ print localtime().": There was a problem opening the file $outf as output: $!\n" and
451 - return 0
452 - );
453 - while (my @field = $sth->fetchrow_array){
454 -@@ -371,8 +371,9 @@
455 - }
456 - my $table=read_config($config,'hmmer_table','');
457 - my $dbh=open_db($db) or return 0;
458 -- my $st="INSERT INTO $table VALUES ('',?,?,?,?,?,?,?,'');";
459 -- my $sth=$dbh->prepare($st);
460 -+ my $st="INSERT INTO $table VALUES (NULL,?,?,?,?,?,?,?,NULL);";
461 -+ print localtime().": Trying to prepare \"$st\" for db=$db and table=$table\n";
462 -+ my $sth=$dbh->prepare($st) or print localtime().": Error preparing $st statement: $DBI::errstr\n";
463 -
464 -
465 - my $ok=1;
466 -@@ -427,7 +428,7 @@
467 - my $out=read_config($config,'hmmer_res','');
468 - my $micros=read_config($config,'micros','');
469 - unless ($bin and $db and $out and $micros){
470 -- print localtime().": Some of the parameters needed by HMMER are missing\n";
471 -+ print localtime().": Some of the parameters needed by HMMER are missing: $bin, $db, $out, $micros\n";
472 - return 0;
473 - }
474 -
475 -@@ -439,7 +440,7 @@
476 - $cmd="$pvmd_bin $host_file &";
477 - print localtime().": Launching pvm: $cmd\n";
478 - not (system($cmd)) or (
479 -- print localtime().": There was a problem launching the pvm environment\n" and
480 -+ print localtime().": There was a problem launching the pvm environment: $!\n" and
481 - return 0
482 - );
483 - $cmd="$bin --cpu $micros --pvm $db $in > $out";
484 -@@ -452,7 +453,7 @@
485 - stop_pvm($config);
486 - }
487 - if ($not_ok){
488 -- print localtime().": There was a problem running HMMER\n";
489 -+ print localtime().": There was a problem running HMMER: $!\n";
490 - return 0;
491 - }
492 -
493 -@@ -510,8 +511,8 @@
494 - #begin_orf mediumint unsigned not null,
495 - #end_orf mediumint unsigned not null,
496 - #reverse tinyint(1) not null
497 -- my $st="INSERT INTO $table VALUES ('',?,?,?,?,?,?);";
498 -- my $sth=$dbh->prepare($st);
499 -+ my $st="INSERT INTO $table VALUES (NULL,?,?,?,?,?,?);";
500 -+ my $sth=$dbh->prepare($st) or die localtime().": Error preparing $st statement: $DBI::errstr\n";
501 -
502 - my $no_exit=1;
503 - my $ok=1;
504 -@@ -544,7 +545,7 @@
505 - }
506 - $sth->execute() or $ok=0;
507 - unless ($ok){
508 -- print localtime().": There was a problem executing the statement $st\n";
509 -+ print localtime().": There was a problem executing the statement: $st: $DBI::errstr\n";
510 - return 0;
511 - }
512 - }else{
513 -@@ -583,7 +584,7 @@
514 - my $cmd="$bin $seq_file -M $matrix -t $out_pep -o $out_dna\n";
515 - not(system($cmd)) or (
516 - print localtime().": There has been a problem running ESTScan.\n" and
517 -- print localtime().": Command was:\n$cmd\n" and
518 -+ print localtime().": Command was:\n$cmd: $!\n" and
519 - return 0
520 - );
521 -
522 -@@ -698,7 +699,7 @@
523 - if (not ($putative_e_value) or ($e_value < $putative_e_value)){
524 - #we evaluate if this is a good hit
525 - #is greater than the $inf_limit
526 -- if (($e_value<$inf_limit) and hit_is_not_annoymous($hit,$config)){
527 -+ if (($e_value<$inf_limit) and hit_is_not_anonymous($hit,$config)){
528 - #this is a good hit, we should annotate the unigene
529 - $putative_e_value=$e_value;
530 - #we remove the first word and the trailing information of the hit
531 -@@ -718,7 +719,7 @@
532 - return $putative_annot;
533 - }
534 -
535 --sub hit_is_not_annoymous ($$){
536 -+sub hit_is_not_anonymous ($$){
537 - my $hit=shift;
538 - my $config=shift;
539 - my $ok=1;
540 -@@ -730,7 +731,7 @@
541 - if ($hit =~ /$tag/i) {return 0}
542 - }
543 -
544 -- # hit is also annonymous if it has no description
545 -+ # hit is also anonymous if it has no description
546 - # JF, 2007-01-10
547 - if ($hit =~ /^\t$/) {return 0}
548 -
549 -@@ -747,7 +748,7 @@
550 - my $table=read_config($config,'unigenes_table2','') or return 0;
551 - my $st="UPDATE $table SET annotation=NULL;";
552 - my $dbh=open_db($db) or (
553 -- print localtime().": Unable to open database $db\n" and
554 -+ print localtime().": Unable to open database $db: $DBI::errstr\n" and
555 - return 0
556 - );
557 - my $sth=prepare_st($dbh,$st) or return 0;
558 -@@ -776,7 +777,7 @@
559 - my $cmd="cp $seq_file $blast_dir".$db_name;
560 - my $fail=system($cmd);
561 - if ($fail){
562 -- print localtime().": There was a problem with the command: $cmd\n";
563 -+ print localtime().": There was a problem with the command: $cmd: $!\n";
564 - return 0;
565 - }
566 - #format the database
567 -@@ -792,7 +793,7 @@
568 - }
569 - $fail=system($cmd); #now the database is formatted
570 - if ($fail){
571 -- print localtime().": There was a problem with the command: $cmd\n";
572 -+ print localtime().": There was a problem with the command: $cmd: $!\n";
573 - print localtime().": Logfile is $log\n";
574 - return 0;
575 - }
576 -@@ -986,7 +987,7 @@
577 - my $in = new Bio::SearchIO(-format => 'blast',-file => $in_file);
578 - open OUT,">$out_file" or $ok=0;
579 - unless ($ok) {
580 -- print localtime().": The out file: $out_file could not be opened.\n";
581 -+ print localtime().": The out file: $out_file could not be opened: $!\n";
582 - return 0;
583 - }
584 -
585 -@@ -1092,7 +1093,7 @@
586 -
587 - #prints a wellcome message
588 - sub wellcome_annot () {
589 -- print localtime().": Wellcome to the EST annotation pipe, have a pleasant jouney.\n\n";
590 -+ print localtime().": Welcome to the EST annotation pipe, have a pleasant journey.\n\n";
591 - }
592 -
593 -
594 -@@ -1112,6 +1113,7 @@
595 - my $dbh=open_db($db) or return 0;
596 - #if the database is superunigenes previous blast superunigenes should be removed
597 - if ($blast_db =~ /superunigenes$/){
598 -+ print localtime().": Deleting previous BLAST results: DELETE FROM blast_result WHERE db='superunigenes'\n";
599 - my $st="DELETE FROM blast_result WHERE db='superunigenes'";
600 - my $sth=$dbh->prepare($st) or return 0;
601 - execute_st($sth) or return 0;
602 -@@ -1129,18 +1131,19 @@
603 - if ($ext){$temp_in.=$separator.$ext}
604 -
605 - #we create a new in file with the sequences that still has no blast stored in the database
606 -- #if the blast is alredy done, there is no need to repeat it
607 -+ #if the blast is already done, there is no need to repeat it
608 - my $st;
609 - if (read_config($config,'mysql_compress','')){
610 - $st="SELECT UNCOMPRESS(blast_result) FROM blast_result WHERE query_seq=? AND db='$blast_db'";
611 - }else{
612 - $st="SELECT blast_result FROM blast_result WHERE query_seq=? AND db='$blast_db'";
613 - }
614 -+ print localtime().": Extracting from $in_file those FASTA entries which have no rows matching in blast_result.query_seq using Bio::SeqIO into $temp_in\n";
615 - my $sth=$dbh->prepare($st) or return 0;
616 - my $num_blast_todo=0;
617 - my $in_seq = Bio::SeqIO->new('-file' => "<$in_file",'-format' => "fasta") or return 0;
618 - my $out_seq = Bio::SeqIO->new('-file' => ">$temp_in",'-format' => "fasta") or return 0;
619 -- open OUT, ">$blast_file_from_db";
620 -+ open OUT, ">$blast_file_from_db" or print localtime().": Cannot write to $blast_file_from_db file: $!\n";
621 - while (my $seq=$in_seq->next_seq){
622 - my $seq_name=$seq->id;
623 - $sth->bind_param(1,$seq_name);
624 -@@ -1162,10 +1165,11 @@
625 - #we run the blast
626 - #we need to check for every blast if this blast has already been done to avoid repeating blast from different modules
627 - if (!$num_blast_todo){
628 -- print localtime().": All BLASTs are already on the database\n";
629 -+ print localtime().": All BLASTs are already in the database: \$num_blast_todo=$num_blast_todo\n";
630 - my $cmd="mv $blast_file_from_db $out_file";
631 - !system ($cmd) or return 0;
632 -- return 1
633 -+ print localtime().": Renamed $blast_file_from_db to $out_file\n";
634 -+ return 1;
635 - }
636 - run_local_blast($temp_in,$in_type,$blast_file_from_blast,$blast_db,$config) or return 0;
637 - $dbh=open_db($db) or return 0;
638 -@@ -1173,14 +1177,18 @@
639 - #we split the result and we store it on the database
640 - #we should do a minimal parsing but we don't use bioperl to speed up the process
641 - #we just asume that every blast begins with ^BLAST and that the query is ^Query= xxxxxxxx
642 -- open IN,"<$blast_file_from_blast" or return 0;
643 -+ if (! -r $blast_file_from_blast) {
644 -+ print localtime().": File $blast_file_from_blast is not readable: $!\n";
645 -+ return 0;
646 -+ }
647 -+ open IN,"<$blast_file_from_blast" or die localtime().": Cannot open $blast_file_from_blast file: $!\n";
648 - my $more=1;
649 - my $blast_result="";
650 - my $query="";
651 - if (read_config($config,'mysql_compress','')){
652 -- $st="INSERT INTO blast_result (query_seq,db,blast_result) VALUES (?,?,COMPRESS(?))";
653 -+ $st="INSERT DELAYED INTO blast_result (query_seq,db,blast_result) VALUES (?,?,COMPRESS(?))";
654 - }else{
655 -- $st="INSERT INTO blast_result (query_seq,db,blast_result) VALUES (?,?,?)";
656 -+ $st="INSERT DELAYED INTO blast_result (query_seq,db,blast_result) VALUES (?,?,?)";
657 - }
658 - $sth=$dbh->prepare($st) or return 0;
659 - while ($more){
660 -@@ -1211,6 +1219,7 @@
661 - #now we have two files with blast results, the one generated by the blast and the one made by stored blast
662 - #we should merge them to obtain the output file
663 - my $cmd="cat $blast_file_from_blast $blast_file_from_db > $out_file";
664 -+ print localtime().": Merging computed blast output with the one already in database: 'cat $blast_file_from_blast $blast_file_from_db > $out_file'\n";
665 - !system ($cmd) or return 0;
666 -
667 - return 1;
668 -@@ -1241,7 +1250,7 @@
669 - print localtime().": There was a problem executing the statement:\n" and
670 - print localtime().": Query: $query\n" and
671 - print localtime().": Blast db: $blast_db\n" and
672 -- print localtime().": $st\n" and
673 -+ print localtime().": $st: $DBI::errstr\n" and
674 - return 0
675 - );
676 - return 1;
677 -@@ -1267,25 +1276,55 @@
678 -
679 - my $db;my $db_type; my $env_blastdir; my $program;
680 - if (not($db_name =~ /unigenes\.*\d*/) and $db_name ne 'superunigenes'){
681 -+ print localtime().": BLAST database $db_name does not match REGEXP with /unigenes\.*\\d*/ nor =='superunigenes',\n\t\t\tfetching its location from table db (sourced from databases.csv)\n";
682 - $db=${$$db_info{$db_name}}{'local_blast_name'};
683 - $db_type=${$$db_info{$db_name}}{'kind'};
684 -+ print localtime().": Inferred $db_type datatype from table db (sourced from databases.csv)\n";
685 - }else{
686 -+ # unigenes and superunigenes are DNA datasets generated from this EST dataset
687 -+ # albeit it is ugly these files were written into BLASTDB directory where typically site-wide, public databases exist
688 - if ($ENV{'BLASTDB'}) { #if blastdb enviroment is set
689 -+ print localtime().": BLAST database $db_name will be looked up via BLASTDB=".$ENV{'BLASTDB'}."\n";
690 - #$env_blastdir = $ENV{'BLASTDB'};
691 - #$ENV{'BLASTDB'} = '';
692 - $db=$db_name; #db is just db name
693 - }else{ #otherwise
694 -+ print localtime().": Getting rid of the trailing '_dna' if possible\n";
695 - $db_name =~ s/_dna$//; # get rid of '_dna' in db name
696 - $db=read_config($config,'blast_dir','').$db_name; #we should add the path to the database
697 -+ print localtime().": BLAST database $db was looked up via est_pipe.conf variable \$blast_dir\n";
698 - }
699 - $db_type='dna';
700 -+ print localtime().": Forced 'dna' datatype because unigenes and superunigenes are DNA datasets generated from this EST dataset.\n\t\t\t However, it is ugly that these files were written into BLASTDB defined directory where typically site-wide, public databases exist.\n";
701 - }
702 - unless (check_blastdb($ENV{'BLASTDB'},$db)) {
703 - print localtime().": BLAST database $db cannot be found at $ENV{'BLASTDB'}\n";
704 -+ } else {
705 -+ if (-r $ENV{'BLASTDB'}."/".$db) {
706 -+ print localtime().": BLAST database $db exists in $ENV{'BLASTDB'}\n";
707 -+ if ($db_type eq 'dna') {
708 -+ if (! -r $ENV{'BLASTDB'}."/".$db.".nin") {
709 -+ system("cd $ENV{'BLASTDB'} && formatdb -p F -i $db") or die "Failed to formatdb -p F -i $db\n";
710 -+ } else {
711 -+ print localtime().": BLAST database ".$ENV{'BLASTDB'}."/".$db." already formatted, good\n";
712 -+ }
713 -+ } elsif ($db_type eq 'pep') {
714 -+ if (! -r $ENV{'BLASTDB'}."/".$db.".pin") {
715 -+ system("cd $ENV{'BLASTDB'} && formatdb -p T -i $db") or die "Failed to formatdb -p T -i $db\n";
716 -+ } else {
717 -+ print localtime().": BLAST database ".$ENV{'BLASTDB'}."/".$db." already formatted, good\n";
718 -+ }
719 -+ } else {
720 -+ print localtime().": Do not know whether $db is a pep/dna database, not checking whether it is formatted by formatdb, it is your job\n";
721 -+ }
722 -+ } else {
723 -+ print localtime().": Cannot find BLAST database ".$ENV{'BLASTDB'}."/".$db."\n";
724 -+ return 0;
725 -+ }
726 - }
727 -
728 - if (!$db_type){
729 -- print localtime().": Database type (dna or pep) not defined for database $db_name\n";
730 -+ print localtime().": Database type (dna or pep) not defined for database $db_name in databases.csv and subsequently in table db.\n";
731 - return 0;
732 - }
733 - $program = ${$$db_info{$db_name}}{'blast_program'};
734 -@@ -1294,6 +1333,7 @@
735 - elsif ($in_type eq 'pep' and $db_type eq 'dna'){$program='tblastn'}
736 - elsif ($in_type eq 'dna' and $db_type eq 'pep'){$program='blastx'}
737 - elsif ($in_type eq 'pep' and $db_type eq 'pep'){$program='blastp'}
738 -+ else { print localtime().": Wrong combination of input data type=$in_type and db.kind=$in_type, do not know which of blastn/tblastn/blastx/blastp to use\n"; return 0; }
739 - }elsif($program ne'blastn' and $program ne'tblastn' and $program ne'blastx' and $program ne'blastp' and $program ne'tblastx'){
740 - print localtime().": BLAST program called $program is not allowed\n";
741 - return 0;
742 -@@ -1330,7 +1370,7 @@
743 - $ok=not (system("rm $out_file"));
744 - unless ($ok){
745 - print localtime().": The BLAST output file: $out_file\n";
746 -- print localtime().": exists and can not be removed\n";
747 -+ print localtime().": exists and can not be removed: $!\n";
748 - return 0;
749 - };
750 - }
751 -@@ -1346,7 +1386,7 @@
752 - my $fail=system($cmd);
753 - if ($fail){
754 - print localtime().": Something wen't wrong with the mpiBLAST\n";
755 -- print localtime().": Command was: $cmd\n";
756 -+ print localtime().": Command was: $cmd: $!\n";
757 - return 0;
758 - }
759 - } else {
760 -@@ -1357,7 +1397,7 @@
761 - my $fail=system($cmd);
762 - if ($fail){
763 - print localtime().": Something wen't wrong with the BLAST\n";
764 -- print localtime().": Command was: $cmd\n";
765 -+ print localtime().": Command was: $cmd: $!\n";
766 - return 0;
767 - }
768 - }else{
769 -@@ -1371,7 +1411,7 @@
770 - #we create the input stream
771 - my $in = Bio::SeqIO->new(-file => $in_file , -format => 'Fasta') or $ok=0;
772 - unless ($ok){
773 -- print localtime().": There was a problem opening the file $in_file\n";
774 -+ print localtime().": There was a problem opening the file $in_file: $!\n";
775 - }
776 - my $seq; my $blast_report;
777 - while ($seq=$in->next_seq()) {
778 -@@ -1380,13 +1420,13 @@
779 - #input file there could be some memory trouble
780 - $blast_report= $factory->blastall($seq);
781 - unless ($blast_report) {
782 -- print localtime().": There was a problem running the BLAST search\n";
783 -+ print localtime().": There was a problem running the BLAST search: $!\n";
784 - return 0;
785 - }
786 -- system("cat $temp_file >> $out_file")
787 -+ system("cat $temp_file >> $out_file") or die "Cannot append to $out_file: $!\n";
788 - }
789 -- #we remove the temporal file
790 -- system("rm $temp_file");
791 -+ #we remove the temporary file
792 -+ system("rm $temp_file") or die "Cannot remove temporary file $temp_file: $!\n";
793 - #my $blast_report = $factory->blastall($in_file);
794 - }
795 - }
796 -@@ -1425,7 +1465,7 @@
797 - my $blast_dbs=read_config($config,'blast_dbs','');
798 - my @blast_dbs=split(/,/,$blast_dbs);
799 - unless (@blast_dbs) {
800 -- print localtime().": There are no BLAST databases defined in the config file\n";
801 -+ print localtime().": There are no BLAST databases defined in the config file under \$blast_dbs\n";
802 - return 0;
803 - }
804 - #how are the report files named?
805 -@@ -1441,7 +1481,7 @@
806 - }
807 - my $db=read_config($config,'db_path',''); #complete path to the mysql db
808 - unless (check_table($db,$table)){
809 -- print localtime().": Table $table for store the BLAST reports is not in database $db\n";
810 -+ print localtime().": Table $table to store the BLAST reports is not in created in the database $db\n";
811 - return 0;
812 - }
813 -
814 -@@ -1461,7 +1501,7 @@
815 - my $config=shift;
816 - my $blast_db=shift;
817 - my $in_file=shift;
818 -- print localtime().": Storing BLAST report: $in_file into the database\n";
819 -+ print localtime().": Storing BLAST report from $in_file into the database\n";
820 - my $table=read_config($config,'blast_reports_table','');
821 - my $db=read_config($config,'db_path',''); #complete path to the mysql db
822 -
823 -@@ -1477,13 +1517,13 @@
824 - #| identity | float | | | 0 | |
825 - #| similarity | float | | | 0 | |
826 - #| e_value
827 -- my $st="INSERT INTO $table (blast_result_id,subj_acc,description,location_begin_query,location_end_query,location_query,location_begin_subj,location_end_subj,location_subj,identity,similarity,e_value) VALUES (?,?,?,?,?,?,?,?,?,?,?,?);";
828 -+ my $st="INSERT DELAYED INTO $table (blast_result_id,subj_acc,description,location_begin_query,location_end_query,location_query,location_begin_subj,location_end_subj,location_subj,identity,similarity,e_value) VALUES (?,?,?,?,?,?,?,?,?,?,?,?);";
829 - my $sth=$dbh->prepare($st) or return 0;
830 - my $st_blast_result="SELECT blast_result_id FROM blast_result WHERE query_seq=? AND db=?";
831 - my $sth_blast_result=$dbh->prepare($st_blast_result) or return 0;
832 - unless ($sth){
833 - print localtime().": There was a problem preparing statement:\n";
834 -- print localtime().": $st\n";
835 -+ print localtime().": $st: $DBI::errstr\n";
836 - close_db($dbh);
837 - return 0;
838 - }
839 -@@ -1493,8 +1533,10 @@
840 - }
841 - open IN, "<$in_file" or $ok=0;
842 - unless ($ok) {
843 -- print localtime()." There was a problem opening file $in_file\n";
844 -+ print localtime()." There was a problem opening file $in_file: $!\n";
845 - return 0;
846 -+ } else {
847 -+ print localtime().": Parsing $in_file with BLAST plaintext output\n";
848 - }
849 - my $line;my $query;my $hit;
850 - while ($ok){
851 -@@ -1513,7 +1555,7 @@
852 - if ($array[0]){
853 - $blast_result_id=$array[0]
854 - }else{
855 -- print localtime().": BLAST result ID has not been found in the database\n";
856 -+ print localtime().": BLAST result blast_result_id has not been found in the database using query_seq=$query AND db=$blast_db\n";
857 - return 0;
858 - }
859 -
860 -@@ -1558,6 +1600,7 @@
861 - print localtime().": query: $query\n";
862 - print localtime().": blast_db: $blast_db\n";
863 - print localtime().": hit: $hit\n";
864 -+ print localtime().": The error was: $DBI::errstr\n";
865 - return 0;
866 - }
867 - }
868
869 diff --git a/sci-biology/est2uni/files/est_annot_go.pm.patch b/sci-biology/est2uni/files/est_annot_go.pm.patch
870 deleted file mode 100644
871 index bdda596..0000000
872 --- a/sci-biology/est2uni/files/est_annot_go.pm.patch
873 +++ /dev/null
874 @@ -1,136 +0,0 @@
875 ---- est_annot_go.pm.ori 2011-02-22 15:33:33.000000000 +0100
876 -+++ est_annot_go.pm 2011-02-23 00:12:48.000000000 +0100
877 -@@ -213,13 +213,13 @@
878 - sub annotate_go_from_blast($$){
879 - my $config=shift;
880 - my $db_info=shift;
881 -- print localtime().": Annotating the sequences with GO terms looking at the BLAST results.\n";
882 -+ print localtime().": Annotating the sequences with GO terms from ".read_config($config,'go_assoc_table','')." looking at the BLAST results in ".read_config($config,'go_db_path','').".\n";
883 -
884 - #the go-blast_db association is stored in a table on a database
885 - my $go_db_path=read_config($config,'go_db_path','');
886 - my $assoc_table=read_config($config,'go_assoc_table','');
887 - my $go_dbh=open_db($go_db_path) or (
888 -- print localtime().": There was a problem opening the database $go_db_path\n" and
889 -+ print localtime().": There was a problem opening the database $go_db_path: $DBI::errstr\n" and
890 - return 0
891 - );
892 -
893 -@@ -227,13 +227,13 @@
894 - my $result_table=read_config($config,'go_table','');
895 - my $est_db_path=read_config($config,'db_path','');
896 - my $est_dbh=open_db($est_db_path) or (
897 -- print localtime().": There was a problem opening the database $est_db_path\n" and
898 -+ print localtime().": There was a problem opening the database $est_db_path: $DBI::errstr\n" and
899 - return 0
900 - );
901 - #we use ignore because we're interested just in the first annotation for the combined seq_go_slim, it could be more but they're not important
902 - my $est_st="INSERT IGNORE INTO $result_table (db,db_symbol,qualifier,go_id,ori_evidence,evidence,aspect,taxon_id,e_value,is_slim,seq_id) VALUES (?,?,?,?,?,?,?,?,?,?,?);";
903 - my $est_sth=prepare_st($est_dbh,$est_st) or (
904 -- print localtime().": There was a problem executing the statement $est_st\n" and
905 -+ print localtime().": There was a problem executing the statement $est_st: $DBI::errstr\n" and
906 - return 0
907 - );
908 -
909 -@@ -255,7 +255,7 @@
910 - my $real_table=$assoc_table.$go_db;
911 - my $go_st="SELECT db,db_symbol,qualifier,go_id,evidence,aspect,taxon_id,is_slim FROM $real_table WHERE db_symbol=? ;";
912 - my $go_sth=prepare_st($go_dbh,$go_st) or (
913 -- print localtime().": There was a problem executing the statement $go_st\n" and
914 -+ print localtime().": There was a problem executing the statement $go_st: $DBI::errstr\n" and
915 - return 0
916 - );
917 - unless ($go_db){
918 -@@ -264,7 +264,7 @@
919 - }
920 - #we go through the blast files using the bioperl blast parser
921 - my $in = new Bio::SearchIO(-format => 'blast',-file => $blast_file) or(
922 -- print localtime().": There was a problem creating a bioperl handler for the BLAST file $blast_file\n" and
923 -+ print localtime().": There was a problem creating a bioperl handler for the BLAST file $blast_file: $!\n" and
924 - return 0
925 - );
926 -
927 -@@ -277,9 +277,12 @@
928 - my $significative_hit=0;
929 - my $query=$result->query_name;
930 - my $hit=$result->next_hit;
931 -- unless ($hit){$done=1;last}; #if there isn't more hits we're finnished
932 -+ unless ($hit){$done=1;last}; #if there isn't more hits we're finished
933 - my $acc=$hit->name;
934 -- #the arabidopsis project puts an .number in the hit name that should be removed
935 -+ if (! $acc ) {
936 -+ print localtime().": No \$acc value parsed from \$hit->name\n";
937 -+ }
938 -+ #the arabidopsis project puts a .number in the hit name that should be removed
939 - if (${$$db_info{$go_db}}{'orthologues_arabi_hack'}){
940 - $acc =~ s/\.\d$//;
941 - }
942 -@@ -299,7 +302,7 @@
943 - #is there go terms associated with this acc?
944 - $go_sth->bind_param(1,$acc);
945 - $go_sth->execute or (
946 -- print localtime().": There was a problem executing the statement $go_st with accession $acc\n" and
947 -+ print localtime().": There was a problem executing the statement $go_st with accession $acc: $DBI::errstr\n" and
948 - return 0
949 - );
950 - my $there_is_go=0;
951 -@@ -319,7 +322,7 @@
952 - $est_sth->bind_param(10,$$go[7]); #is this a slim term?
953 - $est_sth->bind_param(11,$query); #annotated sequence
954 - $est_sth->execute or (
955 -- print localtime().": There was a problem executing the statement $est_st\n" and
956 -+ print localtime().": There was a problem executing the statement $est_st: $DBI::errstr\n" and
957 - return 0
958 - );
959 - $done=1; #we do not need any more hits
960 -@@ -333,11 +336,12 @@
961 - $i_uni++;
962 - }
963 - close_st ($go_sth);
964 -+ print localtime().": $i_uni BLAST unigenes processed from $blast_file, $i_uni_with_go with GO annotations, and $i_go_assoc GO terms associated\n";
965 - }
966 - close_st ($est_sth);
967 - close_db ($go_dbh);
968 - close_db ($est_dbh);
969 -- print localtime().": $i_uni BLAST unigenes processed, $i_uni_with_go with GO annotations, and $i_go_assoc GO terms associated\n";
970 -+ print localtime().": $i_uni BLAST unigenes processed from $blast_file_base and "."@go_dbs\n".", $i_uni_with_go with GO annotations, and $i_go_assoc GO terms associated\n";
971 - return 1;
972 - }
973 -
974 -@@ -367,7 +371,7 @@
975 - my $assoc_file=${$$db_info{$db}}{'local_go_assoc_file'};
976 - my $cmd="$bin $slim_file $go_def_file $assoc_file -o $temp_dir$base_out_file".$sep."$db";
977 - not (system $cmd) or (
978 -- print localtime().": There was a problem executing: $cmd\n" and
979 -+ print localtime().": There was a problem executing $cmd: $!\n" and
980 - return 0
981 - );
982 - $i++;
983 -@@ -447,7 +451,8 @@
984 - my $table=read_config($config,'go_assoc_table','');
985 - #now it's time to fill the table with the data
986 - my $real_table=$table.$go_db;
987 -- my $st="INSERT INTO $real_table (db,db_symbol,qualifier,go_id,evidence,aspect,taxon_id,is_slim) VALUES (?,?,?,?,?,?,?,?);";
988 -+ # this is a wastefull insert inserting qualifier, taxon_id, is_slim equal to NULL
989 -+ my $st="INSERT DELAYED INTO $real_table (db,db_symbol,qualifier,go_id,evidence,aspect,taxon_id,is_slim) VALUES (?,?,?,?,?,?,?,?);";
990 - my $dbh=open_db($db_path) or (
991 - print localtime().": There was a problem opening the database $db_path\n" and
992 - return 0
993 -@@ -491,7 +496,7 @@
994 - $sth->bind_param(5,$items[6]); #evidence
995 - $sth->bind_param(6,$items[8]); #aspect
996 - $sth->bind_param(7,$items[12]); #taxon_id
997 -- $sth->bind_param(8,$is_slim);
998 -+ $sth->bind_param(8,$is_slim); #is_slim
999 - }else{
1000 - print localtime().": Gene-GO association file has no defined format in $config go_assoc_file_format\n";
1001 - print localtime().": Or the format is not supported. Supported formats are goa and tair\n";
1002 -@@ -542,7 +547,7 @@
1003 - my $db=read_config($config,'db_path','');
1004 -
1005 - open IN,"<$file" or (
1006 -- print localtime().": Imposible to open file: $file\n" and
1007 -+ print localtime().": Error opening file $file: $!\n" and
1008 - return 0
1009 - );
1010 -
1011
1012 diff --git a/sci-biology/est2uni/files/est_annot_psnp.pm.patch b/sci-biology/est2uni/files/est_annot_psnp.pm.patch
1013 deleted file mode 100644
1014 index 996d625..0000000
1015 --- a/sci-biology/est2uni/files/est_annot_psnp.pm.patch
1016 +++ /dev/null
1017 @@ -1,11 +0,0 @@
1018 ---- est_annot_psnp.pm.ori 2011-02-22 20:12:25.000000000 +0100
1019 -+++ est_annot_psnp.pm 2011-02-22 20:12:46.000000000 +0100
1020 -@@ -773,7 +773,7 @@
1021 - }
1022 -
1023 - my $dbh=open_db($db) or return 0;
1024 -- my $st_psnp="INSERT INTO $table_psnp (psnp_id,unigene,location,is_snp,is_indel,score,enzymes) VALUES (?,?,?,?,?,?,'');";
1025 -+ my $st_psnp="INSERT INTO $table_psnp (psnp_id,unigene,location,is_snp,is_indel,score,enzymes) VALUES (?,?,?,?,?,?,NULL);";
1026 - my $sth_psnp=$dbh->prepare($st_psnp);
1027 - my $st_seq="INSERT INTO $table_seq (psnp_id,nucleotide,est,accession) VALUES (?,?,?,?);";
1028 - my $sth_seq=$dbh->prepare($st_seq);
1029
1030 diff --git a/sci-biology/est2uni/files/est_annot_reciprocal_blast.pm.patch b/sci-biology/est2uni/files/est_annot_reciprocal_blast.pm.patch
1031 deleted file mode 100644
1032 index e887f7e..0000000
1033 --- a/sci-biology/est2uni/files/est_annot_reciprocal_blast.pm.patch
1034 +++ /dev/null
1035 @@ -1,14 +0,0 @@
1036 ---- est_annot_reciprocal_blast.pm.ori 2011-02-22 01:19:43.000000000 +0100
1037 -+++ est_annot_reciprocal_blast.pm 2011-02-22 01:39:37.000000000 +0100
1038 -@@ -106,8 +106,9 @@
1039 - my @dbs=split (',',read_config($config,'reci_dbs',''));
1040 - foreach my $db (@dbs){
1041 - if (!$$db_info{$db}){
1042 -- print localtime().": Database $db is not defined in db table on the databases\n";
1043 -- return 0;
1044 -+ print localtime().": Database $db included in \$reci_dbs is not described in table db, skipping.\n";
1045 -+ #return 0;
1046 -+ next;
1047 - }
1048 - my $in_file=$unigenes_seq_file;
1049 - my $outf=$in_file.$separator.$db.$separator."blast";
1050
1051 diff --git a/sci-biology/est2uni/files/est_clustering.pm.patch b/sci-biology/est2uni/files/est_clustering.pm.patch
1052 deleted file mode 100644
1053 index a6e553a..0000000
1054 --- a/sci-biology/est2uni/files/est_clustering.pm.patch
1055 +++ /dev/null
1056 @@ -1,383 +0,0 @@
1057 ---- est_clustering.pm.ori 2011-02-21 13:12:39.000000000 +0100
1058 -+++ est_clustering.pm 2011-02-22 20:23:16.000000000 +0100
1059 -@@ -76,7 +76,7 @@
1060 - }
1061 -
1062 - sub contig_image ($) {
1063 -- print localtime().": Creating contig images\n";
1064 -+ print localtime().": Creating contig images using contigimage.pl\n";
1065 - my $config = shift;
1066 - my $bin = read_config($config,'contigimage_bin','contigimage.pl');
1067 - my $ace = read_config($config,'ace_file','');
1068 -@@ -94,6 +94,8 @@
1069 - my $qual_file=read_config($config,'seqclean_masked_qual',''); #output file for the qualities
1070 - my $db=read_config($config,'db_path',''); #path to the database in the format dbi:$dbi_driver:$db_name:$host
1071 - my @libraries=split(/,/,read_config($config,'libraries','')); #libraries to be retrieved
1072 -+ # if populate_clone_table=0 then the clone table is empty, therefore the SELECT would return empty results
1073 -+ my $populate_clone_table=read_config($config,'populate_clone_table','');
1074 - my $ok=1;
1075 - print localtime().": Fetching processed ESTs from the database\n";
1076 -
1077 -@@ -108,20 +110,36 @@
1078 - #we create the handler for the database
1079 - my $dbh; my $sth; #database and statements handlers
1080 - if ($ok){$dbh=open_db($db) or $ok=0}; #we open the database
1081 -- my $st="SELECT sequence.name,sequence.sequence,sequence.quality FROM sequence,est,clone WHERE ( ";
1082 -+
1083 -+ my $st="";
1084 -+ if ($populate_clone_table) {
1085 -+ $st="SELECT sequence.name,sequence.sequence,sequence.quality FROM sequence,est,clone WHERE ( ";
1086 - foreach (@libraries) {
1087 - $st.="clone.library = '$_' OR "
1088 - }
1089 - $_=$st; s/ OR $//;$st=$_; #this removes the trailing OR
1090 - $st.=" ) ";
1091 -+ } else {
1092 -+ $st="SELECT sequence.name,sequence.sequence,sequence.quality FROM sequence,est WHERE ";
1093 -+ }
1094 -+
1095 -+ # if populate_clone_table=0 then the clone table is empty, therefore the SELECT would return empty results
1096 -+ # mysql> SELECT sequence.name,sequence.sequence,sequence.quality FROM sequence,est,clone WHERE
1097 -+ # ( clone.library = 'sgn' OR clone.library = 'fake' OR clone.library = 'tigr' )
1098 -+ # AND clone.name=est.clone AND est.processed_seq=sequence.name;
1099 -+ # Empty set (0.00 sec)
1100 -+ if ($populate_clone_table) {
1101 - $st.= "AND clone.name=est.clone AND est.processed_seq=sequence.name";
1102 -+ } else {
1103 -+ $st.= "est.processed_seq=sequence.name";
1104 -+ }
1105 -
1106 - if ($ok) {$sth=$dbh->prepare($st) or $ok=0}
1107 - #we execute the statement
1108 - if ($ok) {
1109 - $sth->execute() or $ok=0;
1110 - unless ($ok) {
1111 -- print localtime().": There was an error executing the SELECT statement\n";
1112 -+ print localtime().": There was an error executing the SELECT statement: $DBI::errstr\n";
1113 - }
1114 - }
1115 - #now all the results are written in the output files
1116 -@@ -138,6 +156,7 @@
1117 - $seq_stream->write_seq($seq);
1118 - $qual_stream->write_seq($seq->qual_obj());
1119 - }
1120 -+ print localtime().": Fetched ".$sth->rows()." from the database.\n";
1121 - close_st($sth);
1122 - close_db($dbh);
1123 - return $ok;
1124 -@@ -159,11 +178,11 @@
1125 - );
1126 - my $st="DELETE FROM $table WHERE object_type='contig' OR object_type='singleton';";
1127 - my $sth=prepare_st($dbh,$st) or (
1128 -- print localtime().": Unable to prepare the statement $st\n" and
1129 -+ print localtime().": Unable to prepare the statement $st: $DBI::errstr\n" and
1130 - return 0
1131 - );
1132 - $sth->execute or (
1133 -- print localtime().": Unable to execute the statement $st\n" and
1134 -+ print localtime().": Unable to execute the statement $st: $DBI::errstr\n" and
1135 - return 0
1136 - );
1137 - close_st($sth);
1138 -@@ -172,11 +191,11 @@
1139 -
1140 - $st="UPDATE $table SET unigene=NULL, location_begin=NULL, location_end=NULL, orientation_fwd=NULL, r_begin_in=NULL, r_end_in=NULL, inserts=NULL;";
1141 - $sth=prepare_st($dbh,$st) or (
1142 -- print localtime().": Unable to prepare the statement $st\n" and
1143 -+ print localtime().": Unable to prepare the statement $st: $DBI::errstr\n" and
1144 - return 0
1145 - );
1146 - $sth->execute or (
1147 -- print localtime().": Unable to execute the statement $st\n" and
1148 -+ print localtime().": Unable to execute the statement $st: $DBI::errstr\n" and
1149 - return 0
1150 - );
1151 - close_st($sth);
1152 -@@ -227,7 +246,7 @@
1153 -
1154 - # First we run tgicl
1155 - chdir($temp_dir);
1156 -- $command="$bin_tgicl ".$in_seq." -q ".$in_qual;
1157 -+ $command="$bin_tgicl -F ".$in_seq." -q ".$in_qual;
1158 - if ($tgicl_opt) {
1159 - $command .= " $tgicl_opt";
1160 - }
1161 -@@ -247,19 +266,25 @@
1162 - unless ($tgicl_success)
1163 - {
1164 - print localtime().": There was a problem running tgicl. The command was:\n";
1165 -- print "$command\n";
1166 -+ print "$command: $!\n";
1167 - return $tgicl_success;
1168 - }
1169 -
1170 - # Now we save the results on the results dir
1171 - # file with the reads that form every contig
1172 - print localtime().": Saving the tgicl contigs results\n";
1173 -+ if (-r $in_seq.$contigs_ext) {
1174 -+ # files from older tgicl are *_clusters
1175 - $command="mv ".$in_seq.$contigs_ext." ".$contigs_file;
1176 -+ } elsif (-r $in_seq."_cl".$contigs_ext) {
1177 -+ # files from newer tgicl are *_cl_clusters
1178 -+ $command="mv ".$in_seq."_cl".$contigs_ext." ".$contigs_file;
1179 -+ }
1180 - $tgicl_success= not(system($command));
1181 - unless ($tgicl_success)
1182 - {
1183 - print localtime().": There was a problem moving the tgicl result. The command was:\n";
1184 -- print "$command\n";
1185 -+ print "$command: $!\n";
1186 - return $tgicl_success;
1187 - }
1188 -
1189 -@@ -270,7 +295,7 @@
1190 - unless ($tgicl_success)
1191 - {
1192 - print localtime().": There was a problem running tgicl. The command was:\n";
1193 -- print "$command\n";
1194 -+ print "$command: $!\n";
1195 - return $tgicl_success;
1196 - }
1197 -
1198 -@@ -286,7 +311,7 @@
1199 - unless ($tgicl_success)
1200 - {
1201 - print localtime().": There was a problem running tgicl. The command was:\n";
1202 -- print "$command\n";
1203 -+ print "$command: $!\n";
1204 - return $tgicl_success;
1205 - }
1206 -
1207 -@@ -302,7 +327,7 @@
1208 - unless ($tgicl_success)
1209 - {
1210 - print localtime().": There was a problem running tgicl. The command was:\n";
1211 -- print "$command\n";
1212 -+ print "$command: $!\n";
1213 - return $tgicl_success;
1214 - }
1215 -
1216 -@@ -313,7 +338,7 @@
1217 - $tgicl_success=not(system($command));
1218 - unless ($tgicl_success)
1219 - {
1220 -- print localtime().": There was a problem running cdbyank\n";
1221 -+ print localtime().": There was a problem running $command: $!\n";
1222 - return $tgicl_success;
1223 - }
1224 -
1225 -@@ -353,7 +378,7 @@
1226 - $ok=not(system($command));
1227 - unless ($ok) {
1228 - print localtime().": There was a problem running cap3. The command was:\n";
1229 -- print "$command\n";
1230 -+ print "$command: $!\n";
1231 - return $ok;
1232 - }
1233 - my $qual_file=$seq_file.".qual";
1234 -@@ -361,7 +386,7 @@
1235 - system($command);
1236 - unless ($ok) {
1237 - print localtime().": There was a problem running cap3. The command was:\n";
1238 -- print "$command\n";
1239 -+ print "$command: $!\n";
1240 - return $ok;
1241 - }
1242 -
1243 -@@ -390,7 +415,7 @@
1244 - unless ($ok)
1245 - {
1246 - print localtime().": There was a problem running cap3. The command was:\n";
1247 -- print "$command\n";
1248 -+ print "$command: $!\n";
1249 - return $ok;
1250 - }
1251 -
1252 -@@ -402,7 +427,7 @@
1253 - unless ($ok)
1254 - {
1255 - print localtime().": There was a problem running cap3. The command was:\n";
1256 -- print "$command\n";
1257 -+ print "$command: $!\n";
1258 - return $ok;
1259 - }
1260 -
1261 -@@ -412,7 +437,7 @@
1262 - unless ($ok)
1263 - {
1264 - print localtime().": There was a problem running tgicl. The command was:\n";
1265 -- print "$command\n";
1266 -+ print "$command: $!\n";
1267 - return $ok;
1268 - }
1269 -
1270 -@@ -423,7 +448,7 @@
1271 - unless ($ok)
1272 - {
1273 - print localtime().": There was a problem running tgicl. The command was:\n";
1274 -- print "$command\n";
1275 -+ print "$command: $!\n";
1276 - return $ok;
1277 - }
1278 -
1279 -@@ -442,17 +467,19 @@
1280 - #we should keep the original singletons names
1281 - my $single_file=read_config($config,'singletons_list','');
1282 - my $ori_single_file=read_config($config,'original_singletons_list','');
1283 -+
1284 -+ my $prefix=read_config($config,'prefix','');
1285 -+ my $postfix=read_config($config,'postfix','');
1286 -+ # doh, but the routine update_est_table_with_singletons() anyways looks for the unchanged original file
1287 - my $cmd="cp $single_file $ori_single_file";
1288 - my $not_ok=system ($cmd);
1289 - if ($not_ok){
1290 -- print localtime()."; There was a problem with the command $cmd\n";
1291 -+ print localtime()."; There was a problem with the command $cmd: $!\n";
1292 - return 0;
1293 - }
1294 -- my $prefix=read_config($config,'prefix','');
1295 -- my $postfix=read_config($config,'postfix','');
1296 - unless ($prefix or $postfix){
1297 -- print localtime().": WARNING, there are no prefix or postfix to change unigene name\n";
1298 -- print localtime().": WARNING, it won't be any name change\n";
1299 -+ print localtime().": WARNING, there are no prefix or postfix defined to change unigene name\n";
1300 -+ print localtime().": WARNING, there won't be any name change\n";
1301 - return 1;
1302 - }
1303 - change_seq_names_in_file($contigs_file,$config,'') or return 0;
1304 -@@ -470,8 +497,8 @@
1305 - my $postfix=read_config($config,'singleton_seq_tag','');
1306 -
1307 - my $temp_file=select_temp_file($config);
1308 -- open IN, "<$file";
1309 -- open OUT, ">$temp_file\n";
1310 -+ open IN, "<$file" or die "Error: failed to open $file: $!\n";
1311 -+ open OUT, ">$temp_file" or die "Error: failed to write $temp_file: $!\n";
1312 - while (my $line = <IN>){
1313 - #for fasta files
1314 - if ($line =~ /^>/){
1315 -@@ -586,7 +613,7 @@
1316 - my $ok=1;
1317 - open OUT,">$outf" or $ok= 0;
1318 - unless ($ok){
1319 -- print localtime().": There was a problem opening the file: $outf\n";
1320 -+ print localtime().": There was a problem opening the file: $outf: $!\n";
1321 - return 0;
1322 - }
1323 -
1324 -@@ -629,7 +656,7 @@
1325 - my $ok=1;
1326 - open IN, "<$dnaf" or $ok=0;
1327 - unless ($ok){
1328 -- print localtime().": ESTScan result file $dnaf couldn't be opened\n";
1329 -+ print localtime().": ESTScan result file $dnaf couldn't be opened: $!\n";
1330 - return 0;
1331 - }
1332 - while (<IN>){
1333 -@@ -653,18 +680,18 @@
1334 - my $backf=$revf.".bak";
1335 - my $not_ok=system ("cp $revf $backf");
1336 - if ($not_ok){
1337 -- print localtime().": There was a problem when trying to do a copy of $revf to $backf\n";
1338 -+ print localtime().": There was a problem when trying to do a copy of $revf to $backf: $!\n";
1339 - return 0;
1340 - }
1341 -
1342 - open OUT, ">$revf" or $ok=0;
1343 - unless ($ok){
1344 -- print localtime().": Reverse file $revf couldn't be opened for output\n";
1345 -+ print localtime().": Reverse file $revf couldn't be opened for output: $!\n";
1346 - return 0;
1347 - }
1348 - open IN, "<$backf" or $ok=0;
1349 - unless ($ok){
1350 -- print localtime().": Reverse file $backf couldn't be opened for input\n";
1351 -+ print localtime().": Reverse file $backf couldn't be opened for input: $!\n";
1352 - return 0;
1353 - }
1354 - while (<IN>){
1355 -@@ -711,20 +738,20 @@
1356 -
1357 - open ACE, "<$ace_file" or $ok=0;
1358 - unless ($ok) {
1359 -- print localtime().": There has been a problem opening the file $ace_file\n";
1360 -+ print localtime().": There has been a problem opening the file $ace_file: $!\n";
1361 - print localtime().": Maybe is not in the correct tgicl_ace format.\n";
1362 - return 0;
1363 - }
1364 -
1365 - my $dbh=open_db($db);
1366 - unless ($dbh) {
1367 -- print localtime().": Database $dbh is not reachable\n";
1368 -+ print localtime().": Database $dbh is not reachable: $DBI::errstr\n";
1369 - return 0;
1370 - }
1371 - my $st= write_insert_st ($table,@fields);
1372 - my $sth=prepare_st($dbh,$st);
1373 - unless ($sth) {
1374 -- print localtime().": There has been a problem preparing the statement: $st\n";
1375 -+ print localtime().": There has been a problem preparing the statement: $st: $DBI::errstr\n";
1376 - close_db($dbh);
1377 - return 0;
1378 - }
1379 -@@ -839,6 +866,10 @@
1380 - push(@$orientation,$1);
1381 - }
1382 - $contig =~ s/^\n+//;
1383 -+ while ($contig =~ s/^BS\s+?\d+\s+?\d+\s+?([^\s]+)\s*\n//){
1384 -+ print localtime().": Skipping BS line in the ACE output due to newer cap3: https://listas.upv.es/pipermail/est2uni/2008-October/000191.html\n";
1385 -+ }
1386 -+ $contig =~ s/^\n+//;
1387 - my $read_len=[]; my $seq_names=[];
1388 - my $r_begin_in_read=[];
1389 - my $r_end_in_read=[];
1390 -@@ -955,7 +986,7 @@
1391 - $table=read_config($config,'est_table','');
1392 - $st="UPDATE $table SET unigene=?,orientation_fwd=?,location_begin=?,location_end=?,r_begin_in=?,r_end_in=?,inserts=? WHERE processed_seq=?";
1393 - $sth=prepare_st($dbh,$st) or (
1394 -- print localtime().": There was a problem preparing the statement $st\n" and
1395 -+ print localtime().": There was a problem preparing the statement: $st: $DBI::errstr\n" and
1396 - return 0
1397 - );
1398 - foreach my $contig_info (@contig_est_info){
1399 -@@ -981,7 +1012,7 @@
1400 - $sth->bind_param(7,$insertion);
1401 - $sth->bind_param(8,$seq_name);
1402 - $sth->execute or (
1403 -- print localtime().": There was a problem executing the statement $st\n" and
1404 -+ print localtime().": There was a problem executing the statement: $st: $DBI::errstr\n" and
1405 - return 0
1406 - );
1407 - unless (@{${$contig_info}[1]} and @{${$contig_info}[2]} and @{${$contig_info}[3]}){
1408 -@@ -1042,19 +1073,19 @@
1409 - my $db=read_config($config,'db_path','');
1410 - my $dbh=open_db($db);
1411 - unless ($dbh) {
1412 -- print localtime().": Database $dbh is not reachable\n";
1413 -+ print localtime().": Database $dbh is not reachable: $DBI::errstr\n";
1414 - return 0;
1415 - }
1416 - my $st="UPDATE $est_table SET unigene=?,orientation_fwd=1,location_begin=1,location_end=?,r_begin_in=1,r_end_in=? WHERE processed_seq=?";
1417 - my $sth=prepare_st($dbh,$st) or (
1418 -- print localtime().": There was a problem preparing the statement $st\n" and
1419 -+ print localtime().": There was a problem preparing the statement: $st: $DBI::errstr\n" and
1420 - return 0
1421 - );
1422 -
1423 - my $singletons_file=read_config($config,'seq_singletons_file',''); #singletons fasta file
1424 - my $ori_singletons_file=read_config($config,'original_singletons_list',''); #singletons list file without the name change this is in fact the name of the est sequences that correspond to every singleton
1425 - open ORI, "<$ori_singletons_file" or (
1426 -- print localtime().": There was a problem opening file: $ori_singletons_file\n" and
1427 -+ print localtime().": There was a problem opening file: $ori_singletons_file: $!\n" and
1428 - return 0
1429 - );
1430 -
1431 -@@ -1070,7 +1101,7 @@
1432 - $sth->bind_param(3,$len);
1433 - $sth->bind_param(4,$ori_line);
1434 - $sth->execute or (
1435 -- print localtime().": There was a problem executing the statement $st\n" and
1436 -+ print localtime().": There was a problem executing the statement: $st: $DBI::errstr\n" and
1437 - return 0
1438 - );
1439 - }
1440
1441 diff --git a/sci-biology/est2uni/files/est_prepro.pm.patch b/sci-biology/est2uni/files/est_prepro.pm.patch
1442 deleted file mode 100644
1443 index 7efcbe8..0000000
1444 --- a/sci-biology/est2uni/files/est_prepro.pm.patch
1445 +++ /dev/null
1446 @@ -1,85 +0,0 @@
1447 ---- est_prepro.pm.ori 2011-02-21 11:37:20.000000000 +0100
1448 -+++ est_prepro.pm 2011-02-22 00:46:57.000000000 +0100
1449 -@@ -478,7 +478,7 @@
1450 - }
1451 - else {
1452 - print localtime()." There is a problem with the length in sequence ".$temp_seq->id."\n";
1453 -- print localtime()." from file: $seq_file\n. Quality and sequence length don't match.\n";
1454 -+ print localtime()." from file: $seq_file. Quality $temp_qual->length and sequence $temp_seq->length length don't match.\n";
1455 - #print $temp_seq->desc."\n";
1456 - return 0;
1457 - }
1458 -@@ -973,7 +973,7 @@
1459 - #check that $assignments_file exist
1460 - if (not(-r $assi_file)){
1461 - print localtime().": ######################################################################\n";
1462 -- print localtime().": WARNING: Assignment file for lucy is not found or not defined\n";
1463 -+ print localtime().": WARNING: Assignment file $assi_file for lucy is not found or not defined\n";
1464 - print localtime().": Lucy will not be used in the preprocessing\n";
1465 - print localtime().": ######################################################################\n";
1466 - }else{
1467 -@@ -1062,7 +1062,7 @@
1468 - my $tag=read_config($config,'assignment_tag','');
1469 - $command="echo $tag".$library.">> $temp_log";
1470 - chdir ($temp_dir); #we change the directory becouse lucy write some stuff in the working directory
1471 -- system($command);
1472 -+ system($command) or die print localtime().": $command failed: $!\n";
1473 - chdir ($actual_dir);
1474 - # Options used:
1475 - # $in_seq fasta sequences generated by phred
1476 -@@ -1086,9 +1086,9 @@
1477 -
1478 - # lucy log is moved to the results directory
1479 - $command="cat $temp_log >> $log";
1480 -- system($command);
1481 -+ system($command) or die print localtime().": failed to append $temp_log contents to $log\n";
1482 - $command="rm $temp_log";
1483 -- system($command);
1484 -+ system($command) or die print localtime().": failed to delete $temp_log\n";
1485 -
1486 - if ($success)
1487 - {
1488 -@@ -1112,8 +1112,8 @@
1489 - print localtime().": Parsing the lucy output\n";
1490 - # now we check that the input file is in place
1491 - unless (check_file($lucy_log_file,"lucy log file")){
1492 -- print localtime().": WARNING there is no lucy log file\n";
1493 -- print localtime().": Maybe lucy has not been used by any library\n";
1494 -+ print localtime().": WARNING there is no lucy log file $lucy_log_file\n";
1495 -+ print localtime().": Maybe lucy has not been used by any library?\n";
1496 - return 1;
1497 - }
1498 -
1499 -@@ -1490,7 +1490,7 @@
1500 - sub run_seqclean($$$$$$$$$$$$)
1501 - {
1502 - my $config=shift;
1503 -- my $library=shift; # informational porpouse only
1504 -+ my $library=shift; # informational purpose only
1505 - my $trimmed_fasta_file=shift; # name for the trimmed sequences file
1506 - my $trimmed_qual_file=shift; # name for the trimmed quality file
1507 - my $seqclean_report_file=shift; # report file with the masked area
1508 -@@ -1518,7 +1518,13 @@
1509 - #The file with the vector (univec recommended)
1510 - my $vec_file=read_config($config,'seqclean_vec_dat','');
1511 - unless (check_file($vec_file,"vector database")){return 0};
1512 --
1513 -+ if (! -r $vec_file.".nin") {
1514 -+ print localtime().": Formatting database with formatdb -p F -i $vec_file\n";
1515 -+ system("cd `dirname $vec_file` && formatdb -p F -i $vec_file");
1516 -+ if (! -r $vec_file.".nin") {
1517 -+ die "Failed to formatdb $vec_file: $!\n";
1518 -+ }
1519 -+ }
1520 - my $seqclean_success=1; # control variable
1521 - my $command;
1522 - my $temp;
1523 -@@ -1749,7 +1755,7 @@
1524 - sub seqclean_masking_assignments ($$$$$$)
1525 - {
1526 - my $config=shift;
1527 -- print localtime().": Masking the sequences following seqclean's recomendations\n";
1528 -+ print localtime().": Masking the sequences following seqclean's recommendations\n";
1529 - my @libraries=split(',',read_config($config,'libraries','')); # libraries names
1530 - my $report=read_config($config,'seqclean_report',''); # base name for the report generated by seqclean, this is the file with the instruccions for masking the sequences
1531 - my $in_seq=shift; # base name for the trimmed sequences file generated by lucy
1532
1533 diff --git a/sci-biology/est2uni/files/installation_est2uni_perl.txt.patch b/sci-biology/est2uni/files/installation_est2uni_perl.txt.patch
1534 deleted file mode 100644
1535 index a4d2413..0000000
1536 --- a/sci-biology/est2uni/files/installation_est2uni_perl.txt.patch
1537 +++ /dev/null
1538 @@ -1,85 +0,0 @@
1539 ---- installation_est2uni_perl.txt.ori 2011-02-21 11:52:15.000000000 +0100
1540 -+++ installation_est2uni_perl.txt 2011-02-21 22:58:23.000000000 +0100
1541 -@@ -84,8 +84,12 @@
1542 - .qual.
1543 -
1544 - There are some library examples on the 'test_data' directory of the EST2uni
1545 --distribution. You could just copy that libraries to check the software. Be
1546 --aware that the sgn chromatograms could need a modification in the phredpar.dat file
1547 -+distribution. You could just copy that libraries to check the software.
1548 -+
1549 -+ > cp /usr/local/est2uni/test_data/libraries/* ./libraries
1550 -+ > cp -r /usr/local/est2uni/test_data/data .
1551 -+
1552 -+Be aware that the sgn chromatograms could need a modification in the phredpar.dat file
1553 - (see installation instructions for phred in docs/installation_external_software.txt).
1554 -
1555 - 4.- Copy the estpipe.conf.example file from the installation directory into
1556 -@@ -205,7 +209,7 @@
1557 - Although the clustering software could consider that two unigenes are not similar
1558 - enough to be merged, it is useful to know which are these similar clusters of unigenes.
1559 - Accordingly, EST2uni does a clustering of the unigenes, and these clusters are named
1560 --'superunigenes'. This analysis is done thorough a BLAST search, followed by
1561 -+'superunigenes'. This analysis is done through a BLAST search, followed by
1562 - parsing the results. Unigenes with a similarity high enough (above user-defined threshold
1563 - parameters) are then clustered in a superunigene.
1564 -
1565 -@@ -219,15 +223,17 @@
1566 -
1567 - In EST2uni a database can have several aspects like the blast indexed files, the fasta
1568 - sequence files or the related GO files. This information should be placed in the file
1569 --referenced by the parameter databases_dat. This file should be uploaded to the database
1570 --setting the parameters populate_database_table and do_prior_data_population to 1.
1571 -+referenced by the parameter databases_dat, usually named databases.csv.
1572 -+Contents of this file will be uploaded into the database when the parameters
1573 -+populate_database_table and do_prior_data_population are set to 1.
1574 -
1575 - In that file, the name of the database is defined in the field "name" and could be different
1576 - than the BLAST name. For instance the database name could be "arabidopsis" and the local
1577 --BLAST name could be "tair6". When a BLAST against database "arabidopsis" is
1578 --asked, EST2uni will look for the local BLAST name in the database. In this example the blast should
1579 --be asked for the database "arabidopsis", not against "tair6", despite the fact that the
1580 --local blast database is named "tair6".
1581 -+BLAST filename could be "tair6". When a BLAST against database "arabidopsis" is
1582 -+asked, EST2uni will look for the local BLAST-formatted filenames tair6.* in the BLASTDB
1583 -+of $blast_dir directory. In this example the blast should be asked for the database
1584 -+"arabidopsis", not against "tair6", despite the fact that the local blast database is
1585 -+named "tair6".
1586 -
1587 -
1588 - BLAST ANNOTATION
1589 -@@ -243,7 +249,8 @@
1590 - this example the arabidopsis database should be defined in the databases_dat file. On that
1591 - file the field local_blast_name should be the name given to that database on the local blast
1592 - installation. For instance it could be named tair6. That means that the name in the blast_dbs
1593 --parameter and the name of the database in the local blast installation could be different.
1594 -+parameter and the name of the database in the local blast installation could be different
1595 -+(they are mapped via the databases.csv trick).
1596 -
1597 - Other important field in the databases file is "kind", which should be set to dna or pep.
1598 -
1599 -@@ -357,7 +364,7 @@
1600 - same database. The paths for these files should be specified in the local_go_assoc_file and
1601 - local_go_slim_obo_file of the databases information file. The GO association file for the
1602 - arabidopsis database can be downloaded from the www.arabidopsis.org site. At the time of
1603 -- this writting the file is located in:
1604 -+ this writing the file is located in:
1605 - ftp://ftp.arabidopsis.org/home/tair/Ontologies/Gene_Ontology/ATH_GO_GOSLIM.20061021.txt
1606 - The GO slim obo file for arabidopsis and goa is on the Gene Ontology ftp:
1607 - ftp://ftp.geneontology.org/pub/go/GO_slims/go_slim_plant.obo
1608 -@@ -376,7 +383,7 @@
1609 - ----------------
1610 -
1611 - You just need to set the parameter do_hmmer_annot to 1 and to set the name
1612 --of the HMMER database on the parameter pfam_db.
1613 -+of the HMMER database on the parameter pfam_db with a full path.
1614 -
1615 - HMMER uses the ORFs as a starting point, so it is necessary to have the annotated
1616 - ORF already in the database or to ask for the do_estscan_annot.
1617 -@@ -400,5 +407,5 @@
1618 - ---------------------------
1619 -
1620 - Every researcher can be associated with several ESTs using the csv file defined in the working_on_dat
1621 --parameter. Those relationships will get loaded when the parameters populate_workin_on_table and
1622 -+parameter. Those relationships will get loaded when the parameters populate_working_on_table and
1623 - do_prior_data_population are set to 1.
1624
1625 diff --git a/sci-biology/est2uni/files/mysql_fixes.sql b/sci-biology/est2uni/files/mysql_fixes.sql
1626 deleted file mode 100644
1627 index ee3ec93..0000000
1628 --- a/sci-biology/est2uni/files/mysql_fixes.sql
1629 +++ /dev/null
1630 @@ -1,3 +0,0 @@
1631 -alter table db change kind kind enum('dna','pep') default null;
1632 -alter table db change blast_program blast_program enum('blastn', 'blastp', 'blastx', 'tblastn', 'tblastx') default null;
1633 -alter table db change rec_sim_type rec_sim_type enum('orthologue', 'synonymous') default null;
1634
1635 diff --git a/sci-biology/est2uni/files/pipe_db.pm.patch b/sci-biology/est2uni/files/pipe_db.pm.patch
1636 deleted file mode 100644
1637 index 139cf56..0000000
1638 --- a/sci-biology/est2uni/files/pipe_db.pm.patch
1639 +++ /dev/null
1640 @@ -1,972 +0,0 @@
1641 ---- pipe_db.pm.ori 2011-02-22 18:08:58.000000000 +0100
1642 -+++ pipe_db.pm 2011-02-22 14:48:03.000000000 +0100
1643 -@@ -90,29 +90,29 @@
1644 -
1645 - my $db=read_config($config,'db_path',''); #database in the form dbi:$dbi_driver:$db_name:$host
1646 - my $dbh=open_db($db) or (
1647 -- print localtime().": There was a problem opening the database $db: $DBI::errstr\n" and
1648 -+ print localtime().": There was a problem opening the database $db\n" and
1649 - return 0
1650 - ); #we open the database
1651 -
1652 - #the location statistics
1653 - my $st="INSERT INTO pssr_location_view SELECT CASE ((ssr_end<orf_begin)*1+(ssr_begin>orf_end)*2+(ssr_begin>orf_begin && ssr_end<orf_end)*3) WHEN 0 THEN 'other' WHEN 1 THEN '5_utr' WHEN 2 THEN '3_utr' WHEN 3 THEN 'in_orf' END AS location,count(*) AS count FROM ESTScan_orf,sputnik_ssr WHERE sputnik_ssr.seq_name=ESTScan_orf.seq_name GROUP BY (ssr_end<orf_begin)*1+(ssr_begin>orf_end)*2+(ssr_begin>orf_begin && ssr_end<orf_end)*3";
1654 - my $sth=prepare_st($dbh,$st) or (
1655 -- print localtime().": There was a problem preparing the statement $st: $DBI::errstr\n" and
1656 -+ print localtime().": There was a problem preparing the statement $st" and
1657 - return 0
1658 - );
1659 - execute_st($sth) or (
1660 -- print localtime().": There was a problem executing the statement $st: $DBI::errstr\n" and
1661 -+ print localtime().": There was a problem executing the statement $st" and
1662 - return 0
1663 - );
1664 - close_st($sth);
1665 - #the unit kind statistics
1666 - $st="INSERT INTO pssr_kind_view SELECT unit,count(*) AS count FROM sputnik_ssr GROUP BY unit";
1667 - $sth=prepare_st($dbh,$st) or (
1668 -- print localtime().": There was a problem preparing the statement $st: $DBI::errstr\n" and
1669 -+ print localtime().": There was a problem preparing the statement $st" and
1670 - return 0
1671 - );
1672 - execute_st($sth) or (
1673 -- print localtime().": There was a problem executing the statement $st: $DBI::errstr\n" and
1674 -+ print localtime().": There was a problem executing the statement $st" and
1675 - return 0
1676 - );
1677 - close_st($sth);
1678 -@@ -128,18 +128,18 @@
1679 -
1680 - my $db=read_config($config,'db_path',''); #database in the form dbi:$dbi_driver:$db_name:$host
1681 - my $dbh=open_db($db) or (
1682 -- print localtime().": There was a problem opening the database $db: $DBI::errstr\n" and
1683 -+ print localtime().": There was a problem opening the database $db\n" and
1684 - return 0
1685 - ); #we open the database
1686 -
1687 - #we calculate the min, max and average unigene length
1688 - my $st="SELECT MIN(length) AS min_seq_len, MAX(length) AS max_seq_len, AVG(length) AS avg_seq_len FROM sequence WHERE object_type='contig' OR object_type='singleton'";
1689 - my $sth=prepare_st($dbh,$st) or (
1690 -- print localtime().": There was a problem preparing the statement $st: $DBI::errstr\n" and
1691 -+ print localtime().": There was a problem preparing the statement $st" and
1692 - return 0
1693 - );
1694 - execute_st($sth) or (
1695 -- print localtime().": There was a problem executing the statement $st: $DBI::errstr\n" and
1696 -+ print localtime().": There was a problem executing the statement $st" and
1697 - return 0
1698 - );
1699 - my $min;my $max;my $avg;
1700 -@@ -154,11 +154,11 @@
1701 - }
1702 - $st="INSERT unigene_structure_annotation_view (min_seq_len,max_seq_len,avg_seq_len) VALUES ($min,$max,$avg)";
1703 - $sth=prepare_st($dbh,$st) or (
1704 -- print localtime().": There was a problem preparing the statement $st: $DBI::errstr\n" and
1705 -+ print localtime().": There was a problem preparing the statement $st" and
1706 - return 0
1707 - );
1708 - execute_st($sth) or (
1709 -- print localtime().": There was a problem executing the statement $st: $DBI::errstr\n" and
1710 -+ print localtime().": There was a problem executing the statement $st" and
1711 - return 0
1712 - );
1713 - close_st($sth);
1714 -@@ -173,20 +173,20 @@
1715 - #we calculate the min, max and average num ESTs per unigene
1716 - $st='CREATE TEMPORARY TABLE est_per_unigene SELECT count(*) AS num_est,unigene FROM est WHERE unigene IS NOT NULL GROUP BY unigene';
1717 - $sth=prepare_st($dbh,$st) or (
1718 -- print localtime().": There was a problem preparing the statement $st: $DBI::errstr\n" and
1719 -+ print localtime().": There was a problem preparing the statement $st" and
1720 - return 0
1721 - );
1722 - execute_st($sth) or (
1723 -- print localtime().": There was a problem executing the statement $st: $DBI::errstr\n" and
1724 -+ print localtime().": There was a problem executing the statement $st" and
1725 - return 0
1726 - );
1727 - my $st='SELECT MAX(num_est) AS max_num_est, AVG(num_est) AS avg_num_est FROM est_per_unigene';
1728 - $sth=prepare_st($dbh,$st) or (
1729 -- print localtime().": There was a problem preparing the statement $st: $DBI::errstr\n" and
1730 -+ print localtime().": There was a problem preparing the statement $st" and
1731 - return 0
1732 - );
1733 - execute_st($sth) or (
1734 -- print localtime().": There was a problem executing the statement $st: $DBI::errstr\n" and
1735 -+ print localtime().": There was a problem executing the statement $st" and
1736 - return 0
1737 - );
1738 - while (my @record=$sth->fetchrow_array){
1739 -@@ -196,11 +196,11 @@
1740 - close_st($sth);
1741 - $st="UPDATE unigene_structure_annotation_view SET max_est=$max,avg_est=$avg";
1742 - $sth=prepare_st($dbh,$st) or (
1743 -- print localtime().": There was a problem preparing the statement $st: $DBI::errstr\n" and
1744 -+ print localtime().": There was a problem preparing the statement $st" and
1745 - return 0
1746 - );
1747 - execute_st($sth) or (
1748 -- print localtime().": There was a problem executing the statement $st: $DBI::errstr\n" and
1749 -+ print localtime().": There was a problem executing the statement $st" and
1750 - return 0
1751 - );
1752 - close_st($sth);
1753 -@@ -213,11 +213,11 @@
1754 - #now the annotated unigenes
1755 - my $st="SELECT COUNT(*) FROM sequence WHERE annotation IS NOT NULL AND (object_type='contig' OR object_type='singleton')";
1756 - $sth=prepare_st($dbh,$st) or (
1757 -- print localtime().": There was a problem preparing the statement $st: $DBI::errstr\n" and
1758 -+ print localtime().": There was a problem preparing the statement $st" and
1759 - return 0
1760 - );
1761 - execute_st($sth) or (
1762 -- print localtime().": There was a problem executing the statement $st: $DBI::errstr\n" and
1763 -+ print localtime().": There was a problem executing the statement $st" and
1764 - return 0
1765 - );
1766 - my @record=$sth->fetchrow_array;
1767 -@@ -225,22 +225,22 @@
1768 - close_st($sth);
1769 - $st="UPDATE unigene_structure_annotation_view SET n_uni_with_annot=$n_annot";
1770 - $sth=prepare_st($dbh,$st) or (
1771 -- print localtime().": There was a problem preparing the statement $st: $DBI::errstr\n" and
1772 -+ print localtime().": There was a problem preparing the statement $st" and
1773 - return 0
1774 - );
1775 - execute_st($sth) or (
1776 -- print localtime().": There was a problem executing the statement $st: $DBI::errstr\n" and
1777 -+ print localtime().": There was a problem executing the statement $st" and
1778 - return 0
1779 - );
1780 - close_st($sth);
1781 - #now the full len
1782 - my $st="SELECT COUNT(*) FROM sequence WHERE full_length IS NOT NULL AND (object_type='contig' OR object_type='singleton')";
1783 - $sth=prepare_st($dbh,$st) or (
1784 -- print localtime().": There was a problem preparing the statement $st: $DBI::errstr\n" and
1785 -+ print localtime().": There was a problem preparing the statement $st" and
1786 - return 0
1787 - );
1788 - execute_st($sth) or (
1789 -- print localtime().": There was a problem executing the statement $st: $DBI::errstr\n" and
1790 -+ print localtime().": There was a problem executing the statement $st" and
1791 - return 0
1792 - );
1793 - @record=$sth->fetchrow_array;
1794 -@@ -248,11 +248,11 @@
1795 - close_st($sth);
1796 - $st="UPDATE unigene_structure_annotation_view SET n_uni_with_full_len=$n_annot";
1797 - $sth=prepare_st($dbh,$st) or (
1798 -- print localtime().": There was a problem preparing the statement $st: $DBI::errstr\n" and
1799 -+ print localtime().": There was a problem preparing the statement $st" and
1800 - return 0
1801 - );
1802 - execute_st($sth) or (
1803 -- print localtime().": There was a problem executing the statement $st: $DBI::errstr\n" and
1804 -+ print localtime().": There was a problem executing the statement $st" and
1805 - return 0
1806 - );
1807 - close_st($sth);
1808 -@@ -263,14 +263,14 @@
1809 - my $dbh=shift;
1810 - my $values=shift;
1811 - my $sth=prepare_st($dbh,$st) or (
1812 -- print localtime().": There was a problem preparing the statement $st: $DBI::errstr\n" and
1813 -+ print localtime().": There was a problem preparing the statement $st" and
1814 - return 0
1815 - );
1816 - my $i=1;
1817 - foreach my $value (@$values){
1818 - $sth->bind_param($i,$value);
1819 - execute_st($sth) or (
1820 -- print localtime().": There was a problem executing the statement $st: $DBI::errstr\n" and
1821 -+ print localtime().": There was a problem executing the statement $st" and
1822 - return 0
1823 - );
1824 - $i++;
1825 -@@ -282,7 +282,7 @@
1826 - my $dbh=shift;
1827 - my $intervals=shift;
1828 - my $sth=prepare_st($dbh,$st) or (
1829 -- print localtime().": There was a problem preparing the statement $st: $DBI::errstr\n" and
1830 -+ print localtime().": There was a problem preparing the statement $st" and
1831 - return 0
1832 - );
1833 - my $bottom;
1834 -@@ -293,7 +293,7 @@
1835 - $sth->bind_param(1,$bottom);
1836 - $sth->bind_param(2,$top);
1837 - execute_st($sth) or (
1838 -- print localtime().": There was a problem executing the statement $st: $DBI::errstr\n" and
1839 -+ print localtime().": There was a problem executing the statement $st" and
1840 - return 0
1841 - );
1842 - my @record=$sth->fetchrow_array;
1843 -@@ -329,16 +329,16 @@
1844 -
1845 - my $db=read_config($config,'db_path',''); #database in the form dbi:$dbi_driver:$db_name:$host
1846 - my $dbh=open_db($db) or (
1847 -- print localtime().": There was a problem opening the database $db: $DBI::errstr\n" and
1848 -+ print localtime().": There was a problem opening the database $db\n" and
1849 - return 0
1850 - ); #we open the database
1851 - my $st="INSERT psnp_accessions_view (accession) SELECT DISTINCT accession FROM putative_snp_seq";
1852 - my $sth=prepare_st($dbh,$st) or (
1853 -- print localtime().": There was a problem preparing the statement $st: $DBI::errstr\n" and
1854 -+ print localtime().": There was a problem preparing the statement $st" and
1855 - return 0
1856 - );
1857 - execute_st($sth) or (
1858 -- print localtime().": There was a problem executing the statement $st: $DBI::errstr\n" and
1859 -+ print localtime().": There was a problem executing the statement $st" and
1860 - return 0
1861 - );
1862 - close_st($sth);
1863 -@@ -354,26 +354,26 @@
1864 -
1865 - my $db=read_config($config,'db_path',''); #database in the form dbi:$dbi_driver:$db_name:$host
1866 - my $dbh=open_db($db) or (
1867 -- print localtime().": There was a problem opening the database $db: $DBI::errstr\n" and
1868 -+ print localtime().": There was a problem opening the database $db\n" and
1869 - return 0
1870 - ); #we open the database
1871 - my $st="CREATE TEMPORARY TABLE psnp_mutations_temp (nucleotides CHAR(10),is_snp BOOL,INDEX(nucleotides,is_snp)) SELECT GROUP_CONCAT(DISTINCT(putative_snp_seq.nucleotide) ORDER BY putative_snp_seq.nucleotide) AS nucleotides,putative_snp.is_snp FROM putative_snp_seq,putative_snp WHERE putative_snp_seq.psnp_id=putative_snp.psnp_id AND putative_snp_seq.nucleotide!='*' AND putative_snp.is_indel=0 GROUP BY putative_snp_seq.psnp_id";
1872 - my $sth=prepare_st($dbh,$st) or (
1873 -- print localtime().": There was a problem preparing the statement $st: $DBI::errstr\n" and
1874 -+ print localtime().": There was a problem preparing the statement $st" and
1875 - return 0
1876 - );
1877 - execute_st($sth) or (
1878 -- print localtime().": There was a problem executing the statement $st: $DBI::errstr\n" and
1879 -+ print localtime().": There was a problem executing the statement $st" and
1880 - return 0
1881 - );
1882 - close_st($sth);
1883 - $st="INSERT INTO psnp_mutations_view (mutations,is_snp,count) SELECT nucleotides,is_snp,COUNT(*) AS count FROM psnp_mutations_temp WHERE LENGTH(nucleotides)=3 GROUP BY nucleotides,is_snp";
1884 - $sth=prepare_st($dbh,$st) or (
1885 -- print localtime().": There was a problem preparing the statement $st: $DBI::errstr\n" and
1886 -+ print localtime().": There was a problem preparing the statement $st" and
1887 - return 0
1888 - );
1889 - execute_st($sth) or (
1890 -- print localtime().": There was a problem executing the statement $st: $DBI::errstr\n" and
1891 -+ print localtime().": There was a problem executing the statement $st" and
1892 - return 0
1893 - );
1894 - close_st($sth);
1895 -@@ -389,16 +389,16 @@
1896 -
1897 - my $db=read_config($config,'db_path',''); #database in the form dbi:$dbi_driver:$db_name:$host
1898 - my $dbh=open_db($db) or (
1899 -- print localtime().": There was a problem opening the database $db: $DBI::errstr\n" and
1900 -+ print localtime().": There was a problem opening the database $db\n" and
1901 - return 0
1902 - ); #we open the database
1903 - my $st="INSERT reciprocal_species_view (species,type) SELECT species,type FROM reciprocal_similar_sequences GROUP BY species";
1904 - my $sth=prepare_st($dbh,$st) or (
1905 -- print localtime().": There was a problem preparing the statement $st: $DBI::errstr\n" and
1906 -+ print localtime().": There was a problem preparing the statement $st" and
1907 - return 0
1908 - );
1909 - execute_st($sth) or (
1910 -- print localtime().": There was a problem executing the statement $st: $DBI::errstr\n" and
1911 -+ print localtime().": There was a problem executing the statement $st" and
1912 - return 0
1913 - );
1914 - close_st($sth);
1915 -@@ -416,46 +416,46 @@
1916 -
1917 - my $db=read_config($config,'db_path',''); #database in the form dbi:$dbi_driver:$db_name:$host
1918 - my $dbh=open_db($db) or (
1919 -- print localtime().": There was a problem opening the database $db: $DBI::errstr\n" and
1920 -+ print localtime().": There was a problem opening the database $db\n" and
1921 - return 0
1922 - ); #we open the database
1923 - my $st="INSERT INTO go_uni_aspect_view (db,aspect,num_unigenes,word) SELECT go.db,go.aspect,count(DISTINCT go.seq_id) AS num_unigenes, CONCAT(go.aspect,go.db) AS word FROM clone,go,est WHERE est.clone=clone.name AND go.seq_id=est.unigene AND go.is_slim=1 GROUP BY word";
1924 - my $sth=prepare_st($dbh,$st) or (
1925 -- print localtime().": There was a problem preparing the statement $st: $DBI::errstr\n" and
1926 -+ print localtime().": There was a problem preparing the statement $st" and
1927 - return 0
1928 - );
1929 - execute_st($sth) or (
1930 -- print localtime().": There was a problem executing the statement $st: $DBI::errstr\n" and
1931 -+ print localtime().": There was a problem executing the statement $st" and
1932 - return 0
1933 - );
1934 - close_st($sth);
1935 - $st="INSERT INTO go_uni_aspect_library_view (db,aspect,library,num_unigenes,word) SELECT go.db,go.aspect,clone.library,count(DISTINCT go.seq_id) AS num_unigenes, CONCAT(go.aspect,go.db,clone.library) AS word FROM clone,go,est WHERE est.clone=clone.name AND go.seq_id=est.unigene AND go.is_slim=1 GROUP BY word";
1936 - $sth=prepare_st($dbh,$st) or (
1937 -- print localtime().": There was a problem preparing the statement $st: $DBI::errstr\n" and
1938 -+ print localtime().": There was a problem preparing the statement $st" and
1939 - return 0
1940 - );
1941 - execute_st($sth) or (
1942 -- print localtime().": There was a problem executing the statement $st: $DBI::errstr\n" and
1943 -+ print localtime().": There was a problem executing the statement $st" and
1944 - return 0
1945 - );
1946 - close_st($sth);
1947 - $st="INSERT INTO go_term_aspect_view (db,aspect,go_id,definition,num_go,word) SELECT db,go.aspect,go.go_id,definition,count(DISTINCT go.seq_id) AS num_go, CONCAT(go.go_id,go.aspect,db) AS word FROM go,go_def WHERE is_slim=1 AND go_def.go_id=go.go_id GROUP BY word";
1948 - $sth=prepare_st($dbh,$st) or (
1949 -- print localtime().": There was a problem preparing the statement $st: $DBI::errstr\n" and
1950 -+ print localtime().": There was a problem preparing the statement $st" and
1951 - return 0
1952 - );
1953 - execute_st($sth) or (
1954 -- print localtime().": There was a problem executing the statement $st: $DBI::errstr\n" and
1955 -+ print localtime().": There was a problem executing the statement $st" and
1956 - return 0
1957 - );
1958 - close_st($sth);
1959 - $st="INSERT INTO go_term_aspect_library_view (db,aspect,go_id,definition,library,num_go,word) SELECT db,go.aspect,go.go_id,definition,clone.library,count(DISTINCT go.seq_id) AS num_go, CONCAT(go.go_id,go.aspect,db,clone.library) AS word FROM go,go_def,est,clone WHERE is_slim=1 AND go_def.go_id=go.go_id AND go.seq_id=est.unigene AND est.clone=clone.name GROUP BY word";
1960 - $sth=prepare_st($dbh,$st) or (
1961 -- print localtime().": There was a problem preparing the statement $st: $DBI::errstr\n" and
1962 -+ print localtime().": There was a problem preparing the statement $st" and
1963 - return 0
1964 - );
1965 - execute_st($sth) or (
1966 -- print localtime().": There was a problem executing the statement $st: $DBI::errstr\n" and
1967 -+ print localtime().": There was a problem executing the statement $st" and
1968 - return 0
1969 - );
1970 - close_st($sth);
1971 -@@ -473,27 +473,27 @@
1972 -
1973 - my $db=read_config($config,'db_path',''); #database in the form dbi:$dbi_driver:$db_name:$host
1974 - my $dbh=open_db($db) or (
1975 -- print localtime().": There was a problem opening the database $db: $DBI::errstr\n" and
1976 -+ print localtime().": There was a problem opening the database $db\n" and
1977 - return 0
1978 - ); #we open the database
1979 - my $st="CREATE TEMPORARY TABLE super_count (INDEX(type)) SELECT superunigene,count(*)>1 AS type FROM superunigene GROUP BY superunigene";
1980 - my $sth=prepare_st($dbh,$st) or (
1981 -- print localtime().": There was a problem preparing the statement $st: $DBI::errstr\n" and
1982 -+ print localtime().": There was a problem preparing the statement $st" and
1983 - return 0
1984 - );
1985 - execute_st($sth) or (
1986 -- print localtime().": There was a problem executing the statement $st: $DBI::errstr\n" and
1987 -+ print localtime().": There was a problem executing the statement $st" and
1988 - return 0
1989 - );
1990 - close_st($sth);
1991 -
1992 - $st="INSERT INTO superunigene_view (type,num_superunigenes) SELECT type,count(*) AS num_superunigenes FROM super_count GROUP BY type";
1993 - $sth=prepare_st($dbh,$st) or (
1994 -- print localtime().": There was a problem preparing the statement $st: $DBI::errstr\n" and
1995 -+ print localtime().": There was a problem preparing the statement $st" and
1996 - return 0
1997 - );
1998 - execute_st($sth) or (
1999 -- print localtime().": There was a problem executing the statement $st: $DBI::errstr\n" and
2000 -+ print localtime().": There was a problem executing the statement $st" and
2001 - return 0
2002 - );
2003 - close_st($sth);
2004 -@@ -510,17 +510,17 @@
2005 -
2006 - my $db=read_config($config,'db_path',''); #database in the form dbi:$dbi_driver:$db_name:$host
2007 - my $dbh=open_db($db) or (
2008 -- print localtime().": There was a problem opening the database $db: $DBI::errstr\n" and
2009 -+ print localtime().": There was a problem opening the database $db\n" and
2010 - return 0
2011 - ); #we open the database
2012 -
2013 - my $st="INSERT INTO unigene_view (type,num_unigenes) SELECT object_type,count(*) AS num_unigenes FROM sequence WHERE object_type='contig' OR object_type='singleton' GROUP BY object_type";
2014 - my $sth=prepare_st($dbh,$st) or (
2015 -- print localtime().": There was a problem preparing the statement $st: $DBI::errstr\n" and
2016 -+ print localtime().": There was a problem preparing the statement $st" and
2017 - return 0
2018 - );
2019 - execute_st($sth) or (
2020 -- print localtime().": There was a problem executing the statement $st: $DBI::errstr\n" and
2021 -+ print localtime().": There was a problem executing the statement $st" and
2022 - return 0
2023 - );
2024 - close_st($sth);
2025 -@@ -539,7 +539,7 @@
2026 - clean_tables($config,@table) or return 0;
2027 - my $db=read_config($config,'db_path',''); #database in the form dbi:$dbi_driver:$db_name:$host
2028 - my $dbh=open_db($db) or (
2029 -- print localtime().": There was a problem opening the database $db: $DBI::errstr\n" and
2030 -+ print localtime().": There was a problem opening the database $db\n" and
2031 - return 0
2032 - ); #we open the database
2033 -
2034 -@@ -547,11 +547,11 @@
2035 - #clones per library
2036 - my $st="SELECT clone.library,COUNT(distinct clone.name) AS num_clones FROM clone GROUP BY clone.library";
2037 - my $sth=prepare_st($dbh,$st) or (
2038 -- print localtime().": There was a problem preparing the statement $st: $DBI::errstr\n" and
2039 -+ print localtime().": There was a problem preparing the statement $st" and
2040 - return 0
2041 - );
2042 - execute_st($sth) or (
2043 -- print localtime().": There was a problem executing the statement $st: $DBI::errstr\n" and
2044 -+ print localtime().": There was a problem executing the statement $st" and
2045 - return 0
2046 - );
2047 - my %clones;
2048 -@@ -563,11 +563,11 @@
2049 - #raw_est per library
2050 - $st="SELECT clone.library,COUNT(*) AS num_raw_est FROM est,clone WHERE est.clone=clone.name AND raw_seq IS NOT NULL GROUP BY clone.library";
2051 - $sth=prepare_st($dbh,$st) or (
2052 -- print localtime().": There was a problem preparing the statement $st: $DBI::errstr\n" and
2053 -+ print localtime().": There was a problem preparing the statement $st" and
2054 - return 0
2055 - );
2056 - execute_st($sth) or (
2057 -- print localtime().": There was a problem executing the statement $st: $DBI::errstr\n" and
2058 -+ print localtime().": There was a problem executing the statement $st" and
2059 - return 0
2060 - );
2061 - my %raw_est;
2062 -@@ -579,11 +579,11 @@
2063 - #clean_est per library
2064 - $st='SELECT clone.library,COUNT(*) AS num_clean_est,AVG(sequence.length) AS mean_length,STD(sequence.length) AS std_dev FROM est,sequence,clone WHERE est.processed_seq=sequence.name AND est.clone=clone.name GROUP BY clone.library;';
2065 - $sth=prepare_st($dbh,$st) or (
2066 -- print localtime().": There was a problem preparing the statement $st: $DBI::errstr\n" and
2067 -+ print localtime().": There was a problem preparing the statement $st" and
2068 - return 0
2069 - );
2070 - execute_st($sth) or (
2071 -- print localtime().": There was a problem executing the statement $st: $DBI::errstr\n" and
2072 -+ print localtime().": There was a problem executing the statement $st" and
2073 - return 0
2074 - );
2075 - my %clean_est;
2076 -@@ -599,11 +599,11 @@
2077 - #singletons per library
2078 - $st="SELECT clone.library,COUNT(distinct sequence.name) AS num_singletons FROM clone,sequence,est WHERE sequence.name=est.unigene AND est.clone=clone.name AND sequence.object_type='singleton' GROUP BY clone.library";
2079 - $sth=prepare_st($dbh,$st) or (
2080 -- print localtime().": There was a problem preparing the statement $st: $DBI::errstr\n" and
2081 -+ print localtime().": There was a problem preparing the statement $st" and
2082 - return 0
2083 - );
2084 - execute_st($sth) or (
2085 -- print localtime().": There was a problem executing the statement $st: $DBI::errstr\n" and
2086 -+ print localtime().": There was a problem executing the statement $st" and
2087 - return 0
2088 - );
2089 - my %singletons;
2090 -@@ -615,11 +615,11 @@
2091 - #contigs per library
2092 - $st="SELECT clone.library,COUNT(distinct sequence.name) AS num_contigs FROM clone,sequence,est WHERE sequence.name=est.unigene AND est.clone=clone.name AND sequence.object_type='contig' GROUP BY clone.library";
2093 - $sth=prepare_st($dbh,$st) or (
2094 -- print localtime().": There was a problem preparing the statement $st: $DBI::errstr\n" and
2095 -+ print localtime().": There was a problem preparing the statement $st" and
2096 - return 0
2097 - );
2098 - execute_st($sth) or (
2099 -- print localtime().": There was a problem executing the statement $st: $DBI::errstr\n" and
2100 -+ print localtime().": There was a problem executing the statement $st" and
2101 - return 0
2102 - );
2103 - my %contigs;
2104 -@@ -631,11 +631,11 @@
2105 - #unigenes per library
2106 - $st="SELECT clone.library,COUNT(distinct unigene) AS num_unigenes FROM est,clone WHERE est.clone=clone.name GROUP BY clone.library";
2107 - $sth=prepare_st($dbh,$st) or (
2108 -- print localtime().": There was a problem preparing the statement $st: $DBI::errstr\n" and
2109 -+ print localtime().": There was a problem preparing the statement $st" and
2110 - return 0
2111 - );
2112 - execute_st($sth) or (
2113 -- print localtime().": There was a problem executing the statement $st: $DBI::errstr\n" and
2114 -+ print localtime().": There was a problem executing the statement $st" and
2115 - return 0
2116 - );
2117 - my %unigenes;
2118 -@@ -647,11 +647,11 @@
2119 - #full length per library
2120 - $st="SELECT clone.library,COUNT(distinct sequence.name) AS num_full_len FROM clone,sequence,est WHERE sequence.name=est.unigene AND est.clone=clone.name AND sequence.full_length IS NOT NULL GROUP BY clone.library";
2121 - $sth=prepare_st($dbh,$st) or (
2122 -- print localtime().": There was a problem preparing the statement $st: $DBI::errstr\n" and
2123 -+ print localtime().": There was a problem preparing the statement $st" and
2124 - return 0
2125 - );
2126 - execute_st($sth) or (
2127 -- print localtime().": There was a problem executing the statement $st: $DBI::errstr\n" and
2128 -+ print localtime().": There was a problem executing the statement $st" and
2129 - return 0
2130 - );
2131 - my %full_len;
2132 -@@ -663,21 +663,21 @@
2133 - #spec unigenes length per library
2134 - $st="CREATE TEMPORARY TABLE uni_library_count (PRIMARY KEY(name), INDEX (num_lib))SELECT sequence.name, COUNT(DISTINCT clone.library) AS num_lib, clone.library AS lib_concat FROM sequence,est,clone WHERE sequence.name=est.unigene AND est.clone=clone.name GROUP BY sequence.name";
2135 - $sth=prepare_st($dbh,$st) or (
2136 -- print localtime().": There was a problem preparing the statement $st: $DBI::errstr\n" and
2137 -+ print localtime().": There was a problem preparing the statement $st" and
2138 - return 0
2139 - );
2140 - execute_st($sth) or (
2141 -- print localtime().": There was a problem executing the statement $st: $DBI::errstr\n" and
2142 -+ print localtime().": There was a problem executing the statement $st" and
2143 - return 0
2144 - );
2145 - close_st($sth);
2146 - $st="SELECT lib_concat as library,COUNT(*) AS num_unigenes_ex FROM uni_library_count WHERE num_lib=1 GROUP BY lib_concat";
2147 - $sth=prepare_st($dbh,$st) or (
2148 -- print localtime().": There was a problem preparing the statement $st: $DBI::errstr\n" and
2149 -+ print localtime().": There was a problem preparing the statement $st" and
2150 - return 0
2151 - );
2152 - execute_st($sth) or (
2153 -- print localtime().": There was a problem executing the statement $st: $DBI::errstr\n" and
2154 -+ print localtime().": There was a problem executing the statement $st" and
2155 - return 0
2156 - );
2157 - my %spec_unigenes;
2158 -@@ -689,21 +689,21 @@
2159 - #spec contigs per library
2160 - $st="CREATE TEMPORARY TABLE contig_library_count (PRIMARY KEY(name), INDEX (num_lib))SELECT sequence.name, COUNT(DISTINCT clone.library) AS num_lib, clone.library AS lib_concat FROM sequence,est,clone WHERE sequence.name=est.unigene AND est.clone=clone.name AND sequence.object_type='contig' GROUP BY sequence.name";
2161 - $sth=prepare_st($dbh,$st) or (
2162 -- print localtime().": There was a problem preparing the statement $st: $DBI::errstr\n" and
2163 -+ print localtime().": There was a problem preparing the statement $st" and
2164 - return 0
2165 - );
2166 - execute_st($sth) or (
2167 -- print localtime().": There was a problem executing the statement $st: $DBI::errstr\n" and
2168 -+ print localtime().": There was a problem executing the statement $st" and
2169 - return 0
2170 - );
2171 - close_st($sth);
2172 - $st="SELECT lib_concat as library,COUNT(*) AS num_contigs_ex FROM contig_library_count WHERE num_lib=1 GROUP BY lib_concat";
2173 - $sth=prepare_st($dbh,$st) or (
2174 -- print localtime().": There was a problem preparing the statement $st: $DBI::errstr\n" and
2175 -+ print localtime().": There was a problem preparing the statement $st" and
2176 - return 0
2177 - );
2178 - execute_st($sth) or (
2179 -- print localtime().": There was a problem executing the statement $st: $DBI::errstr\n" and
2180 -+ print localtime().": There was a problem executing the statement $st" and
2181 - return 0
2182 - );
2183 - my %spec_contigs;
2184 -@@ -715,21 +715,21 @@
2185 - #spec singletons per library
2186 - $st="CREATE TEMPORARY TABLE singleton_library_count (PRIMARY KEY(name), INDEX (num_lib))SELECT sequence.name, COUNT(DISTINCT clone.library) AS num_lib, clone.library AS lib_concat FROM sequence,est,clone WHERE sequence.name=est.unigene AND est.clone=clone.name AND sequence.object_type='singleton' GROUP BY sequence.name";
2187 - $sth=prepare_st($dbh,$st) or (
2188 -- print localtime().": There was a problem preparing the statement $st: $DBI::errstr\n" and
2189 -+ print localtime().": There was a problem preparing the statement $st" and
2190 - return 0
2191 - );
2192 - execute_st($sth) or (
2193 -- print localtime().": There was a problem executing the statement $st: $DBI::errstr\n" and
2194 -+ print localtime().": There was a problem executing the statement $st" and
2195 - return 0
2196 - );
2197 - close_st($sth);
2198 - $st="SELECT lib_concat as library,COUNT(*) AS num_singletons_ex FROM singleton_library_count WHERE num_lib=1 GROUP BY lib_concat";
2199 - $sth=prepare_st($dbh,$st) or (
2200 -- print localtime().": There was a problem preparing the statement $st: $DBI::errstr\n" and
2201 -+ print localtime().": There was a problem preparing the statement $st" and
2202 - return 0
2203 - );
2204 - execute_st($sth) or (
2205 -- print localtime().": There was a problem executing the statement $st: $DBI::errstr\n" and
2206 -+ print localtime().": There was a problem executing the statement $st" and
2207 - return 0
2208 - );
2209 - my %spec_singletons;
2210 -@@ -742,7 +742,7 @@
2211 - #now we have all the data and we should store it in the view
2212 - $st="INSERT INTO library_view (library, num_clones, num_raw_est, num_clean_est, num_singletons, num_contigs, num_unigenes, num_full_len, num_spec_singletons, num_spec_contigs, num_spec_unigenes,avg_est_len,std_est_len) VALUES (?,?,?,?,?,?,?,?,?,?,?,?,?)";
2213 - $sth=prepare_st($dbh,$st) or (
2214 -- print localtime().": There was a problem preparing the statement $st: $DBI::errstr\n" and
2215 -+ print localtime().": There was a problem preparing the statement $st" and
2216 - return 0
2217 - );
2218 - foreach my $lib (keys(%libraries)){
2219 -@@ -760,7 +760,7 @@
2220 - $sth->bind_param(12,$avg_est_len{$lib});
2221 - $sth->bind_param(13,$std_est_len{$lib});
2222 - execute_st($sth) or (
2223 -- print localtime().": There was a problem executing the statement $st: $DBI::errstr\n" and
2224 -+ print localtime().": There was a problem executing the statement $st" and
2225 - return 0
2226 - );
2227 - }
2228 -@@ -776,12 +776,12 @@
2229 - my $config=shift;
2230 - my $dir = $$config{'chromat_dir'};
2231 - opendir DIR,$dir or (
2232 -- print localtime().": It was not possible to open the chromat directory $dir: $!\n" and
2233 -+ print localtime().": It was not possible to open the chromat directory: $dir\n" and
2234 - return 0
2235 - );
2236 - my @libraries = grep {/^[^\.]/} readdir(DIR);
2237 - if (!$libraries[0]){
2238 -- print localtime().": No libraries found in the libraries directory $dir: $!\n";
2239 -+ print localtime().": No libraries found in the libraries directory: $dir\n";
2240 - return 0;
2241 - }
2242 - close DIR;
2243 -@@ -791,18 +791,18 @@
2244 - my $db=read_config($config,'db_path','');
2245 - my $dbh=open_db($db);
2246 - unless ($dbh) {
2247 -- print localtime().": Database $dbh is not reachable: $DBI::errstr\n";
2248 -+ print localtime().": Database $dbh is not reachable\n";
2249 - return 0;
2250 - }
2251 - my $sth=prepare_st($dbh,$st) or (
2252 -- print localtime().": Unable to prepare statement: $st: $DBI::errstr\n" and
2253 -+ print localtime().": Unable to prepare statement: $st\n" and
2254 - return 0
2255 - );
2256 - foreach my $lib (@libraries){
2257 - $sth->bind_param(1,$lib);
2258 - $sth->execute() or (
2259 - print localtime().": There was a problem executing the statement:\n" and
2260 -- print localtime().": $st: : $DBI::errstr\n" and
2261 -+ print localtime().": $st:\n" and
2262 - print localtime().": with the library $lib:\n" and
2263 - return 0
2264 - );
2265 -@@ -818,7 +818,7 @@
2266 - my $db=read_config($config,'db_path','');
2267 - my $dbh; my $sth; #database and statements handlers
2268 - $dbh=open_db($db) or (
2269 -- print localtime().": There was a problem opening the database $db: $DBI::errstr\n" and
2270 -+ print localtime().": There was a problem opening the database $db\n" and
2271 - return 0
2272 - ); #we open the database
2273 - my $st="SELECT UNCOMPRESS(COMPRESS('holacaracola'))='holacaracola'";
2274 -@@ -841,7 +841,7 @@
2275 - if ($version){return $version}
2276 - my $dbh; my $sth; #database and statements handlers
2277 - $dbh=open_db($db) or (
2278 -- print localtime().": There was a problem opening the database $db: $DBI::errstr\n" and
2279 -+ print localtime().": There was a problem opening the database $db\n" and
2280 - return 0
2281 - ); #we open the database
2282 - $version=$dbh->get_info(18);
2283 -@@ -924,11 +924,11 @@
2284 - if (!$only_clean){ #nothing more to do because we just should clean
2285 - if (-r $file){
2286 - put_csv_into_db($config,$file,$table) or (
2287 -- print localtime().": There was a problem populating the table $table with file $file\n" and
2288 -+ print localtime().": There was a problem populating the table $table with file $file: $!\n" and
2289 - return 0
2290 - );
2291 - }else{
2292 -- print localtime().": WARNING no database file found, it should be $file\n";
2293 -+ print localtime().": WARNING no database file found, it should be $file: $!\n";
2294 - return 0;
2295 - }
2296 - }
2297 -@@ -945,11 +945,11 @@
2298 - if (!$only_clean){ #nothing more to do because we just should clean
2299 - if (-r $file){
2300 - put_csv_into_db($config,$file,$table) or (
2301 -- print localtime().": There was a problem populating the table $table with file $file\n" and
2302 -+ print localtime().": There was a problem populating the table $table with file $file: $!\n" and
2303 - return 0
2304 - );
2305 - }else{
2306 -- print localtime().": WARNING no working on file found, it should be $file\n";
2307 -+ print localtime().": WARNING no working_on_dat file found, it should be $file: $!\n";
2308 - return 0;
2309 - }
2310 - }
2311 -@@ -966,11 +966,11 @@
2312 - if (!$only_clean){ #nothing more to do because we just should clean
2313 - if (-r $file){
2314 - put_csv_into_db($config,$file,$table) or (
2315 -- print localtime().": There was a problem populating the table $table with file $file\n" and
2316 -+ print localtime().": There was a problem populating the table $table with file $file: $!\n" and
2317 - return 0
2318 - );
2319 - }else{
2320 -- print localtime().": WARNING no researcher file found, it should be $file\n";
2321 -+ print localtime().": WARNING no researcher file found, it should be $file: $!\n";
2322 - return 0;
2323 - }
2324 - }
2325 -@@ -987,11 +987,11 @@
2326 - if (!$only_clean){ #nothing more to do because we just should clean
2327 - if (-r $file){
2328 - put_csv_into_db($config,$file,$table) or (
2329 -- print localtime().": There was a problem populating the table $table with file $file\n" and
2330 -+ print localtime().": There was a problem populating the table $table with file $file: $!\n" and
2331 - return 0
2332 - );
2333 - }else{
2334 -- print localtime().": WARNING no marker-EST file found, it should be $file\n";
2335 -+ print localtime().": WARNING no marker-EST file found, it should be $file: $!\n";
2336 - return 0;
2337 - }
2338 - }
2339 -@@ -1026,11 +1026,11 @@
2340 - my $table = 'microarray_extract';
2341 - if (-r $file){
2342 - put_csv_into_db($config,$file,$table) or (
2343 -- print localtime().": There was a problem populating the table $table with file $file\n" and
2344 -+ print localtime().": There was a problem populating the table $table with file $file: $!\n" and
2345 - return 0
2346 - );
2347 - }else{
2348 -- print localtime().": WARNING no extracts file found, it should be $file\n";
2349 -+ print localtime().": WARNING no extracts file found, it should be $file: $!\n";
2350 - return 0;
2351 - }
2352 - #loading extract mixes
2353 -@@ -1038,11 +1038,11 @@
2354 - my $table = 'microarray_extract_mix';
2355 - if (-r $file){
2356 - put_csv_into_db($config,$file,$table) or (
2357 -- print localtime().": There was a problem populating the table $table with file $file\n" and
2358 -+ print localtime().": There was a problem populating the table $table with file $file: $!\n" and
2359 - return 0
2360 - );
2361 - }else{
2362 -- print localtime().": WARNING no extract mixes file found, it should be $file\n";
2363 -+ print localtime().": WARNING no extract mixes file found, it should be $file: $!\n";
2364 - return 0;
2365 - }
2366 - #loading the hybridizations
2367 -@@ -1050,18 +1050,18 @@
2368 - my $table = 'microarray_hybridization';
2369 - if (-r $file){
2370 - put_csv_into_db($config,$file,$table) or (
2371 -- print localtime().": There was a problem populating the table $table with file $file\n" and
2372 -+ print localtime().": There was a problem populating the table $table with file $file: $!\n" and
2373 - return 0
2374 - );
2375 - }else{
2376 -- print localtime().": WARNING no hybridizations file found, it should be $file\n";
2377 -+ print localtime().": WARNING no hybridizations file found, it should be $file: $!\n";
2378 - return 0;
2379 - }
2380 - my $file = read_config($config,'microarray_normalized_dat','');
2381 - my $table = 'microarray_normalized_expression';
2382 - if (-r $file){
2383 - open IN,"<$file" or (
2384 -- print localtime().": Imposible to open file: $file\n" and
2385 -+ print localtime().": Imposible to open file: $file: $!\n" and
2386 - return 0
2387 - );
2388 -
2389 -@@ -1099,15 +1099,15 @@
2390 - $sth->bind_param(4,$cv);
2391 - $i_hyb++;
2392 - $sth->execute or (
2393 -- print localtime().": Unable to execute stament: $st: $DBI::errstr\n" and
2394 -- print localtime().": With line: $line\n" and
2395 -+ print localtime().": Unable to execute stament: $st\n" and
2396 -+ print localtime().": With line: $line: $DBI::errstr\n" and
2397 - return 0
2398 - );
2399 - }
2400 - }
2401 - close IN;
2402 - }else{
2403 -- print localtime().": WARNING no normalized expression file found, it should be $file\n";
2404 -+ print localtime().": WARNING no normalized expression file found, it should be $file: $!\n";
2405 - return 0;
2406 - }
2407 -
2408 -@@ -1179,7 +1179,7 @@
2409 - #print $contents{$table},"\n";
2410 - create_table($db,$table,$contents{$table}) or $ok=0;
2411 - unless ($ok){
2412 -- print localtime().": Annotation table: $table from $db can't be created\n";
2413 -+ print localtime().": Annotation table: $table from $db can't be created: $DBI::errstr\n";
2414 - }
2415 - }
2416 - }
2417 -@@ -1200,7 +1200,7 @@
2418 - #if the table exist is removed
2419 - if (check_table($db,$table)) {drop_table($db,$table) or $ok=0}
2420 - unless ($ok){
2421 -- print localtime().": Annotation table: $table from $db can't be dropped\n";
2422 -+ print localtime().": Annotation table: $table from $db can't be dropped: $DBI::errstr\n";
2423 - }
2424 - }
2425 - }
2426 -@@ -1220,7 +1220,7 @@
2427 - my $db=read_config($config,'db_path','');
2428 -
2429 - open IN,"<$file" or (
2430 -- print localtime().": Imposible to open file $file: $!\n" and
2431 -+ print localtime().": Imposible to open file: $file: $!\n" and
2432 - return 0
2433 - );
2434 -
2435 -@@ -1235,10 +1235,13 @@
2436 - return 0;
2437 - }
2438 - my $sth=prepare_st($dbh,$st) or (
2439 -- print localtime().": Unable to prepare statement $st: $DBI::errstr\n" and
2440 -+ print localtime().": Unable to prepare statement: $st: $DBI::errstr\n" and
2441 - return 0
2442 - );
2443 - while ($line = <IN>){
2444 -+ if ($line =~ /^#/) {
2445 -+ next;
2446 -+ }
2447 - chomp ($line);
2448 - $line =~ s/"//g;
2449 - my @fields=split (',',$line);
2450 -@@ -1248,8 +1251,8 @@
2451 - $i++;
2452 - }
2453 - $sth->execute or (
2454 -- print localtime().": Unable to execute stament $st: $DBI::errstr\n" and
2455 -- print localtime().": With line: $line\n" and
2456 -+ print localtime().": Unable to execute stament: $st\n" and
2457 -+ print localtime().": With line: $line: $DBI::errstr\n" and
2458 - return 0
2459 - );
2460 - }
2461 -@@ -1312,7 +1315,7 @@
2462 - #here we read all the db structure, the table fields and contigs
2463 - my %db_structure=read_db_structure ($db_structure_file,$config);
2464 - unless (%db_structure) {
2465 -- print localtime().": There was a problem reading the database definition from file $db_structure_file: $!\n";
2466 -+ print localtime().": There was a problem reading the database definition from file: $db_structure_file";
2467 - return 0;
2468 - }
2469 - #the table is regenerated
2470 -@@ -1351,12 +1354,14 @@
2471 - #Here we check that the database is reachable and has all the necesary tables
2472 - $ok=check_db_structure($db_path,%db_structure);
2473 - }
2474 -- #print_db_structure(%db_structure);
2475 -+ if (!$ok) {
2476 -+ print_db_structure(%db_structure);
2477 -+ }
2478 - return $ok;
2479 - }
2480 -
2481 - #Here we check that the database is reachable and has all the necesary tables
2482 --#this is not enough becouse fields should be checked too, so TODO
2483 -+#this is not enough because fields should be checked too, so TODO
2484 - #(although not a very important thing anyway)
2485 - sub check_db_structure($\%) {
2486 - my $db=shift;
2487 -@@ -1375,6 +1380,8 @@
2488 - }
2489 - }
2490 - }
2491 -+ } else {
2492 -+ $ok=0;
2493 - }
2494 - if ($ok) {
2495 - print localtime().": Database structure seems ok\n";
2496 -@@ -1422,7 +1429,7 @@
2497 - print localtime().": Connection to the database server $db_path_no_name has failed: $DBI::errstr\n";
2498 - return 0;
2499 - }
2500 -- #Now we check if db exists and if does is dropped
2501 -+ #Now we check if db exists and if it does it is dropped
2502 - if(db_ok($db_path)){
2503 - #database exits, we should remove it
2504 - if(drop_db($db_path,$db_name)) {
2505 -@@ -1458,13 +1465,23 @@
2506 - sub populate_db ($\%) {
2507 - my $db=shift;
2508 - my $tables=shift;
2509 -+ my %t = %$tables;
2510 - my $ok=1;
2511 -
2512 -+ print "populate_db called with db=$db, tables=$tables\n";
2513 -+ #foreach my $table(keys(%t)) {
2514 -+ # print "table=$table, $t{$table}\n";
2515 -+ #}
2516 -+
2517 - my $table;
2518 - foreach $table(keys %$tables) {
2519 - if ($ok) {
2520 -- $ok=create_table($db,$table,${%{$tables}}{$table});
2521 -+ $ok=create_table($db,$table,$t{$table}); # avoid Can't use string ("38/64") as a HASH ref while "strict refs" in use at /opt/est2uni/pipe_db.pm line 1477.
2522 -+ if ($ok) {
2523 - print localtime().": Table $table created\n";
2524 -+ } else {
2525 -+ print localtime().": Table $table could not be created under dsn=$db: $DBI::errstr\n";
2526 -+ }
2527 - }
2528 - }
2529 - return $ok;
2530 -@@ -1476,7 +1493,7 @@
2531 - my $db=shift;
2532 - my $table_name=shift;
2533 - my $table_content=shift; #table content in sql format
2534 -- #first we check that the database is avaliable
2535 -+ #first we check that the database is available
2536 - my $ok=1;
2537 - unless (db_ok($db)) {
2538 - print localtime().": Something went wrong checking database: $db\n";
2539 -@@ -1488,9 +1505,13 @@
2540 - my $st="CREATE TABLE $table_name ($table_content);";
2541 - if($ok) {
2542 - $sth=prepare_st($dbh,$st) or $ok=0;
2543 -+ } else {
2544 -+ print localtime().": There was a problem preparing a statement: $DBI::errstr\n";
2545 - }
2546 - if ($ok) {
2547 - execute_st($sth) or $ok=0;
2548 -+ } else {
2549 -+ print localtime().": There was a problem executing a statement: $DBI::errstr\n";
2550 - }
2551 - #print $table;
2552 - $sth->finish();
2553 -@@ -1533,17 +1554,13 @@
2554 - #needs a db handler
2555 - sub close_db ($) {
2556 - my $dbh=shift;
2557 -- if ($dbh){
2558 -- $dbh->disconnect() or print localtime().": Cannot disconnect from database: $DBI::errstr\n";
2559 -- }
2560 -+ if ($dbh){$dbh->disconnect();}
2561 - }
2562 -
2563 - #needs a statement handler
2564 - sub close_st ($) {
2565 - my $sth=shift;
2566 -- if ($sth){
2567 -- $sth->finish() or print localtime().": Cannot finish execution over database: $DBI::errstr\n";
2568 -- }
2569 -+ if ($sth){$sth->finish();}
2570 - }
2571 -
2572 -
2573 -@@ -1563,9 +1580,7 @@
2574 - }
2575 - }
2576 -
2577 -- if ($dbh){
2578 -- $dbh->disconnect() or print localtime().": Cannot disconnect from database: $DBI::errstr\n";
2579 -- }
2580 -+ if ($dbh){$dbh->disconnect();}
2581 - return $ok;
2582 - }
2583 -
2584 -@@ -1581,9 +1596,7 @@
2585 - else {
2586 - $ok=0;
2587 - }
2588 -- if ($dbh){
2589 -- $dbh->disconnect() or print localtime().": Cannot disconnect from database: $DBI::errstr\n";
2590 -- }
2591 -+ if ($dbh){$dbh->disconnect();}
2592 - return $ok;
2593 - }
2594 -
2595 -@@ -1594,7 +1607,7 @@
2596 - my $ok=1;
2597 - #is the database to remove ok?
2598 - unless (db_ok($db)) {
2599 -- print localtime().": Something went wrong checking database $db: $DBI::errstr\n";
2600 -+ print localtime().": Something went wrong checking database: $db: $DBI::errstr\n";
2601 - $ok=0;
2602 - }
2603 - #we should open it
2604 -@@ -1619,7 +1632,7 @@
2605 - }
2606 - }
2607 - if ($ok) {$sth->finish();}
2608 -- if ($dbh){$dbh->disconnect() or print localtime().": Cannot disconnect from database: $DBI::errstr\n";}
2609 -+ if ($dbh){$dbh->disconnect();}
2610 - return $ok;
2611 - }
2612 -
2613
2614 diff --git a/sci-biology/est2uni/files/tables.sql.patch b/sci-biology/est2uni/files/tables.sql.patch
2615 deleted file mode 100644
2616 index 3a83de8..0000000
2617 --- a/sci-biology/est2uni/files/tables.sql.patch
2618 +++ /dev/null
2619 @@ -1,23 +0,0 @@
2620 ---- tables.sql.ori 2011-02-22 10:53:26.000000000 +0100
2621 -+++ tables.sql 2011-02-22 16:15:11.000000000 +0100
2622 -@@ -576,15 +576,15 @@
2623 - long_name CHAR(100),
2624 - version CHAR(40),
2625 - local_blast_name CHAR(100),
2626 -- blast_program CHAR(7),
2627 -- repository CHAR(100),
2628 -- web_site CHAR(100),
2629 -- kind CHAR(40),
2630 -+ blast_program ENUM('blastn', 'blastp', 'blastx', 'tblastn', 'tblastx'),
2631 -+ repository CHAR(255),
2632 -+ web_site CHAR(255),
2633 -+ kind ENUM('dna','pep'),
2634 - go_annot_format CHAR(40),
2635 - link_pre CHAR(200),
2636 - link_post CHAR(200),
2637 - local_hmmer_name CHAR(40),
2638 -- rec_sim_type CHAR(40),
2639 -+ rec_sim_type ENUM('', 'orthologue', 'synonymous'),
2640 - rec_sim_evalue CHAR(40),
2641 - orthologues_arabi_hack CHAR(1),
2642 - local_go_assoc_file CHAR(200),
2643
2644 diff --git a/sci-biology/est2uni/files/tgicl_files.patch b/sci-biology/est2uni/files/tgicl_files.patch
2645 deleted file mode 100644
2646 index ed7943a..0000000
2647 --- a/sci-biology/est2uni/files/tgicl_files.patch
2648 +++ /dev/null
2649 @@ -1,26 +0,0 @@
2650 ---- perl/est_clustering.pm.ori 2011-02-17 22:41:29.000000000 +0100
2651 -+++ perl/est_clustering.pm 2011-02-17 22:42:54.000000000 +0100
2652 -@@ -279,8 +279,11 @@
2653 - $command="cat ";
2654 - for ($i=1; $i<=$num_micros; $i++) # a loop for every directory created by tgicl
2655 - {
2656 -+ if (-e $temp_dir.$asm_dir.$i."/".$tgicl_ace_file)
2657 -+ {
2658 - $command=$command.$temp_dir.$asm_dir.$i."/".$tgicl_ace_file." ";
2659 - }
2660 -+ }
2661 - $command.=" >".$output_ace_file;
2662 - $tgicl_success=not(system($command));
2663 - unless ($tgicl_success)
2664 -@@ -295,8 +298,11 @@
2665 - $command="cat ";
2666 - for ($i=1; $i<=$num_micros; $i++) # a loop for every directory created by tgicl
2667 - {
2668 -+ if (-e $temp_dir.$asm_dir.$i."/".$tgicl_fasta_file)
2669 -+ {
2670 - $command=$command.$temp_dir.$asm_dir.$i."/".$tgicl_fasta_file." ";
2671 - }
2672 -+ }
2673 - $command.=" >".$output_contig_fasta_file;
2674 - $tgicl_success=not(system($command));
2675 - unless ($tgicl_success)
2676
2677 diff --git a/sci-biology/est2uni/metadata.xml b/sci-biology/est2uni/metadata.xml
2678 deleted file mode 100644
2679 index 2bc8930..0000000
2680 --- a/sci-biology/est2uni/metadata.xml
2681 +++ /dev/null
2682 @@ -1,9 +0,0 @@
2683 -<?xml version="1.0" encoding="UTF-8"?>
2684 -<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
2685 -<pkgmetadata>
2686 - <herd>sci-biology</herd>
2687 - <maintainer>
2688 - <email>mmokrejs@×××××××××××××××.cz</email>
2689 - <name>Martin Mokrejs</name>
2690 - </maintainer>
2691 -</pkgmetadata>