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/apbs/, sci-chemistry/apbs/files/
Date: Mon, 05 May 2014 20:12:17
Message-Id: 1398952207.cf9d2e5e7d5ea97ff690ee5f5ab79595a765a8b5.jlec@gentoo
1 commit: cf9d2e5e7d5ea97ff690ee5f5ab79595a765a8b5
2 Author: Justin Lecher <jlec <AT> gentoo <DOT> org>
3 AuthorDate: Thu May 1 13:50:07 2014 +0000
4 Commit: Justin Lecher <jlec <AT> gentoo <DOT> org>
5 CommitDate: Thu May 1 13:50:07 2014 +0000
6 URL: http://git.overlays.gentoo.org/gitweb/?p=proj/sci.git;a=commit;h=cf9d2e5e
7
8 sci-chemistry/apbs: Add live ebuild
9
10 Package-Manager: portage-2.2.10
11
12 ---
13 sci-chemistry/apbs/ChangeLog | 10 +++
14 sci-chemistry/apbs/apbs-9999.ebuild | 91 ++++++++++++++++++++++
15 sci-chemistry/apbs/files/apbs-9999-manip.patch | 15 ++++
16 sci-chemistry/apbs/files/apbs-9999-prll.patch | 101 +++++++++++++++++++++++++
17 sci-chemistry/apbs/metadata.xml | 21 +++++
18 5 files changed, 238 insertions(+)
19
20 diff --git a/sci-chemistry/apbs/ChangeLog b/sci-chemistry/apbs/ChangeLog
21 new file mode 100644
22 index 0000000..7ce467c
23 --- /dev/null
24 +++ b/sci-chemistry/apbs/ChangeLog
25 @@ -0,0 +1,10 @@
26 +# ChangeLog for sci-chemistry/apbs
27 +# Copyright 1999-2014 Gentoo Foundation; Distributed under the GPL v2
28 +# $Header: $
29 +
30 +*apbs-9999 (01 May 2014)
31 +
32 + 01 May 2014; Justin Lecher <jlec@g.o> +apbs-9999.ebuild,
33 + +files/apbs-9999-manip.patch, +files/apbs-9999-prll.patch, +metadata.xml:
34 + Add live ebuild
35 +
36
37 diff --git a/sci-chemistry/apbs/apbs-9999.ebuild b/sci-chemistry/apbs/apbs-9999.ebuild
38 new file mode 100644
39 index 0000000..dcbc0f9
40 --- /dev/null
41 +++ b/sci-chemistry/apbs/apbs-9999.ebuild
42 @@ -0,0 +1,91 @@
43 +# Copyright 1999-2014 Gentoo Foundation
44 +# Distributed under the terms of the GNU General Public License v2
45 +# $Header: /var/cvsroot/gentoo-x86/sci-chemistry/apbs/apbs-1.3-r3.ebuild,v 1.5 2013/05/02 15:16:35 jlec Exp $
46 +
47 +EAPI=5
48 +
49 +PYTHON_COMPAT=( python2_7 )
50 +
51 +inherit cmake-utils flag-o-matic git-r3 multilib python-single-r1 toolchain-funcs
52 +
53 +DESCRIPTION="Evaluation of electrostatic properties of nanoscale biomolecular systems"
54 +HOMEPAGE="http://www.poissonboltzmann.org/apbs/"
55 +SRC_URI=""
56 +EGIT_REPO_URI="git://git.code.sf.net/p/apbs/code"
57 +
58 +SLOT="0"
59 +LICENSE="BSD"
60 +KEYWORDS=""
61 +IUSE="debug examples +fetk mpi +openmp +tools"
62 +
63 +RDEPEND="${PYTHON_DEPS}
64 + dev-libs/maloc[mpi=]
65 + virtual/blas
66 + sys-libs/readline
67 + fetk? (
68 + sci-libs/fetk
69 + sci-libs/amd
70 + sci-libs/umfpack
71 + sci-libs/superlu )
72 + mpi? ( virtual/mpi )"
73 +DEPEND="${DEPEND}
74 + virtual/pkgconfig"
75 +
76 +PATCHES=(
77 + "${FILESDIR}"/${P}-manip.patch
78 + "${FILESDIR}"/${P}-prll.patch
79 +)
80 +
81 +DOCS=(
82 + doc/{APBS-1.4-README.txt,ChangeLog,README}
83 +)
84 +
85 +src_prepare() {
86 + local _examples
87 +
88 + use examples || examples=$(ls examples/*)
89 +
90 + rm -rf \
91 + contrib/maloc* include/Eigen/* \
92 + doc/{license,release_procedure.txt,programmer,CMakeLists.txt} \
93 + ${examples} \
94 + || die
95 +
96 + append-cppflags $($(tc-getPKG_CONFIG) --cflags eigen3)
97 +
98 + sed \
99 + -e "s:-lblas:$($(tc-getPKG_CONFIG) --libs blas):g" \
100 + -e 's:-lg2c::g' \
101 + -i CMakeLists.txt || die
102 +
103 + cmake-utils_src_prepare
104 +}
105 +
106 +src_configure() {
107 + local mycmakeargs=(
108 + -DSYS_LIBPATHS="${EPREFIX}"/usr/$(get_libdir)
109 + -DLIBRARY_INSTALL_PATH=$(get_libdir)
110 + -DFETK_PATH="${EPREFIX}"/usr/
111 + -DBUILD_SHARED_LIBS=ON
112 + -DENABLE_PYTHON=ON
113 + $(cmake-utils_use_build tools)
114 + $(cmake-utils_use_enable debug)
115 +# Not acitve in the code yet
116 +# $(cmake-utils_use_enable fast)
117 + $(cmake-utils_use_enable fetk)
118 + $(cmake-utils_use_enable mpi)
119 + $(cmake-utils_use_enable openmp)
120 + )
121 + cmake-utils_src_configure
122 +}
123 +
124 +src_test() {
125 + cd tests || die
126 + "${PYTHON}" apbs_tester.py -l log || die
127 + grep -q 'FAILED' log && die "Tests failed"
128 +}
129 +
130 +src_install() {
131 + cmake-utils_src_install
132 + python_optimize "${ED}"
133 +}
134
135 diff --git a/sci-chemistry/apbs/files/apbs-9999-manip.patch b/sci-chemistry/apbs/files/apbs-9999-manip.patch
136 new file mode 100644
137 index 0000000..fd5c1a2
138 --- /dev/null
139 +++ b/sci-chemistry/apbs/files/apbs-9999-manip.patch
140 @@ -0,0 +1,15 @@
141 + tools/CMakeLists.txt | 1 -
142 + 1 file changed, 1 deletion(-)
143 +
144 +diff --git a/tools/CMakeLists.txt b/tools/CMakeLists.txt
145 +index 1982a3c..30ab17a 100644
146 +--- a/tools/CMakeLists.txt
147 ++++ b/tools/CMakeLists.txt
148 +@@ -1,7 +1,6 @@
149 + set(EXECUTABLE_OUTPUT_PATH ${TOOLS_PATH}/bin)
150 +
151 + add_subdirectory(mesh)
152 +-add_subdirectory(manip)
153 +
154 + if(ENABLE_PYTHON)
155 + add_subdirectory(manip)
156
157 diff --git a/sci-chemistry/apbs/files/apbs-9999-prll.patch b/sci-chemistry/apbs/files/apbs-9999-prll.patch
158 new file mode 100644
159 index 0000000..99e1845
160 --- /dev/null
161 +++ b/sci-chemistry/apbs/files/apbs-9999-prll.patch
162 @@ -0,0 +1,101 @@
163 + CMakeLists.txt | 16 ++++++++--------
164 + src/CMakeLists.txt | 1 -
165 + src/fem/CMakeLists.txt | 2 +-
166 + src/pmgc/CMakeLists.txt | 2 +-
167 + 4 files changed, 10 insertions(+), 11 deletions(-)
168 +
169 +diff --git a/CMakeLists.txt b/CMakeLists.txt
170 +index e3f720c..6b7db4c 100644
171 +--- a/CMakeLists.txt
172 ++++ b/CMakeLists.txt
173 +@@ -61,7 +61,7 @@ set(LIBRARY_OUTPUT_PATH ${APBS_ROOT}/lib)
174 + set(TOOLS_PATH ${APBS_ROOT}/tools)
175 + set(APBS_BINARY ${EXECUTABLE_OUTPUT_PATH}/apbs)
176 +
177 +-set(LIBRARY_INSTALL_PATH lib)
178 ++set(LIBRARY_INSTALL_PATH ${CMAKE_INSTALL_LIBDIR})
179 + set(HEADER_INSTALL_PATH include/apbs)
180 + set(EXECUTABLE_INSTALL_PATH bin)
181 + set(SHARE_INSTALL_PATH share/apbs)
182 +@@ -93,8 +93,6 @@ set(CMAKE_INCLUDE_PATH "${CMAKE_INCLUDE_PATH}")
183 + list(APPEND CMAKE_INCLUDE_PATH /usr/include)
184 + list(APPEND CMAKE_INCLUDE_PATH /usr/local/include)
185 +
186 +-set(APBS_LIBS "-L${APBS_ROOT}/lib -lapbs_geoflow")
187 +-
188 + ################################################################################
189 + # Enable ansi pedantic compiling #
190 + ################################################################################
191 +@@ -202,9 +200,11 @@ if(ENABLE_BEM)
192 + else()
193 + set(TABI_LIBRARY_BASENAME ${CMAKE_STATIC_LIBRARY_PREFIX}${TABI}${CMAKE_STATIC_LIBRARY_SUFFIX})
194 + endif()
195 +-
196 ++
197 ++ file(GLOB MODS ${LIBRARY_OUTPUT_PATH}/*.mod)
198 ++
199 + install(
200 +- FILES ${LIBRARY_OUTPUT_PATH}/${TABI_LIBRARY_BASENAME} ${LIBRARY_OUTPUT_PATH}/*.mod
201 ++ FILES ${LIBRARY_OUTPUT_PATH}/${TABI_LIBRARY_BASENAME} ${MODS}
202 + DESTINATION ${LIBRARY_INSTALL_PATH}
203 + )
204 + set(TABI_LIBRARY ${APBS_ROOT}/${LIBRARY_INSTALL_PATH}/${TABI_LIBRARY_BASENAME})
205 +@@ -219,7 +219,7 @@ if(ENABLE_BEM)
206 + endif()
207 + get_filename_component(LIBGFORTRANPATH ${LIBGFORTRANPATH} PATH)
208 + find_path(LIBGFORTRAN_PATH ${LIBGFORTRAN_NAME} PATH ${LIBGFORTRANPATH})
209 +- list(APPEND APBS_LIBS "-L${APBS_ROOT}/${LIBRARY_INSTALL_PATH} -L${LIBGFORTRAN_PATH} -lgfortran -ltabipb" )
210 ++ list(APPEND APBS_LIBS "-L${APBS_ROOT}/lib -L${LIBGFORTRAN_PATH} -lgfortran -ltabipb" )
211 + endif()
212 +
213 + find_file( # this should be find path...
214 +@@ -237,7 +237,7 @@ endif()
215 +
216 +
217 + find_library(MALOC_LIBRARY "maloc"
218 +- PATHS ${FETK_PATH}/lib ${CONTRIB_PATH}
219 ++ PATHS ${FETK_PATH}/${CMAKE_INSTALL_LIBDIR} ${CONTRIB_PATH}
220 + DOC "The fetk/maloc library"
221 + )
222 + if(MALOC_LIBRARY)
223 +@@ -295,7 +295,7 @@ if(ENABLE_FETK)
224 + set(FETK_ENALBED 1)
225 +
226 + list(APPEND APBS_LIBS "-lstdc++")
227 +- list(APPEND APBS_LIBS "-L${FETK_PATH}/lib")
228 ++ list(APPEND APBS_LIBS "-L${FETK_PATH}/${CMAKE_INSTALL_LIBDIR}")
229 + list(APPEND APBS_LIBS -lamd -lpunc -lmc -lgamer -lsuperlu -lumfpack
230 + -lblas -lvf2c -ltetgen -ltriangle -lg2c -lreadline )
231 +
232 +diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
233 +index 44d20fa..5d5150b 100644
234 +--- a/src/CMakeLists.txt
235 ++++ b/src/CMakeLists.txt
236 +@@ -23,7 +23,6 @@ macro(add_items TYPE)
237 + endmacro()
238 +
239 +
240 +-
241 + macro(add_sublibrary LIBRARY)
242 + set(LIBRARY_NAME "apbs_${LIBRARY}")
243 + set(LIBRARY_DEPENDENCIES ${APBS_LIBS} ${ARGN})
244 +diff --git a/src/fem/CMakeLists.txt b/src/fem/CMakeLists.txt
245 +index 5a950c2..dc37f48 100644
246 +--- a/src/fem/CMakeLists.txt
247 ++++ b/src/fem/CMakeLists.txt
248 +@@ -12,4 +12,4 @@ add_items(
249 + vpee.h
250 + )
251 +
252 +-add_sublibrary(fem)
253 ++add_sublibrary(fem apbs_geoflow)
254 +diff --git a/src/pmgc/CMakeLists.txt b/src/pmgc/CMakeLists.txt
255 +index 85b0c1e..97c95f0 100644
256 +--- a/src/pmgc/CMakeLists.txt
257 ++++ b/src/pmgc/CMakeLists.txt
258 +@@ -42,4 +42,4 @@ add_items(
259 + mgfasd.h
260 + )
261 +
262 +-add_sublibrary(pmgc)
263 ++add_sublibrary(pmgc apbs_geoflow)
264
265 diff --git a/sci-chemistry/apbs/metadata.xml b/sci-chemistry/apbs/metadata.xml
266 new file mode 100644
267 index 0000000..b8e5095
268 --- /dev/null
269 +++ b/sci-chemistry/apbs/metadata.xml
270 @@ -0,0 +1,21 @@
271 +<?xml version="1.0" encoding="UTF-8"?>
272 +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
273 +<pkgmetadata>
274 + <herd>sci-chemistry</herd>
275 + <maintainer>
276 + <email>jlec@g.o</email>
277 + <name>Justin Lecher</name>
278 + <description>Ebuild Crasher</description>
279 + </maintainer>
280 + <use>
281 + <flag name="fetk">Include support for FeTK</flag>
282 + <flag name="tools">Install optional tools</flag>
283 + </use>
284 + <longdescription>
285 +APBS is a software package for modeling biomolecular solvation through solution
286 +of the Poisson-Boltzmann equation (PBE), one of the most popular continuum
287 +models for describing electrostatic interactions between molecular solutes in
288 +salty, aqueous media. Continuum electrostatics plays an important role in
289 +several areas of biomolecular simulation
290 +</longdescription>
291 +</pkgmetadata>