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-chemistry/coot/files/, sci-chemistry/coot/
Date: Wed, 29 Jun 2011 13:32:47
Message-Id: 767b48f97d415ca52c9aa904172fc1e24f5d5533.jlec@gentoo
1 commit: 767b48f97d415ca52c9aa904172fc1e24f5d5533
2 Author: Justin Lecher <jlec <AT> gentoo <DOT> org>
3 AuthorDate: Wed Jun 29 13:32:19 2011 +0000
4 Commit: Justin Lecher <jlec <AT> gentoo <DOT> org>
5 CommitDate: Wed Jun 29 13:32:19 2011 +0000
6 URL: http://git.overlays.gentoo.org/gitweb/?p=proj/sci.git;a=commit;h=767b48f9
7
8 Imported changes from tree
9
10 (Portage version: 2.2.0_alpha41/git/Linux x86_64, signed Manifest commit with key 70EB7916)
11
12 ---
13 sci-chemistry/coot/ChangeLog | 5 ++
14 sci-chemistry/coot/coot-9999.ebuild | 46 ++++++++++----------
15 sci-chemistry/coot/files/9999-clipper-config.patch | 17 +++++++
16 sci-chemistry/coot/files/9999-mmdb-config.patch | 18 ++++++++
17 sci-chemistry/coot/files/9999-test.patch | 16 +++++++
18 sci-chemistry/coot/metadata.xml | 8 ++--
19 6 files changed, 83 insertions(+), 27 deletions(-)
20
21 diff --git a/sci-chemistry/coot/ChangeLog b/sci-chemistry/coot/ChangeLog
22 index 2d688c2..c4d7981 100644
23 --- a/sci-chemistry/coot/ChangeLog
24 +++ b/sci-chemistry/coot/ChangeLog
25 @@ -2,6 +2,11 @@
26 # Copyright 1999-2011 Gentoo Foundation; Distributed under the GPL v2
27 # $Header: $
28
29 + 29 Jun 2011; Justin Lecher <jlec@g.o>
30 + +files/9999-clipper-config.patch, +files/9999-mmdb-config.patch,
31 + coot-9999.ebuild, +files/9999-test.patch, metadata.xml:
32 + Imported changes from tree
33 +
34 15 Jun 2011; Justin Lecher <jlec@g.o> -files/9999-align.patch,
35 coot-9999.ebuild:
36 Updated to current HEAD
37
38 diff --git a/sci-chemistry/coot/coot-9999.ebuild b/sci-chemistry/coot/coot-9999.ebuild
39 index 5561140..ecb5ff0 100644
40 --- a/sci-chemistry/coot/coot-9999.ebuild
41 +++ b/sci-chemistry/coot/coot-9999.ebuild
42 @@ -2,7 +2,7 @@
43 # Distributed under the terms of the GNU General Public License v2
44 # $Header: $
45
46 -EAPI="3"
47 +EAPI=3
48
49 PYTHON_DEPEND="2"
50
51 @@ -23,16 +23,17 @@ SRC_URI="test? ( http://www.biop.ox.ac.uk/coot/devel/greg-data.tar.gz )"
52 SLOT="0"
53 LICENSE="GPL-3"
54 KEYWORDS="~amd64 ~x86 ~amd64-linux ~x86-linux"
55 -IUSE="test"
56 +IUSE="+openmp test"
57
58 SCIDEPS="
59 >=sci-libs/ccp4-libs-6.1
60 >=sci-libs/clipper-20090520
61 >=sci-libs/coot-data-2
62 >=sci-libs/gsl-1.3
63 - sci-libs/mmdb
64 + >=sci-libs/mmdb-1.23
65 + <sci-libs/monomer-db-1
66 sci-chemistry/reduce
67 - sci-chemistry/refmac
68 + <sci-chemistry/refmac-5.6
69 sci-chemistry/probe"
70
71 XDEPS="
72 @@ -67,14 +68,20 @@ DEPEND="${RDEPEND}
73 S="${WORKDIR}"
74
75 pkg_setup() {
76 + if use openmp; then
77 + tc-has-openmp || die "Please use an OPENMP capable compiler"
78 + fi
79 python_set_active_version 2
80 }
81
82 PATCHES=(
83 + "${FILESDIR}"/${PV}-clipper-config.patch
84 "${FILESDIR}"/${PV}-lidia.patch
85 "${FILESDIR}"/${PV}-goocanvas.patch
86 "${FILESDIR}"/${PV}-include.patch
87 "${FILESDIR}"/${PV}-gl.patch
88 + "${FILESDIR}"/${PV}-mmdb-config.patch
89 + "${FILESDIR}"/${PV}-test.patch
90 )
91
92 src_unpack() {
93 @@ -85,12 +92,6 @@ src_unpack() {
94 src_prepare() {
95 base_src_prepare
96
97 - # Link against single-precision fftw
98 - sed -i \
99 - -e "s:\}fftw:}sfftw:g" \
100 - -e "s:\}rfftw:}srfftw:g" \
101 - "${S}"/macros/clipper.m4
102 -
103 cat >> src/svn-revision.cc <<- EOF
104 extern "C" {
105 int svn_revision() {
106 @@ -107,17 +108,15 @@ src_configure() {
107 # Yes, this is broken behavior.
108 econf \
109 --includedir='${prefix}/include/coot' \
110 - --with-gtkcanvas-prefix="${EPREFIX}"/usr \
111 - --with-clipper-prefix="${EPREFIX}"/usr \
112 - --with-mmdb-prefix="${EPREFIX}"/usr \
113 - --with-ssmlib-prefix="${EPREFIX}"/usr \
114 - --with-gtkgl-prefix="${EPREFIX}"/usr \
115 + --with-gtkcanvas-prefix="${EPREFIX}/usr" \
116 + --with-ssmlib-prefix="${EPREFIX}/usr" \
117 + --with-gtkgl-prefix="${EPREFIX}/usr" \
118 --with-guile \
119 - --with-python="${EPREFIX}"/usr \
120 + --with-python="${EPREFIX}/usr" \
121 --with-guile-gtk \
122 --with-gtk2 \
123 --with-pygtk \
124 - --enable-openmp
125 + $(use_enable openmp)
126 }
127
128 src_compile() {
129 @@ -133,16 +132,16 @@ src_test() {
130 export COOT_STANDARD_RESIDUES="${S}/standard-residues.pdb"
131 export COOT_SCHEME_DIR="${S}/scheme/"
132 export COOT_RESOURCES_FILE="${S}/cootrc"
133 - export COOT_PIXMAPS_DIR="${S}/pixmaps"
134 - export COOT_DATA_DIR="${S}"
135 - export COOT_PYTHON_DIR="${S}/python"
136 + export COOT_PIXMAPS_DIR="${S}/pixmaps/"
137 + export COOT_DATA_DIR="${S}/"
138 + export COOT_PYTHON_DIR="${S}/python/"
139 export PYTHONPATH="${COOT_PYTHON_DIR}:${PYTHONPATH}"
140 - export PYTHONHOME="${EPREFIX}"/usr
141 - export CCP4_SCR="${T}"/coot_test
142 + export PYTHONHOME="${EPREFIX}"/usr/
143 + export CCP4_SCR="${T}"/coot_test/
144 export CLIBD_MON="${EPREFIX}/usr/share/ccp4/data/monomers/"
145 export SYMINFO="${S}/syminfo.lib"
146
147 - export COOT_TEST_DATA_DIR="${S}"/data/greg-data
148 + export COOT_TEST_DATA_DIR="${S}"/data/greg-data/
149
150 cat > command-line-greg.scm <<- EOF
151 (use-modules (ice-9 greg))
152 @@ -169,4 +168,5 @@ src_test() {
153 einfo "SYMINFO ${SYMINFO}"
154
155 "${S}"/src/coot-real --no-graphics --script command-line-greg.scm || die
156 + "${S}"/src/coot-real --no-graphics --script python-tests/coot_unittest.py || die
157 }
158
159 diff --git a/sci-chemistry/coot/files/9999-clipper-config.patch b/sci-chemistry/coot/files/9999-clipper-config.patch
160 new file mode 100644
161 index 0000000..311b5e8
162 --- /dev/null
163 +++ b/sci-chemistry/coot/files/9999-clipper-config.patch
164 @@ -0,0 +1,17 @@
165 + macros/clipper.m4 | 3 +++
166 + 1 files changed, 3 insertions(+), 0 deletions(-)
167 +
168 +diff --git a/macros/clipper.m4 b/macros/clipper.m4
169 +index 0bf087a..d0e8b6b 100644
170 +--- a/macros/clipper.m4
171 ++++ b/macros/clipper.m4
172 +@@ -98,6 +98,9 @@ case $ac_cv_build_alias in
173 + ;;
174 + esac
175 +
176 ++CLIPPER_CXXFLAGS=`clipper-config --cflags`
177 ++CLIPPER_LDOPTS=`clipper-config --libs`
178 ++
179 + AC_MSG_CHECKING([for Clipper])
180 +
181 + LIBS="$save_LIBS $CLIPPER_LDOPTS"
182
183 diff --git a/sci-chemistry/coot/files/9999-mmdb-config.patch b/sci-chemistry/coot/files/9999-mmdb-config.patch
184 new file mode 100644
185 index 0000000..1d7cbd4
186 --- /dev/null
187 +++ b/sci-chemistry/coot/files/9999-mmdb-config.patch
188 @@ -0,0 +1,18 @@
189 + macros/mmdb.m4 | 4 ++++
190 + 1 files changed, 4 insertions(+), 0 deletions(-)
191 +
192 +diff --git a/macros/mmdb.m4 b/macros/mmdb.m4
193 +index b477597..d05cf66 100644
194 +--- a/macros/mmdb.m4
195 ++++ b/macros/mmdb.m4
196 +@@ -86,6 +86,10 @@ else
197 + ac_MMDB_LDOPTS="-lmmdb -lm"
198 + fi
199 +
200 ++PKG_CHECK_MODULES([MMDB],[mmdb >= 1.2])
201 ++ac_MMDB_LDOPTS="${MMDB_LIBS}"
202 ++ac_MMDB_CXXFLAGS="${MMDB_CFLAGS}"
203 ++
204 + AC_MSG_CHECKING([for MMDB])
205 +
206 + LIBS="$save_LIBS $ac_MMDB_LDOPTS"
207
208 diff --git a/sci-chemistry/coot/files/9999-test.patch b/sci-chemistry/coot/files/9999-test.patch
209 new file mode 100644
210 index 0000000..8cb79e6
211 --- /dev/null
212 +++ b/sci-chemistry/coot/files/9999-test.patch
213 @@ -0,0 +1,16 @@
214 + src/testing.cc | 4 +++-
215 + 1 files changed, 3 insertions(+), 1 deletions(-)
216 +
217 +diff --git a/src/testing.cc b/src/testing.cc
218 +index f767bf6..097b9b9 100644
219 +--- a/src/testing.cc
220 ++++ b/src/testing.cc
221 +@@ -86,6 +86,8 @@ std::string greg_test(const std::string &file_name) {
222 + const char *c = getenv("COOT_TEST_DATA_DIR");
223 + if (c) {
224 + dd = c;
225 ++ dd += "/";
226 ++ dd += file_name;
227 + } else {
228 + const char *d = getenv("HOME");
229 + if (d) {
230
231 diff --git a/sci-chemistry/coot/metadata.xml b/sci-chemistry/coot/metadata.xml
232 index d7156cf..702e073 100644
233 --- a/sci-chemistry/coot/metadata.xml
234 +++ b/sci-chemistry/coot/metadata.xml
235 @@ -1,10 +1,10 @@
236 <?xml version="1.0" encoding="UTF-8"?>
237 <!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
238 <pkgmetadata>
239 -<herd>sci</herd>
240 -<maintainer>
241 - <email>sci@g.o</email>
242 -</maintainer>
243 + <herd>sci</herd>
244 + <maintainer>
245 + <email>sci@g.o</email>
246 + </maintainer>
247 <maintainer>
248 <email>jlec@g.o</email>
249 <name>Justin Lecher</name>