1 |
commit: baefa0bf89ac382b08e24e32646c176a475b4add |
2 |
Author: Honza Macháček <Hloupy.Honza <AT> centrum <DOT> cz> |
3 |
AuthorDate: Thu May 30 13:21:59 2013 +0000 |
4 |
Commit: Honza Macháček <Hloupy.Honza <AT> centrum <DOT> cz> |
5 |
CommitDate: Thu May 30 13:21:59 2013 +0000 |
6 |
URL: http://git.overlays.gentoo.org/gitweb/?p=proj/sci.git;a=commit;h=baefa0bf |
7 |
|
8 |
sci-chemistry/freeon improved, the ebuild of the latest snapshot added. sci-chemistry/nwchem bumped to 6.3, building docs allowed. |
9 |
|
10 |
--- |
11 |
sci-chemistry/freeon/ChangeLog | 8 ++ |
12 |
.../files/freeon-2012.05.03-no_internal_libs.patch | 50 +++++++ |
13 |
.../files/freeon-9999-no_internal_libs.patch | 47 +++++++ |
14 |
...freeon-9999.ebuild => freeon-2012.05.03.ebuild} | 21 ++- |
15 |
sci-chemistry/freeon/freeon-9999.ebuild | 9 ++ |
16 |
sci-chemistry/nwchem/ChangeLog | 6 + |
17 |
.../nwchem/files/nwchem-6.3-html_doc.patch | 82 ++++++++++++ |
18 |
sci-chemistry/nwchem/nwchem-6.3.ebuild | 146 +++++++++++++++++++++ |
19 |
8 files changed, 364 insertions(+), 5 deletions(-) |
20 |
|
21 |
diff --git a/sci-chemistry/freeon/ChangeLog b/sci-chemistry/freeon/ChangeLog |
22 |
index 25af9d7..4e266de 100644 |
23 |
--- a/sci-chemistry/freeon/ChangeLog |
24 |
+++ b/sci-chemistry/freeon/ChangeLog |
25 |
@@ -2,6 +2,14 @@ |
26 |
# Copyright 1999-2013 Gentoo Foundation; Distributed under the GPL v2 |
27 |
# $Header: $ |
28 |
|
29 |
+*freeon-2012.05.03 (30 May 2013) |
30 |
+ |
31 |
+ 30 May 2013; Honza Macháček <Hloupy.Honza@×××××××.cz> |
32 |
+ +freeon-2012.05.03.ebuild, freeon-9999.ebuild, |
33 |
+ +files/freeon-2012.05.03-no_internal_libs.patch, |
34 |
+ +files/freeon-9999-no_internal_libs.patch: |
35 |
+ Internal hdf5 and lapack removed, the ebuild of the latest snapshot added. |
36 |
+ |
37 |
22 Feb 2013; Justin Lecher <jlec@g.o> freeon-9999.ebuild, |
38 |
metadata.xml: |
39 |
Add missing dep on virtual/pkgconfig; bump to eapi=5; use pkg-config to |
40 |
|
41 |
diff --git a/sci-chemistry/freeon/files/freeon-2012.05.03-no_internal_libs.patch b/sci-chemistry/freeon/files/freeon-2012.05.03-no_internal_libs.patch |
42 |
new file mode 100644 |
43 |
index 0000000..e37622b |
44 |
--- /dev/null |
45 |
+++ b/sci-chemistry/freeon/files/freeon-2012.05.03-no_internal_libs.patch |
46 |
@@ -0,0 +1,50 @@ |
47 |
+diff -Naurp freeon-beta-2012-05-03.orig/Makefile.am freeon-beta-2012-05-03/Makefile.am |
48 |
+--- freeon-beta-2012-05-03.orig/Makefile.am 2012-05-04 03:53:04.000000000 +0000 |
49 |
++++ freeon-beta-2012-05-03/Makefile.am 2013-05-29 14:42:07.791473885 +0000 |
50 |
+@@ -5,18 +5,9 @@ ACLOCAL_AMFLAGS = -I m4 |
51 |
+ CPP = @CPP@ |
52 |
+ AM_CPPFLAGS = @AM_CPPFLAGS@ |
53 |
+ |
54 |
+-if INTERNAL_LAPACK |
55 |
+-INTERNAL_LAPACK_DIRS = lapack |
56 |
+-endif |
57 |
++SUBDIRS = Modules FreeON SCFeqs OneE QCTC HiCu TwoE ONX PostProcessing BasisSets tests Validate |
58 |
+ |
59 |
+-if INTERNAL_HDF5 |
60 |
+-INTERNAL_HDF5_DIRS = hdf5-1.8.3 |
61 |
+-HDF5_INCLUDES = -I$(srcdir)/hdf5-1.8.3/src -I$(builddir)/hdf5-1.8.3/src |
62 |
+-endif |
63 |
+- |
64 |
+-SUBDIRS = $(INTERNAL_LAPACK_DIRS) $(INTERNAL_HDF5_DIRS) Modules FreeON SCFeqs OneE QCTC HiCu TwoE ONX PostProcessing BasisSets tests Validate |
65 |
+- |
66 |
+-DIST_SUBDIRS = $(SUBDIRS) lapack hdf5-1.8.3 |
67 |
++DIST_SUBDIRS = $(SUBDIRS) |
68 |
+ |
69 |
+ EXTRA_DIST = fix_localversion.sh localversion FreeON.bibtex $(top_builddir)/latex/refman.pdf |
70 |
+ |
71 |
+--- freeon-beta-2012-05-03.orig/configure.ac 2012-05-04 04:38:47.000000000 +0000 |
72 |
++++ freeon-beta-2012-05-03/configure.ac 2013-05-29 15:04:02.886109082 +0000 |
73 |
+@@ -855,7 +855,6 @@ AC_MSG_RESULT([${use_internal_hdf5}]) |
74 |
+ |
75 |
+ AM_CONDITIONAL(INTERNAL_HDF5, [test "${use_internal_hdf5}" = "yes"]) |
76 |
+ |
77 |
+-AC_CONFIG_SUBDIRS([hdf5-1.8.3]) |
78 |
+ |
79 |
+ if test "${use_internal_hdf5}" = "yes"; then |
80 |
+ |
81 |
+@@ -1027,15 +1026,6 @@ Makefile |
82 |
+ documentation/main_page.h |
83 |
+ FreeON/Makefile |
84 |
+ Modules/Makefile |
85 |
+-lapack/Makefile |
86 |
+-lapack/install/Makefile |
87 |
+-lapack/blas/Makefile |
88 |
+-lapack/lapack/Makefile |
89 |
+-lapack/blas_testing/Makefile |
90 |
+-lapack/lapack_testing/Makefile |
91 |
+-lapack/lapack_testing/lin/Makefile |
92 |
+-lapack/lapack_testing/eig/Makefile |
93 |
+-lapack/lapack_testing/matgen/Makefile |
94 |
+ SCFeqs/Makefile |
95 |
+ OneE/Makefile |
96 |
+ QCTC/Makefile |
97 |
|
98 |
diff --git a/sci-chemistry/freeon/files/freeon-9999-no_internal_libs.patch b/sci-chemistry/freeon/files/freeon-9999-no_internal_libs.patch |
99 |
new file mode 100644 |
100 |
index 0000000..a908aa7 |
101 |
--- /dev/null |
102 |
+++ b/sci-chemistry/freeon/files/freeon-9999-no_internal_libs.patch |
103 |
@@ -0,0 +1,47 @@ |
104 |
+diff -Naurp freeon-9999.orig/Modules/Makefile.am freeon-9999/Modules/Makefile.am |
105 |
+--- freeon-9999.orig/Modules/Makefile.am 2013-05-28 08:09:39.000000000 +0000 |
106 |
++++ freeon-9999/Modules/Makefile.am 2013-05-29 14:32:24.879721200 +0000 |
107 |
+@@ -1,17 +1,5 @@ |
108 |
+ include $(top_srcdir)/make.inc |
109 |
+ |
110 |
+-if INTERNAL_LAPACK |
111 |
+-INTERNAL_LAPACK_DIRS = lapack |
112 |
+-endif |
113 |
+- |
114 |
+-if INTERNAL_HDF5 |
115 |
+-INTERNAL_HDF5_DIRS = hdf5-1.8.3 |
116 |
+-HDF5_INCLUDES = -I$(srcdir)/hdf5-1.8.3/src -I$(builddir)/hdf5-1.8.3/src |
117 |
+-endif |
118 |
+- |
119 |
+-DIST_SUBDIRS = lapack hdf5-1.8.3 |
120 |
+-SUBDIRS = $(INTERNAL_HDF5_DIRS) $(INTERNAL_LAPACK_DIRS) |
121 |
+- |
122 |
+ if USE_DYNAMIC_LINKING |
123 |
+ lib_LTLIBRARIES = libfreeonmodules.la |
124 |
+ else |
125 |
+--- freeon-9999.orig/configure.ac 2013-05-29 15:34:16.000000000 +0000 |
126 |
++++ freeon-9999/configure.ac 2013-05-29 15:36:22.000063299 +0000 |
127 |
+@@ -870,7 +870,6 @@ AM_CONDITIONAL(INTERNAL_HDF5, [test "${u |
128 |
+ if test "${use_internal_hdf5}" = "yes"; then |
129 |
+ |
130 |
+ AC_DEFINE(HAVE_INTERNAL_HDF5, 1, [Use the inernal hdf5 library.]) |
131 |
+- AC_CONFIG_SUBDIRS([Modules/hdf5-1.8.3]) |
132 |
+ |
133 |
+ else |
134 |
+ |
135 |
+@@ -1069,15 +1068,6 @@ config_localversion.h |
136 |
+ Makefile |
137 |
+ FreeON/Makefile |
138 |
+ Modules/Makefile |
139 |
+-Modules/lapack/Makefile |
140 |
+-Modules/lapack/install/Makefile |
141 |
+-Modules/lapack/blas/Makefile |
142 |
+-Modules/lapack/lapack/Makefile |
143 |
+-Modules/lapack/blas_testing/Makefile |
144 |
+-Modules/lapack/lapack_testing/Makefile |
145 |
+-Modules/lapack/lapack_testing/lin/Makefile |
146 |
+-Modules/lapack/lapack_testing/eig/Makefile |
147 |
+-Modules/lapack/lapack_testing/matgen/Makefile |
148 |
+ SCFeqs/Makefile |
149 |
+ OneE/Makefile |
150 |
+ QCTC/Makefile |
151 |
|
152 |
diff --git a/sci-chemistry/freeon/freeon-9999.ebuild b/sci-chemistry/freeon/freeon-2012.05.03.ebuild |
153 |
similarity index 64% |
154 |
copy from sci-chemistry/freeon/freeon-9999.ebuild |
155 |
copy to sci-chemistry/freeon/freeon-2012.05.03.ebuild |
156 |
index 2fe44e9..99805e0 100644 |
157 |
--- a/sci-chemistry/freeon/freeon-9999.ebuild |
158 |
+++ b/sci-chemistry/freeon/freeon-2012.05.03.ebuild |
159 |
@@ -8,14 +8,14 @@ AUTOTOOLS_AUTORECONF=1 |
160 |
|
161 |
FORTRAN_STANDARD=90 |
162 |
|
163 |
-inherit autotools-utils fortran-2 git-2 |
164 |
+inherit autotools-utils fortran-2 |
165 |
+ |
166 |
+REAL_PN="${PN}-beta" |
167 |
+REAL_PV="${PV//./-}" |
168 |
|
169 |
DESCRIPTION="an experimental suite of programs for linear scaling quantum chemistry." |
170 |
HOMEPAGE="http://www.freeon.org" |
171 |
-SRC_URI="" |
172 |
- |
173 |
-EGIT_REPO_URI="http://git.savannah.gnu.org/r/freeon.git" |
174 |
-EGIT_BOOTSTRAP="fix_localversion.sh" |
175 |
+SRC_URI="http://download.savannah.gnu.org/releases/${PN}/${REAL_PN}-${REAL_PV}.tar.bz2" |
176 |
|
177 |
LICENSE="GPL-3" |
178 |
SLOT="0" |
179 |
@@ -30,6 +30,17 @@ RDEPEND=" |
180 |
DEPEND="${DEPEND} |
181 |
virtual/pkgconfig" |
182 |
|
183 |
+S="${WORKDIR}/${REAL_PN}-${REAL_PV}" |
184 |
+ |
185 |
+src_prepare() { |
186 |
+ # Get rid of the obsolete internal hdf5 |
187 |
+ rm -r "${S}"/hdf5-1.8.3 |
188 |
+ # as well as of the internal lapack |
189 |
+ rm -r "${S}"/lapack |
190 |
+ epatch "${FILESDIR}"/"${P}"-no_internal_libs.patch |
191 |
+ eautoreconf |
192 |
+} |
193 |
+ |
194 |
src_configure() { |
195 |
local myeconfargs=( |
196 |
--disable-internal-hdf5 |
197 |
|
198 |
diff --git a/sci-chemistry/freeon/freeon-9999.ebuild b/sci-chemistry/freeon/freeon-9999.ebuild |
199 |
index 2fe44e9..369e063 100644 |
200 |
--- a/sci-chemistry/freeon/freeon-9999.ebuild |
201 |
+++ b/sci-chemistry/freeon/freeon-9999.ebuild |
202 |
@@ -30,6 +30,15 @@ RDEPEND=" |
203 |
DEPEND="${DEPEND} |
204 |
virtual/pkgconfig" |
205 |
|
206 |
+src_prepare() { |
207 |
+ # Get rid of the obsolete internal hdf5 |
208 |
+ rm -r "${S}"/Modules/hdf5-1.8.3 |
209 |
+ # as well as of the internal lapack |
210 |
+ rm -r "${S}"/Modules/lapack |
211 |
+ epatch "${FILESDIR}"/"${P}"-no_internal_libs.patch |
212 |
+ eautoreconf |
213 |
+} |
214 |
+ |
215 |
src_configure() { |
216 |
local myeconfargs=( |
217 |
--disable-internal-hdf5 |
218 |
|
219 |
diff --git a/sci-chemistry/nwchem/ChangeLog b/sci-chemistry/nwchem/ChangeLog |
220 |
index b6b85fc..687c7c7 100644 |
221 |
--- a/sci-chemistry/nwchem/ChangeLog |
222 |
+++ b/sci-chemistry/nwchem/ChangeLog |
223 |
@@ -2,6 +2,12 @@ |
224 |
# Copyright 1999-2013 Gentoo Foundation; Distributed under the GPL v2 |
225 |
# $Header: $ |
226 |
|
227 |
+*nwchem-6.3 (30 May 2013) |
228 |
+ |
229 |
+ 30 May 2013; Honza Macháček <Hloupy.Honza@×××××××.cz> +nwchem-6.3.ebuild, |
230 |
+ +files/nwchem-6.3-html_doc.patch: |
231 |
+ Version bumped to 6.3, adding the doc option attempted. |
232 |
+ |
233 |
14 Mar 2013; François Bissey <francois.bissey@×××××××××××××.nz> |
234 |
nwchem-6.1.1.ebuild: |
235 |
Improving mpi linking. It will now work with openmpi as well. |
236 |
|
237 |
diff --git a/sci-chemistry/nwchem/files/nwchem-6.3-html_doc.patch b/sci-chemistry/nwchem/files/nwchem-6.3-html_doc.patch |
238 |
new file mode 100644 |
239 |
index 0000000..fa0e8fa |
240 |
--- /dev/null |
241 |
+++ b/sci-chemistry/nwchem/files/nwchem-6.3-html_doc.patch |
242 |
@@ -0,0 +1,82 @@ |
243 |
+diff -Naurp old/doc/update_www new/doc/update_www |
244 |
+--- doc/update_www 2013-05-18 00:40:51.000000000 +0000 |
245 |
++++ doc/update_www 2013-05-22 12:15:27.543414281 +0000 |
246 |
+@@ -16,7 +16,8 @@ set document = $argv[1] |
247 |
+ echo Updating WWW pages for $document.tex |
248 |
+ #............... public |
249 |
+ #foreach WWWDIR (/msrc/www/pub/docs/nwchem/doc) |
250 |
+-foreach WWWDIR (/msrc/emslweb/docs/nwchem/doc) |
251 |
++#foreach WWWDIR (/msrc/emslweb/docs/nwchem/doc) |
252 |
++foreach WWWDIR ("${NWCHEM_TOP}"/html) |
253 |
+ # |
254 |
+ # Now copy the revised source into the EMSL public WWW tree |
255 |
+ echo "update_www: Public pages .. " |
256 |
+diff -Naurp old/user/geometry.tex new/user/geometry.tex |
257 |
+--- user/geometry.tex 2013-05-18 00:40:51.000000000 +0000 |
258 |
++++ user/geometry.tex 2013-05-23 13:00:44.234316049 +0000 |
259 |
+@@ -472,11 +472,11 @@ and angles. |
260 |
+ \ifx\pdfoutput\undefined |
261 |
+ \includegraphics[angle=270,width=6in]{zmat1.eps} |
262 |
+ \else |
263 |
+-\includegraphics[angle=0,width=6in]{zmat1.pdf} |
264 |
++\includegraphics[angle=0,width=6in,bburx=509,bbury=201]{zmat1.pdf} |
265 |
+ \fi |
266 |
+ \end{latexonly} |
267 |
+ \begin{htmlonly} |
268 |
+-\psfig{figure=zmat1.eps,angle=270,width=6in} |
269 |
++\epsfig{figure=zmat1.eps,angle=270,width=6in} |
270 |
+ \end{htmlonly} |
271 |
+ \caption{\label{fig:zmat1} Relationships between the centers, bond angle |
272 |
+ and dihedral angle in Z-matrix input.} |
273 |
+@@ -488,11 +488,11 @@ and dihedral angle in Z-matrix input.} |
274 |
+ \ifx\pdfoutput\undefined |
275 |
+ \includegraphics[angle=270,width=6in]{zmat2.eps} |
276 |
+ \else |
277 |
+-\includegraphics[angle=270,width=6in]{zmat2.pdf} |
278 |
++\includegraphics[angle=270,width=6in,bburx=266,bbury=485]{zmat2.pdf} |
279 |
+ \fi |
280 |
+ \end{latexonly} |
281 |
+ \begin{htmlonly} |
282 |
+-\psfig{figure=zmat2.eps,angle=270,width=6in} |
283 |
++\epsfig{figure=zmat2.eps,angle=270,width=6in} |
284 |
+ \end{htmlonly} |
285 |
+ |
286 |
+ \caption{\label{fig:zmat2} Relationships between the centers and two |
287 |
+@@ -505,11 +505,11 @@ and dihedral angle in Z-matrix input.} |
288 |
+ \ifx\pdfoutput\undefined |
289 |
+ \includegraphics[angle=270,width=6in]{zmat3.eps} |
290 |
+ \else |
291 |
+-\includegraphics[angle=270,width=6in]{zmat3.pdf} |
292 |
++\includegraphics[angle=270,width=6in,bburx=266,bbury=482]{zmat3.pdf} |
293 |
+ \fi |
294 |
+ \end{latexonly} |
295 |
+ \begin{htmlonly} |
296 |
+-\psfig{figure=zmat3.eps,angle=270,width=6in} |
297 |
++\epsfig{figure=zmat3.eps,angle=270,width=6in} |
298 |
+ \end{htmlonly} |
299 |
+ \caption{\label{fig:zmat3} Relationships between the centers and two |
300 |
+ bond angles in Z-matrix input with optional parameter specified as $-1$.} |
301 |
+diff -Naurp old/user/titlepage.tex new/user/titlepage.tex |
302 |
+--- user/titlepage.tex 2013-05-18 00:40:51.000000000 +0000 |
303 |
++++ user/titlepage.tex 2013-05-23 13:01:07.304152791 +0000 |
304 |
+@@ -19,7 +19,7 @@ |
305 |
+ {\bf\Large \nwchemmonth \ \nwchemyear}\\[1.0in] |
306 |
+ |
307 |
+ |
308 |
+-%\psfig{figure=zsm.major.ps,height=4in,width=4in} |
309 |
++%\epsfig{figure=zsm.major.ps,height=4in,width=4in} |
310 |
+ |
311 |
+ |
312 |
+ \end{centering} |
313 |
+diff -Naurp old/user/user.tex new/user/user.tex |
314 |
+--- user/user.tex 2013-05-18 00:40:51.000000000 +0000 |
315 |
++++ user/user.tex 2013-05-23 13:00:04.961296411 +0000 |
316 |
+@@ -2,7 +2,7 @@ |
317 |
+ \input{top} |
318 |
+ \usepackage[dvips]{graphicx} |
319 |
+ \begin{htmlonly} |
320 |
+-\usepackage{psfig} |
321 |
++\usepackage{epsfig} |
322 |
+ \end{htmlonly} |
323 |
+ |
324 |
+ |
325 |
|
326 |
diff --git a/sci-chemistry/nwchem/nwchem-6.3.ebuild b/sci-chemistry/nwchem/nwchem-6.3.ebuild |
327 |
new file mode 100644 |
328 |
index 0000000..380de67 |
329 |
--- /dev/null |
330 |
+++ b/sci-chemistry/nwchem/nwchem-6.3.ebuild |
331 |
@@ -0,0 +1,146 @@ |
332 |
+# Copyright 1999-2013 Gentoo Foundation |
333 |
+# Distributed under the terms of the GNU General Public License v2 |
334 |
+# $Header: $ |
335 |
+ |
336 |
+EAPI=5 |
337 |
+ |
338 |
+PYTHON_COMPAT=( python{2_6,2_7} ) |
339 |
+inherit eutils fortran-2 multilib python-single-r1 toolchain-funcs |
340 |
+ |
341 |
+DATE="2013-05-17" |
342 |
+ |
343 |
+DESCRIPTION="NWChem: Delivering High-Performance Computational Chemistry to Science" |
344 |
+HOMEPAGE="http://www.nwchem-sw.org/index.php/Main_Page" |
345 |
+SRC_URI="http://www.nwchem-sw.org/images/Nwchem-${PV}-src.${DATE}.tar.gz" |
346 |
+ |
347 |
+LICENSE="ECL-2.0" |
348 |
+SLOT="0" |
349 |
+KEYWORDS="~x86 ~amd64" |
350 |
+IUSE="mpi doc examples nwchem-tests python" |
351 |
+ |
352 |
+RDEPEND="sys-fs/sysfsutils |
353 |
+ python? ( ${PYTHON_DEPS} )" |
354 |
+DEPEND="${RDEPEND} |
355 |
+ virtual/fortran |
356 |
+ app-shells/tcsh |
357 |
+ mpi? ( virtual/mpi[fortran] ) |
358 |
+ doc? ( dev-texlive/texlive-latex |
359 |
+ dev-tex/latex2html )" |
360 |
+ |
361 |
+S="${WORKDIR}/${P}-src.${DATE}" |
362 |
+ |
363 |
+pkg_setup() { |
364 |
+ fortran-2_pkg_setup |
365 |
+ use python && python-single-r1_pkg_setup |
366 |
+} |
367 |
+ |
368 |
+src_prepare() { |
369 |
+ epatch \ |
370 |
+ "${FILESDIR}"/nwchem-6.1.1-makefile.patch \ |
371 |
+ "${FILESDIR}"/nwchem-6.1.1-nwchemrc.patch \ |
372 |
+ "${FILESDIR}"/nwchem-6.1.1-adjust-dir-length.patch |
373 |
+ use python && epatch "${FILESDIR}"/nwchem-6.1.1-python_makefile.patch |
374 |
+ use doc && epatch "${FILESDIR}"/nwchem-6.3-html_doc.patch |
375 |
+ |
376 |
+ sed \ |
377 |
+ -e "s:DBASIS_LIBRARY=\"'\$(SRCDIR)'\":DBASIS_LIBRARY=\"'${EPREFIX}/usr/share/NWChem'\":g" \ |
378 |
+ -i src/basis/MakeFile src/basis/GNUmakefile || die |
379 |
+ sed \ |
380 |
+ -e "s:DNWPW_LIBRARY=\"'\$(SRCDIR)'\":DNWPW_LIBRARY=\"'${EPREFIX}/usr/share/NWChem'\":g" \ |
381 |
+ -i src/nwpw/libraryps/GNUmakefile || die |
382 |
+ sed \ |
383 |
+ -e "s:-DCOMPILATION_DIR=\"'\$(TOPDIR)'\":-DCOMPILATION_DIR=\"''\":g" \ |
384 |
+ -i src/GNUmakefile src/MakeFile || die |
385 |
+ |
386 |
+ if [[ $(tc-getFC) == *-*-*-*-gfortran ]]; then |
387 |
+ sed \ |
388 |
+ -e "s:ifneq (\$(FC),gfortran):ifneq (\$(FC),$(tc-getFC)):g" \ |
389 |
+ -e "s:ifeq (\$(FC),gfortran):ifeq (\$(FC),$(tc-getFC)):g" \ |
390 |
+ -i src/config/makefile.h || die |
391 |
+ fi |
392 |
+} |
393 |
+ |
394 |
+src_compile() { |
395 |
+ export USE_SUBGROUPS=yes |
396 |
+ if use mpi ; then |
397 |
+ export MSG_COMMS=MPI |
398 |
+ export USE_MPI=yes |
399 |
+ export MPI_LOC=/usr |
400 |
+ export MPI_INCLUDE=$MPI_LOC/include |
401 |
+ export MPI_LIB=$MPI_LOC/$(get_libdir) |
402 |
+ export LIBMPI="$(mpif90 -showme:link)" |
403 |
+ fi |
404 |
+ if [ "$ARCH" = "amd64" ]; then |
405 |
+ export NWCHEM_TARGET=LINUX64 |
406 |
+ elif [ "$ARCH" = "ia64" ]; then |
407 |
+ export NWCHEM_TARGET=LINUX64 |
408 |
+ elif [ "$ARCH" = "x86" ]; then |
409 |
+ export NWCHEM_TARGET=LINUX |
410 |
+ elif [ "$ARCH" = "ppc" ]; then |
411 |
+ export NWCHEM_TARGET=LINUX |
412 |
+ else |
413 |
+ die "Unknown architecture" |
414 |
+ fi |
415 |
+ if use python ; then |
416 |
+ if [ "$ARCH" = "amd64" ] || [ "$ARCH" = "ia64" ]; then |
417 |
+ export USE_PYTHON64=yes |
418 |
+ fi |
419 |
+ export PYTHONHOME=/usr |
420 |
+ export PYTHONVERSION=$(eselect python show|awk -Fpython '{ print $2 }') |
421 |
+ export PYTHONPATH="./:${S}/contrib/python/" |
422 |
+ export NWCHEM_MODULES="all python" |
423 |
+ else |
424 |
+ export NWCHEM_MODULES="all" |
425 |
+ fi |
426 |
+ |
427 |
+ cd src |
428 |
+ emake \ |
429 |
+ DIAG=PAR \ |
430 |
+ FC=$(tc-getFC) \ |
431 |
+ CC=$(tc-getCC) \ |
432 |
+ CXX=$(tc-getCXX) \ |
433 |
+ NWCHEM_TOP="${S}" \ |
434 |
+ NWCHEM_EXECUTABLE="${S}/bin/${NWCHEM_TARGET}/nwchem" |
435 |
+ |
436 |
+ if use doc; then |
437 |
+ cd "${S}"/doc |
438 |
+ emake \ |
439 |
+ DIAG=PAR \ |
440 |
+ NWCHEM_TOP="${S}" \ |
441 |
+ pdf html |
442 |
+ fi |
443 |
+} |
444 |
+ |
445 |
+src_install() { |
446 |
+ dobin bin/${NWCHEM_TARGET}/nwchem |
447 |
+ |
448 |
+ insinto /usr/share/NWChem/basis/ |
449 |
+ doins -r src/basis/libraries src/data |
450 |
+ insinto /usr/share/NWChem/nwpw |
451 |
+ doins -r src/nwpw/libraryps |
452 |
+ |
453 |
+ insinto /etc |
454 |
+ doins nwchemrc |
455 |
+ |
456 |
+ use examples && \ |
457 |
+ insinto /usr/share/NWChem/ && \ |
458 |
+ doins -r examples |
459 |
+ |
460 |
+ use nwchem-tests && \ |
461 |
+ insinto /usr/share/NWChem && \ |
462 |
+ doins -r QA/tests |
463 |
+ |
464 |
+ use doc && \ |
465 |
+ insinto /usr/share/doc/"${P}" && \ |
466 |
+ doins -r doc/nwahtml && \ |
467 |
+ doins -r html |
468 |
+ |
469 |
+} |
470 |
+ |
471 |
+pkg_postinst() { |
472 |
+ echo |
473 |
+ elog "The user will need to link \$HOME/.nwchemrc to /etc/nwchemrc" |
474 |
+ elog "or copy it in order to tell NWChem the right position of the" |
475 |
+ elog "basis library and other necessary data." |
476 |
+ echo |
477 |
+} |