1 |
commit: c16e51d89ade3ee46c780185a2aad20555ab154b |
2 |
Author: Kent Fredric <kentnl <AT> gentoo <DOT> org> |
3 |
AuthorDate: Mon Jul 17 23:55:34 2017 +0000 |
4 |
Commit: Kent Fredric <kentnl <AT> gentoo <DOT> org> |
5 |
CommitDate: Tue Jul 18 04:38:03 2017 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=c16e51d8 |
7 |
|
8 |
sci-biology/bioperl-db: EAPI6/-R1 Bump |
9 |
|
10 |
- Test infa overhauled slightly |
11 |
- EAPI6ified |
12 |
- More test changes planned |
13 |
- -r1 bump mostly for double-safety around EAPI6 changes |
14 |
|
15 |
Package-Manager: Portage-2.3.6, Repoman-2.3.2 |
16 |
|
17 |
sci-biology/bioperl-db/bioperl-db-1.6.9-r1.ebuild | 61 ++++++++++++++++++++++ |
18 |
.../bioperl-db/files/bioperl-db-1.6.9-db.patch | 57 ++++++++++++++++++++ |
19 |
2 files changed, 118 insertions(+) |
20 |
|
21 |
diff --git a/sci-biology/bioperl-db/bioperl-db-1.6.9-r1.ebuild b/sci-biology/bioperl-db/bioperl-db-1.6.9-r1.ebuild |
22 |
new file mode 100644 |
23 |
index 00000000000..fd3a4280fa0 |
24 |
--- /dev/null |
25 |
+++ b/sci-biology/bioperl-db/bioperl-db-1.6.9-r1.ebuild |
26 |
@@ -0,0 +1,61 @@ |
27 |
+# Copyright 1999-2017 Gentoo Foundation |
28 |
+# Distributed under the terms of the GNU General Public License v2 |
29 |
+ |
30 |
+EAPI=6 |
31 |
+ |
32 |
+BIOPERL_RELEASE=1.6.9 |
33 |
+ |
34 |
+DIST_NAME=BioPerl-DB |
35 |
+DIST_AUTHOR=CJFIELDS |
36 |
+DIST_VERSION=1.006900 |
37 |
+inherit perl-module |
38 |
+ |
39 |
+DESCRIPTION="Perl tools for bioinformatics - Perl API that accesses the BioSQL schema" |
40 |
+HOMEPAGE="http://www.bioperl.org/" |
41 |
+ |
42 |
+SLOT="0" |
43 |
+KEYWORDS="~amd64 ~x86" |
44 |
+IUSE="test" |
45 |
+ |
46 |
+DIST_TEST="do" # Parallelism probably bad |
47 |
+ |
48 |
+RDEPEND=" |
49 |
+ >=sci-biology/bioperl-${PV} |
50 |
+ dev-perl/DBD-mysql |
51 |
+ dev-perl/DBI |
52 |
+ sci-biology/biosql" |
53 |
+DEPEND="${RDEPEND} |
54 |
+ dev-perl/Module-Build |
55 |
+ test? ( |
56 |
+ dev-perl/Data-Stag |
57 |
+ dev-perl/Sub-Uplevel |
58 |
+ dev-perl/Test-Warn |
59 |
+ dev-perl/Test-Exception |
60 |
+ virtual/perl-Test-Simple |
61 |
+ ) |
62 |
+" |
63 |
+ |
64 |
+src_prepare() { |
65 |
+ if use test; then |
66 |
+ eapply "${FILESDIR}/${PN}-1.6.9-db.patch" |
67 |
+ einfo "Using the following configuration details for test database:" |
68 |
+ einfo " GENTOO_DB_TEST_HOST : ${GENTOO_DB_TEST_HOST:=localhost}" |
69 |
+ einfo " GENTOO_DB_TEST_USER : ${GENTOO_DB_TEST_USER:=portage}" |
70 |
+ einfo " GENTOO_DB_TEST_PORT : ${GENTOO_DB_TEST_PORT:=3306}" |
71 |
+ einfo " GENTOO_DB_TEST_PASSWOWRD: ${GENTOO_DB_TEST_PASSWORD:=sekrit}" |
72 |
+ einfo " GENTOO_DB_TEST_DATABASE : ${GENTOO_DB_TEST_DB:=biosql_test}" |
73 |
+ einfo "Please ensure the relevant mysql database is configured and/or tweak" |
74 |
+ einfo "environment variables to suit" |
75 |
+ export GENTOO_DB_TEST_HOST GENTOO_DB_TEST_USER GENTOO_DB_TEST_PORT GENTOO_DB_TEST_PASSWORD GENTOO_DB_TEST_DB |
76 |
+ fi |
77 |
+ perl-module_src_prepare |
78 |
+} |
79 |
+src_install() { |
80 |
+ mydoc="AUTHORS BUGS FAQ" |
81 |
+ perl-module_src_install |
82 |
+} |
83 |
+src_test() { |
84 |
+ einfo "Removing bundled test libraries t/lib" |
85 |
+ rm -r "${S}/t/lib" || die "Cannot remove t/lib" |
86 |
+ perl-module_src_test |
87 |
+} |
88 |
|
89 |
diff --git a/sci-biology/bioperl-db/files/bioperl-db-1.6.9-db.patch b/sci-biology/bioperl-db/files/bioperl-db-1.6.9-db.patch |
90 |
new file mode 100644 |
91 |
index 00000000000..9a2d5e7bb0b |
92 |
--- /dev/null |
93 |
+++ b/sci-biology/bioperl-db/files/bioperl-db-1.6.9-db.patch |
94 |
@@ -0,0 +1,57 @@ |
95 |
+From a63725a70ab6d5cbf419d1896007b49609ac5cfa Mon Sep 17 00:00:00 2001 |
96 |
+From: Kent Fredric <kentfredric@×××××.com> |
97 |
+Date: Tue, 18 Jul 2017 11:06:05 +1200 |
98 |
+Subject: [PATCH] Add env db test controls |
99 |
+ |
100 |
+--- |
101 |
+ Build.PL | 10 +++++----- |
102 |
+ t/DBTestHarness.pm | 11 ++++++----- |
103 |
+ 2 files changed, 11 insertions(+), 10 deletions(-) |
104 |
+ |
105 |
+diff --git a/Build.PL b/Build.PL |
106 |
+index ecc402e..4d55f3a 100755 |
107 |
+--- a/Build.PL |
108 |
++++ b/Build.PL |
109 |
+@@ -97,11 +97,11 @@ sub biosql_conf { |
110 |
+ or die "Error: could not write to config file '$config_file'\n"; |
111 |
+ |
112 |
+ my %config = (driver => $drivers[0], |
113 |
+- host => '127.0.0.1', |
114 |
+- user => 'root', |
115 |
+- port => 3306, |
116 |
+- password => '', |
117 |
+- dbname => 'bioseqdb', |
118 |
++ host => $ENV{GENTOO_DB_TEST_HOST}, |
119 |
++ user => $ENV{GENTOO_DB_TEST_USER}, |
120 |
++ port => $ENV{GENTOO_DB_TEST_PORT}, |
121 |
++ password => $ENV{GENTOO_DB_TEST_PASSWORD}, |
122 |
++ dbname => $ENV{GENTOO_DB_TEST_DB}, |
123 |
+ database => 'biosql', |
124 |
+ schema_sql => '../biosql-schema/sql/biosqldb-mysql.sql'); |
125 |
+ |
126 |
+diff --git a/t/DBTestHarness.pm b/t/DBTestHarness.pm |
127 |
+index b660429..bd0b3b7 100755 |
128 |
+--- a/t/DBTestHarness.pm |
129 |
++++ b/t/DBTestHarness.pm |
130 |
+@@ -47,12 +47,13 @@ my $counter=0; |
131 |
+ # Default settings as a hash |
132 |
+ my $dflt = { |
133 |
+ 'driver' => 'mysql', |
134 |
+- 'host' => 'localhost', |
135 |
+- 'user' => 'root', |
136 |
+- 'port' => undef, |
137 |
+- 'password' => '', |
138 |
++ 'host' => $ENV{GENTOO_DB_HOST}, |
139 |
++ 'user' => $ENV{GENTOO_DB_TEST_USER}, |
140 |
++ 'port' => ( defined $ENV{GENTOO_DB_TEST_PORT} and length $ENV{GENTOO_DB_TEST_PORT} ) ? |
141 |
++ $ENV{GENTOO_DB_TEST_PORT} : undef, |
142 |
++ 'password' => $ENV{GENTOO_DB_TEST_PASSWORD}, |
143 |
+ 'schema_sql' => ['../biosql-schema/sql/biosqldb-mysql.sql'], |
144 |
+- 'database' => 'biosql', |
145 |
++ 'database' => $ENV{GENTOO_DB_TEST_DB}, |
146 |
+ 'module' => 'Bio::DB::BioSQL::DBAdaptor' |
147 |
+ }; |
148 |
+ |
149 |
+-- |
150 |
+2.13.1 |
151 |
+ |