diff options
author | Justin Lecher <jlec@gentoo.org> | 2014-10-28 13:10:30 +0000 |
---|---|---|
committer | Justin Lecher <jlec@gentoo.org> | 2014-10-28 13:10:30 +0000 |
commit | 2fca740804b57a467467a88aa78124f0dd951765 (patch) | |
tree | d43130457824b1a90fc8bac8fab431d69023f04d /sci-chemistry/apbs | |
parent | Filter -pie from CFLAGS, bug 526948. (diff) | |
download | gentoo-2-2fca740804b57a467467a88aa78124f0dd951765.tar.gz gentoo-2-2fca740804b57a467467a88aa78124f0dd951765.tar.bz2 gentoo-2-2fca740804b57a467467a88aa78124f0dd951765.zip |
sci-chemistry/apbs: Link python libs completely
(Portage version: 2.2.14/cvs/Linux x86_64, signed Manifest commit with key B9D4F231BD1558AB!)
Diffstat (limited to 'sci-chemistry/apbs')
-rw-r--r-- | sci-chemistry/apbs/ChangeLog | 9 | ||||
-rw-r--r-- | sci-chemistry/apbs/apbs-1.4.1-r1.ebuild (renamed from sci-chemistry/apbs/apbs-1.4.1.ebuild) | 37 | ||||
-rw-r--r-- | sci-chemistry/apbs/files/apbs-1.4.1-manip.patch | 13 | ||||
-rw-r--r-- | sci-chemistry/apbs/files/apbs-1.4.1-python.patch | 122 |
4 files changed, 162 insertions, 19 deletions
diff --git a/sci-chemistry/apbs/ChangeLog b/sci-chemistry/apbs/ChangeLog index 530323b8bf51..d189a27f63ee 100644 --- a/sci-chemistry/apbs/ChangeLog +++ b/sci-chemistry/apbs/ChangeLog @@ -1,6 +1,13 @@ # ChangeLog for sci-chemistry/apbs # Copyright 1999-2014 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/sci-chemistry/apbs/ChangeLog,v 1.67 2014/10/24 11:38:49 jlec Exp $ +# $Header: /var/cvsroot/gentoo-x86/sci-chemistry/apbs/ChangeLog,v 1.68 2014/10/28 13:10:30 jlec Exp $ + +*apbs-1.4.1-r1 (28 Oct 2014) + + 28 Oct 2014; Justin Lecher <jlec@gentoo.org> -apbs-1.4.1.ebuild, + +apbs-1.4.1-r1.ebuild, files/apbs-1.4.1-manip.patch, + +files/apbs-1.4.1-python.patch: + Link python libs completely 24 Oct 2014; Justin Lecher <jlec@gentoo.org> apbs-1.4.1.ebuild: Add missing requiered use diff --git a/sci-chemistry/apbs/apbs-1.4.1.ebuild b/sci-chemistry/apbs/apbs-1.4.1-r1.ebuild index acbe367af4c8..61461b25cfef 100644 --- a/sci-chemistry/apbs/apbs-1.4.1.ebuild +++ b/sci-chemistry/apbs/apbs-1.4.1-r1.ebuild @@ -1,12 +1,12 @@ # Copyright 1999-2014 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/sci-chemistry/apbs/apbs-1.4.1.ebuild,v 1.4 2014/10/24 11:38:49 jlec Exp $ +# $Header: /var/cvsroot/gentoo-x86/sci-chemistry/apbs/apbs-1.4.1-r1.ebuild,v 1.1 2014/10/28 13:10:30 jlec Exp $ EAPI=5 PYTHON_COMPAT=( python2_7 ) -inherit cmake-utils flag-o-matic multilib python-single-r1 toolchain-funcs +inherit cmake-utils distutils-r1 flag-o-matic multilib toolchain-funcs GITHUB_REV="74fcb8676de69ed04ddab8976a8b05a6caaf4d65" @@ -22,7 +22,7 @@ IUSE="debug doc examples fast +fetk mpi openmp python tools" REQUIRED_USE=" mpi? ( !python ) - ${PYTHON_REQUIRED_USE}" + python? ( tools fetk ${PYTHON_REQUIRED_USE} )" RDEPEND=" dev-cpp/eigen:3 @@ -48,6 +48,7 @@ S="${WORKDIR}"/${PN}-pdb2pqr-${GITHUB_REV}/${PN} PATCHES=( "${FILESDIR}"/${P}-multilib.patch "${FILESDIR}"/${P}-manip.patch + "${FILESDIR}"/${P}-python.patch ) src_prepare() { @@ -56,12 +57,19 @@ src_prepare() { sed \ -e "s:-lblas:$($(tc-getPKG_CONFIG) --libs blas):g" \ + -e "/TOOLS_PATH/d" \ -i CMakeLists.txt || die use doc && MAKEOPTS+=" -j1" + if use python; then + unset PATCHES || die + cd tools/python && distutils-r1_src_prepare + fi } src_configure() { local mycmakeargs=( + -DCMAKE_SKIP_RPATH=ON + -DTOOLS_PATH="${ED}"/usr -DSYS_LIBPATHS="${EPREFIX}"/usr/$(get_libdir) -DLIBRARY_INSTALL_PATH=$(get_libdir) -DFETK_PATH="${EPREFIX}"/usr/ @@ -78,11 +86,21 @@ src_configure() { $(cmake-utils_use_enable mpi MPI) $(cmake-utils_use_enable python PYTHON) # ENABLE_TINKER: Enable TINKER support - $(cmake-utils_use_enable python PYTHON) # ENABLE_iAPBS: Enable iAPBS + -DENABLE_iAPBS=ON # MAX_MEMORY: Set the maximum memory (in MB) to be used for a job ) cmake-utils_src_configure + if use python; then + cd tools/python && distutils-r1_src_configure + fi +} + +src_compile(){ + cmake-utils_src_compile + if use python; then + cd tools/python && distutils-r1_src_compile + fi } src_test() { @@ -92,6 +110,15 @@ src_test() { } src_install() { + dodir /usr/bin cmake-utils_src_install - python_optimize "${ED}" + local i + for i in "${ED}"/usr/bin/*; do + if [[ ! "${i}" =~ .*apbs$ ]]; then + mv "${i}" "${i}-apbs" || die + fi + done + if use python; then + cd tools/python && distutils-r1_src_install + fi } diff --git a/sci-chemistry/apbs/files/apbs-1.4.1-manip.patch b/sci-chemistry/apbs/files/apbs-1.4.1-manip.patch index edfeb75b886c..378223397594 100644 --- a/sci-chemistry/apbs/files/apbs-1.4.1-manip.patch +++ b/sci-chemistry/apbs/files/apbs-1.4.1-manip.patch @@ -1,6 +1,5 @@ apbs/CMakeLists.txt | 2 +- apbs/tools/CMakeLists.txt | 4 ---- - apbs/tools/manip/CMakeLists.txt | 4 ++-- apbs/tools/mesh/CMakeLists.txt | 4 ++-- 4 files changed, 5 insertions(+), 9 deletions(-) @@ -17,18 +16,6 @@ index 8917fc4..5152008 100644 list(APPEND APBS_LIBS "-lstdc++") list(APPEND APBS_LIBS "-L${FETK_PATH}/lib") -diff --git a/apbs/tools/CMakeLists.txt b/apbs/tools/CMakeLists.txt -index 1982a3c..da3b8ee 100644 ---- a/apbs/tools/CMakeLists.txt -+++ b/apbs/tools/CMakeLists.txt -@@ -2,7 +2,3 @@ set(EXECUTABLE_OUTPUT_PATH ${TOOLS_PATH}/bin) - - add_subdirectory(mesh) - add_subdirectory(manip) -- --if(ENABLE_PYTHON) -- add_subdirectory(manip) --endif(ENABLE_PYTHON) diff --git a/apbs/tools/manip/CMakeLists.txt b/apbs/tools/manip/CMakeLists.txt index 937dac7..5768cc5 100644 --- a/apbs/tools/manip/CMakeLists.txt diff --git a/sci-chemistry/apbs/files/apbs-1.4.1-python.patch b/sci-chemistry/apbs/files/apbs-1.4.1-python.patch new file mode 100644 index 000000000000..db9f86ba120a --- /dev/null +++ b/sci-chemistry/apbs/files/apbs-1.4.1-python.patch @@ -0,0 +1,122 @@ + apbs/contrib/iapbs/src/apbs_driver.c | 6 +++--- + apbs/src/CMakeLists.txt | 1 + + apbs/tools/CMakeLists.txt | 2 +- + apbs/tools/python/CMakeLists.txt | 1 + + apbs/tools/python/apbslib.c | 4 ++-- + apbs/tools/python/apbslib.i | 4 ++-- + apbs/tools/python/setup.py | 16 ++++++++++++++++ + 7 files changed, 26 insertions(+), 8 deletions(-) + +diff --git a/apbs/contrib/iapbs/src/apbs_driver.c b/apbs/contrib/iapbs/src/apbs_driver.c +index c9e443b..e1ad67f 100644 +--- a/apbs/contrib/iapbs/src/apbs_driver.c ++++ b/apbs/contrib/iapbs/src/apbs_driver.c +@@ -595,7 +595,7 @@ int apbsdrv_( + printPBEPARM(pbeparm); + + /* Refine mesh */ +- if (!preRefineFE(i, nosh, feparm, fetk)) { ++ if (!preRefineFE(i, feparm, fetk)) { + Vnm_tprint( 2, "Error pre-refining mesh!\n"); + VJMPERR1(0); + } +@@ -609,7 +609,7 @@ int apbsdrv_( + Vnm_tprint(1, " Beginning solve-estimate-refine cycle:\n"); + for (isolve=0; isolve<feparm->maxsolve; isolve++) { + Vnm_tprint(1, " Solve #%d...\n", isolve); +- if (!solveFE(i, nosh, pbeparm, feparm, fetk)) { ++ if (!solveFE(i, pbeparm, feparm, fetk)) { + Vnm_tprint(2, "ERROR SOLVING EQUATION!\n"); + VJMPERR1(0); + } +@@ -622,7 +622,7 @@ int apbsdrv_( + /* We're not going to refine if we've hit the max number + * of solves */ + if (isolve < (feparm->maxsolve)-1) { +- if (!postRefineFE(i, nosh, feparm, fetk)) break; ++ if (!postRefineFE(i, feparm, fetk)) break; + } + bytesTotal = Vmem_bytesTotal(); + highWater = Vmem_highWaterTotal(); +diff --git a/apbs/src/CMakeLists.txt b/apbs/src/CMakeLists.txt +index 44d20fa..2577343 100644 +--- a/apbs/src/CMakeLists.txt ++++ b/apbs/src/CMakeLists.txt +@@ -68,6 +68,7 @@ configure_file( + + if(ENABLE_iAPBS) + ADD_LIBRARY(apbs_routines routines.c routines.h) ++ target_link_libraries(apbs_routines apbs_mg apbs_fem) + INSTALL(TARGETS apbs_routines DESTINATION ${LIBRARY_INSTALL_PATH}) + INSTALL(FILES apbscfg.h DESTINATION ${HEADER_INSTALL_PATH}) + endif() +diff --git a/apbs/tools/CMakeLists.txt b/apbs/tools/CMakeLists.txt +index 1982a3c..4acbe68 100644 +--- a/apbs/tools/CMakeLists.txt ++++ b/apbs/tools/CMakeLists.txt +@@ -4,5 +4,5 @@ add_subdirectory(mesh) + add_subdirectory(manip) + + if(ENABLE_PYTHON) +- add_subdirectory(manip) ++ add_subdirectory(python) + endif(ENABLE_PYTHON) +diff --git a/apbs/tools/python/CMakeLists.txt b/apbs/tools/python/CMakeLists.txt +new file mode 100644 +index 0000000..8b13789 +--- /dev/null ++++ b/apbs/tools/python/CMakeLists.txt +@@ -0,0 +1 @@ ++ +diff --git a/apbs/tools/python/apbslib.c b/apbs/tools/python/apbslib.c +index fef5cc8..feaaa2c 100644 +--- a/apbs/tools/python/apbslib.c ++++ b/apbs/tools/python/apbslib.c +@@ -2504,8 +2504,8 @@ static swig_module_info swig_module = {swig_types, 24, 0, 0, 0, 0}; + #include "maloc/maloc.h" + #include "apbscfg.h" + #include "routines.h" +-#include "apbs/valist.h" +-#include "apbs/vatom.h" ++#include "generic/valist.h" ++#include "generic/vatom.h" + + + #include <limits.h> +diff --git a/apbs/tools/python/apbslib.i b/apbs/tools/python/apbslib.i +index 17fe521..44d05ea 100644 +--- a/apbs/tools/python/apbslib.i ++++ b/apbs/tools/python/apbslib.i +@@ -15,8 +15,8 @@ Header files: + #include "maloc/maloc.h" + #include "apbscfg.h" + #include "routines.h" +-#include "apbs/valist.h" +-#include "apbs/vatom.h" ++#include "generic/valist.h" ++#include "generic/vatom.h" + %} + + /* +diff --git a/apbs/tools/python/setup.py b/apbs/tools/python/setup.py +new file mode 100644 +index 0000000..4a20198 +--- /dev/null ++++ b/apbs/tools/python/setup.py +@@ -0,0 +1,16 @@ ++from distutils.core import setup, Extension ++setup(name='apbs', ++ version='1.4.1', ++ package_dir={'apbs': '', 'vgrid': 'vgrid'}, ++ packages=['apbs', 'vgrid'], ++ py_modules=['apbslib', 'main', 'noinput'], ++ ext_modules=[ ++ Extension( ++ '_apbslib', ++ ['apbslib.i'], ++ swig_opts=['-module', 'apbslib', '-I../include'], ++ include_dirs=["../../src"], ++ libraries=["apbs_generic", "apbs_routines"] ++ ) ++ ], ++ ) |