diff options
author | Justin Lecher <jlec@gentoo.org> | 2011-12-21 13:46:42 +0000 |
---|---|---|
committer | Justin Lecher <jlec@gentoo.org> | 2011-12-21 13:46:42 +0000 |
commit | 0dbe51999a692bda85d201c1151c4b226b1b28f3 (patch) | |
tree | ab8175245dd0be67b5fd5f3c35f7ad77c6f5d1eb /sci-chemistry/ccpn | |
parent | changelog for linux/profile.bashrc (diff) | |
download | historical-0dbe51999a692bda85d201c1151c4b226b1b28f3.tar.gz historical-0dbe51999a692bda85d201c1151c4b226b1b28f3.tar.bz2 historical-0dbe51999a692bda85d201c1151c4b226b1b28f3.zip |
Todays Python Patches
Package-Manager: portage-2.2.0_alpha81/cvs/Linux x86_64
Diffstat (limited to 'sci-chemistry/ccpn')
-rw-r--r-- | sci-chemistry/ccpn/ChangeLog | 9 | ||||
-rw-r--r-- | sci-chemistry/ccpn/Manifest | 12 | ||||
-rw-r--r-- | sci-chemistry/ccpn/ccpn-2.1.5_p111221.ebuild | 214 | ||||
-rw-r--r-- | sci-chemistry/ccpn/ccpn-2.2.1_p111221.ebuild | 214 |
4 files changed, 444 insertions, 5 deletions
diff --git a/sci-chemistry/ccpn/ChangeLog b/sci-chemistry/ccpn/ChangeLog index e1be611d98f2..d5aa8f7216d1 100644 --- a/sci-chemistry/ccpn/ChangeLog +++ b/sci-chemistry/ccpn/ChangeLog @@ -1,6 +1,13 @@ # ChangeLog for sci-chemistry/ccpn # Copyright 1999-2011 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/sci-chemistry/ccpn/ChangeLog,v 1.77 2011/12/20 08:39:39 jlec Exp $ +# $Header: /var/cvsroot/gentoo-x86/sci-chemistry/ccpn/ChangeLog,v 1.78 2011/12/21 13:46:42 jlec Exp $ + +*ccpn-2.2.1_p111221 (21 Dec 2011) +*ccpn-2.1.5_p111221 (21 Dec 2011) + + 21 Dec 2011; Justin Lecher <jlec@gentoo.org> +ccpn-2.1.5_p111221.ebuild, + +ccpn-2.2.1_p111221.ebuild: + Todays Python Patches *ccpn-2.2.1_p111220 (20 Dec 2011) *ccpn-2.1.5_p111220 (20 Dec 2011) diff --git a/sci-chemistry/ccpn/Manifest b/sci-chemistry/ccpn/Manifest index b3f9cff13393..c1525f8b9942 100644 --- a/sci-chemistry/ccpn/Manifest +++ b/sci-chemistry/ccpn/Manifest @@ -21,19 +21,23 @@ DIST analysis2.2.1.tar.gz 20974926 RMD160 5905f43fc1399a656f018808c4a2f8dd3d247c DIST ccpn-update-100806.patch.bz2 187965 RMD160 3297162fe3314aa405ee58737ce45cda084834e5 SHA1 338423d9f36da3fb10dc9d9a3b8aeb932ae3bfd0 SHA256 5cea7899edb96237a6674f04a1beee6ad7b309e12964ea8b25d9ea6ff752d0d4 DIST ccpn-update-2.1.5-111213.patch.xz 104892 RMD160 d2a83a0b809a91f8f8422a24c11ce20a8e2cde8d SHA1 ae819afdf4cb6aa39c9059cd1bb96d3d188a86fb SHA256 72bbe7f2a68ee20eca029685b8b3daaf15f71d164767b3aa5d222c3a5de779b1 DIST ccpn-update-2.1.5-111220.patch.xz 105472 RMD160 f8c358e7bc7757a4f645a2f26fa38e0159e5bc2f SHA1 21721845d3f0df77c548a3e5774ed5a82f3d12df SHA256 a4d8d4982c8bf63031cd11cbe67121a598b97f1c490862c363555bf9c2f11140 +DIST ccpn-update-2.1.5-111221.patch.xz 105424 RMD160 70f3b43b0ef4a827cb43f4673ca426deacff13d5 SHA1 6a240d2db8afe9166c8965207ac6701859089fba SHA256 fa9385c46b2aa535917b68de1c9ac0a0dcf0e4a3b2362ec75274fe8374289ca6 DIST ccpn-update-2.2.1-111213.patch.xz 81520 RMD160 55038a1272f8e01ce54fefdba081ee51ec5d4f36 SHA1 0bbd8c029a98b282002d8b5385a85355722de323 SHA256 807cef8e8b2822e178d50695c7e234ea8c243264a4711610f6a95e30e1b40d12 DIST ccpn-update-2.2.1-111220.patch.xz 82840 RMD160 c0fb328ad93d7f07e1f0d45215d7686204315f91 SHA1 7b2ef76c62e85fcb4c5c95be053a9e281bc3d59d SHA256 f8942568e4f859da71e5a38b279355222882de19328501a0297bcddefef75c9f +DIST ccpn-update-2.2.1-111221.patch.xz 82988 RMD160 e1ce373080f97411d9b00a269d8ed29ab8a4db0e SHA1 fe68eccce53bbbc7cfd69d398381cf3b28303c2d SHA256 6482ac0a90b34e4fbb6944a2f158d8743f6a23d7b28193b28fe7517044e27a76 EBUILD ccpn-2.1.3.1_p100806.ebuild 5188 RMD160 b66825e37b79a5f6ec6635b9f3236d1cda2da672 SHA1 458f516ffad25d9283b21c9dfb8e50c6323f4264 SHA256 ff57abefefd3bb128a3f96bf039cbaa5ed97350f6b41fdbdd4b4365ff9e68e51 EBUILD ccpn-2.1.5_p111213.ebuild 5773 RMD160 4fc120d9e6c5ecfd375a3df14a7b8b9afdebb3b5 SHA1 30bb2d2e22087ac6c93434863f1347db50f2514f SHA256 46de0ddcfd2fcb196dfb9ceb07c74c25ff3c8f4655b55f5e4b2f1d90a3787641 EBUILD ccpn-2.1.5_p111220.ebuild 5773 RMD160 726f13ab2aa4532df15cbdc5a96b15293e53791e SHA1 5038f1c70ee0979181278ad3bbc9cdafff54d81c SHA256 7c21ffd5368b3a1c46ee838be8b970c6f7af371ea1048a253eca9c4c73af40c8 +EBUILD ccpn-2.1.5_p111221.ebuild 5773 RMD160 466f12257ec67eb942856702439f3f3b980618e7 SHA1 c7b160431d76ec2d619d4af84c24daf29a7594af SHA256 64429004d43a013ddeaad65e5aa7e6df9aafb1a5ff05455864f8ed88918bc5de EBUILD ccpn-2.2.1_p111213.ebuild 5788 RMD160 49f50c489d3eee93f80e1548c66fe2acf1131e20 SHA1 fe36614826a38746d32f32071f8583744fa263fd SHA256 2f25c2e6e348f37d95bc89dc36137303def1c66a02ff1603eedb8c32f61867e4 EBUILD ccpn-2.2.1_p111220.ebuild 5788 RMD160 abb85d91207669ef94be18d38b4e9efc5dca135b SHA1 e07108a62c4867be2d4538a0ecf09bf5ac4dd968 SHA256 37885cacf0a4e97d05201b18949b87889c5e5965f04434399a2e52b24d30cf98 -MISC ChangeLog 15772 RMD160 c68edc0742245f733471de2f8a86ece12bf87eaa SHA1 d89dbad83be0b61e2d45f28aa8880ac6cd3b2e41 SHA256 cc398ca99864b9d79c0e4d305c0e73b535b35ed265b79859e6d148e9ca936667 +EBUILD ccpn-2.2.1_p111221.ebuild 5788 RMD160 e722eaef088dbe8f273190fed6331157ab57c553 SHA1 97328118dcde05d92d7d5410f61a8c2b9b5badc5 SHA256 72216a2ec437f6cafa02eb435fffcf97bc274c5d6009f303a3eb214bd08badf5 +MISC ChangeLog 15971 RMD160 327d2cf3b19ca3896e89d61188e7a29f251ebb30 SHA1 34239192b5ccea8cd4abac9554b38722311034c4 SHA256 05786084d91cf44b8c6a11f0b5cd3c31cd3a423e7b9cedbcd5ef50d28171d674 MISC metadata.xml 322 RMD160 9fd5fba7405b689fc39a089d81ffdaa9f961b514 SHA1 0c31132b25fca04cff97ef11fdc11940f90c77d0 SHA256 7468ba4c27b879e7ed5f82274f5837e51f1f389673a33b9e26e1756a6b0783df -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.18 (GNU/Linux) -iEYEAREKAAYFAk7wSdEACgkQgAnW8HDreRZj1QCfXIwKGWDwVPFSOBFie1P44pQN -HMIAoKmvPclmOC7NgfuAyVdqJKgk/QXz -=iA0C +iEYEAREKAAYFAk7x40cACgkQgAnW8HDreRaDZwCfbvIO+XQ1m5fS2/IVaSfQoNYy +JyYAn3Z+v1KFX/4areJfAxGVs1zhtpbn +=5hLj -----END PGP SIGNATURE----- diff --git a/sci-chemistry/ccpn/ccpn-2.1.5_p111221.ebuild b/sci-chemistry/ccpn/ccpn-2.1.5_p111221.ebuild new file mode 100644 index 000000000000..260983cbe464 --- /dev/null +++ b/sci-chemistry/ccpn/ccpn-2.1.5_p111221.ebuild @@ -0,0 +1,214 @@ +# Copyright 1999-2011 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/sci-chemistry/ccpn/ccpn-2.1.5_p111221.ebuild,v 1.1 2011/12/21 13:46:42 jlec Exp $ + +EAPI="3" + +PYTHON_DEPEND="2:2.5" +PYTHON_USE_WITH="ssl tk" + +inherit eutils portability python toolchain-funcs versionator + +PATCHSET="${PV##*_p}" +MY_PN="${PN}mr" +MY_PV="$(replace_version_separator 3 _ ${PV%%_p*})" +MY_MAJOR="$(get_version_component_range 1-3)" + +DESCRIPTION="The Collaborative Computing Project for NMR" +HOMEPAGE="http://www.ccpn.ac.uk/ccpn" +SRC_URI="http://www.bio.cam.ac.uk/ccpn/download/${MY_PN}/analysis${MY_PV}.tar.gz" + [[ -n ${PATCHSET} ]] && SRC_URI="${SRC_URI} http://dev.gentoo.org/~jlec/distfiles/ccpn-update-${MY_MAJOR}-${PATCHSET}.patch.xz" + +SLOT="0" +LICENSE="|| ( CCPN LGPL-2.1 )" +KEYWORDS="~amd64 ~x86 ~amd64-linux ~x86-linux" +IUSE="extendnmr +opengl" + +RDEPEND=" + dev-lang/tk[threads] + >=dev-python/numpy-1.4 + >=dev-tcltk/tix-8.4.3 + =sci-libs/ccpn-data-"${MY_MAJOR}"* + >=sci-libs/ccpn-data-2.1.5_p111011 + sci-biology/psipred + x11-libs/libXext + x11-libs/libX11 + opengl? ( + media-libs/freeglut + dev-python/pyglet )" +# We need to fix this +# sci-chemistry/mdd +DEPEND="${RDEPEND}" +PDEPEND=" + extendnmr? ( + <=sci-chemistry/aria-2.3.2 + sci-chemistry/prodecomp )" + +RESTRICT="mirror" + +S="${WORKDIR}"/${MY_PN}/${MY_PN}$(get_version_component_range 1-2 ${PV}) + +pkg_setup() { + python_set_active_version 2 +} + +src_prepare() { + [[ -n ${PATCHSET} ]] && \ + epatch "${WORKDIR}"/ccpn-update-${MY_MAJOR}-${PATCHSET}.patch + + epatch "${FILESDIR}"/${MY_PV}-parallel.patch + + sed \ + -e "/PSIPRED_DIR/s:'data':'share/psipred/data':g" \ + -e "s:weights_s:weights:g" \ + -i python/ccpnmr/analysis/wrappers/Psipred.py || die + + local tk_ver + local myconf + + tk_ver="$(best_version dev-lang/tk | cut -d- -f3 | cut -d. -f1,2)" + + if use opengl; then + GLUT_NEED_INIT="-DNEED_GLUT_INIT" + IGNORE_GL_FLAG="" + GL_FLAG="-DUSE_GL_TRUE" + GL_DIR="${EPREFIX}/usr" + GL_LIB="-lglut -lGLU -lGL" + GL_INCLUDE_FLAGS="-I\$(GL_DIR)/include" + GL_LIB_FLAGS="-L\$(GL_DIR)/$(get_libdir)" + + else + IGNORE_GL_FLAG="-DIGNORE_GL" + GL_FLAG="-DUSE_GL_FALSE" + fi + + GLUT_NOT_IN_GL="" + GLUT_FLAG="\$(GLUT_NEED_INIT) \$(GLUT_NOT_IN_GL)" + + rm -rf data model doc license || die + + sed \ + -e "s|/usr|${EPREFIX}/usr|g" \ + -e "s|^\(CC =\).*|\1 $(tc-getCC)|g" \ + -e "s|^\(OPT_FLAG =\).*|\1 ${CFLAGS}|g" \ + -e "s|^\(LINK_FLAGS =.*\)|\1 ${LDFLAGS}|g" \ + -e "s|^\(IGNORE_GL_FLAG =\).*|\1 ${IGNORE_GL_FLAG}|g" \ + -e "s|^\(GL_FLAG =\).*|\1 ${GL_FLAG}|g" \ + -e "s|^\(GL_DIR =\).*|\1 ${GL_DIR}|g" \ + -e "s|^\(GL_LIB =\).*|\1 ${GL_LIB}|g" \ + -e "s|^\(GL_LIB_FLAGS =\).*|\1 ${GL_LIB_FLAGS}|g" \ + -e "s|^\(GL_INCLUDE_FLAGS =\).*|\1 ${GL_INCLUDE_FLAGS}|g" \ + -e "s|^\(GLUT_NEED_INIT =\).*|\1 ${GLUT_NEED_INIT}|g" \ + -e "s|^\(GLUT_NOT_IN_GL =\).*|\1|g" \ + -e "s|^\(X11_LIB_FLAGS =\).*|\1 -L${EPREFIX}/usr/$(get_libdir)|g" \ + -e "s|^\(TCL_LIB_FLAGS =\).*|\1 -L${EPREFIX}/usr/$(get_libdir)|g" \ + -e "s|^\(TK_LIB_FLAGS =\).*|\1 -L${EPREFIX}/usr/$(get_libdir)|g" \ + -e "s|^\(PYTHON_INCLUDE_FLAGS =\).*|\1 -I${EPREFIX}/$(python_get_includedir)|g" \ + -e "s|^\(PYTHON_LIB =\).*|\1 $(python_get_library -l)|g" \ + c/environment_default.txt > c/environment.txt +} + +src_compile() { + emake -C c all links || die +} + +src_install() { + local libdir + local tkver + local _wrapper + + find . -name "*.pyc" -type d -delete + + libdir=$(get_libdir) + tkver=$(best_version dev-lang/tk | cut -d- -f3 | cut -d. -f1,2) + + _wrapper="analysis dangle dataShifter depositionFileImporter eci formatConverter pipe2azara" + use extendnmr && _wrapper="${_wrapper} extendNmr" + for wrapper in ${_wrapper}; do + sed \ + -e "s|gentoo_sitedir|${EPREFIX}$(python_get_sitedir)|g" \ + -e "s|gentoolibdir|${EPREFIX}/usr/${libdir}|g" \ + -e "s|gentootk|${EPREFIX}/usr/${libdir}/tk${tkver}|g" \ + -e "s|gentootcl|${EPREFIX}/usr/${libdir}/tclk${tkver}|g" \ + -e "s|gentoopython|${EPREFIX}/usr/bin/python|g" \ + -e "s|gentoousr|${EPREFIX}/usr|g" \ + -e "s|//|/|g" \ + "${FILESDIR}"/${wrapper} > "${T}"/${wrapper} || die "Fail fix ${wrapper}" + dobin "${T}"/${wrapper} || die "Failed to install ${wrapper}" + done + + local in_path + local files + local pydocs + + pydocs="$(find python -name doc -type d)" + rm -rf ${pydocs} || die + + in_path=$(python_get_sitedir)/${PN} + + for i in python/memops/format/compatibility/{Converters,part2/Converters2}.py; do + sed \ + -e 's|#from __future__|from __future__|g' \ + -i ${i} || die + done + + insinto ${in_path} + + dodir ${in_path}/c + + ebegin "Installing main files" + doins -r python || die "main files installation failed" + eend + + einfo "Adjusting permissions" + + files=" + cambridge/c/BayesPeakSeparator.so + ccp/c/StructUtil.so + ccp/c/StructStructure.so + ccp/c/StructBond.so + ccp/c/StructAtom.so + ccpnmr/c/DyAtomCoord.so + ccpnmr/c/DyDistConstraint.so + ccpnmr/c/DyDistForce.so + ccpnmr/c/AtomCoordList.so + ccpnmr/c/DyAtomCoordList.so + ccpnmr/c/ContourStyle.so + ccpnmr/c/ContourLevels.so + ccpnmr/c/SliceFile.so + ccpnmr/c/PeakCluster.so + ccpnmr/c/Dynamics.so + ccpnmr/c/Bacus.so + ccpnmr/c/Midge.so + ccpnmr/c/DyDistConstraintList.so + ccpnmr/c/WinPeakList.so + ccpnmr/c/PeakList.so + ccpnmr/c/DistConstraint.so + ccpnmr/c/CloudUtil.so + ccpnmr/c/DistForce.so + ccpnmr/c/DistConstraintList.so + ccpnmr/c/AtomCoord.so + ccpnmr/c/DyDynamics.so + ccpnmr/c/ContourFile.so + memops/c/ShapeFile.so + memops/c/BlockFile.so + memops/c/PdfHandler.so + memops/c/MemCache.so + memops/c/FitMethod.so + memops/c/PsHandler.so + memops/c/GlHandler.so + memops/c/StoreFile.so + memops/c/StoreHandler.so + memops/c/TkHandler.so" + for FILE in ${files}; do + fperms 755 ${in_path}/python/${FILE} + done +} + +pkg_postinst() { + python_mod_optimize ${PN} +} + +pkg_postrm() { + python_mod_cleanup ${PN} +} diff --git a/sci-chemistry/ccpn/ccpn-2.2.1_p111221.ebuild b/sci-chemistry/ccpn/ccpn-2.2.1_p111221.ebuild new file mode 100644 index 000000000000..a7fddbd45dd4 --- /dev/null +++ b/sci-chemistry/ccpn/ccpn-2.2.1_p111221.ebuild @@ -0,0 +1,214 @@ +# Copyright 1999-2011 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/sci-chemistry/ccpn/ccpn-2.2.1_p111221.ebuild,v 1.1 2011/12/21 13:46:42 jlec Exp $ + +EAPI="3" + +PYTHON_DEPEND="2:2.5" +PYTHON_USE_WITH="ssl tk" + +inherit eutils portability python toolchain-funcs versionator + +PATCHSET="${PV##*_p}" +MY_PN="${PN}mr" +MY_PV="$(replace_version_separator 3 _ ${PV%%_p*})" +MY_MAJOR="$(get_version_component_range 1-3)" + +DESCRIPTION="The Collaborative Computing Project for NMR" +SRC_URI="http://www.bio.cam.ac.uk/ccpn/download/${MY_PN}/analysis${MY_PV}.tar.gz" + [[ -n ${PATCHSET} ]] && SRC_URI="${SRC_URI} http://dev.gentoo.org/~jlec/distfiles/ccpn-update-${MY_MAJOR}-${PATCHSET}.patch.xz" +HOMEPAGE="http://www.ccpn.ac.uk/ccpn" + +SLOT="0" +LICENSE="|| ( CCPN LGPL-2.1 )" +KEYWORDS="~amd64 ~x86 ~amd64-linux ~x86-linux" +IUSE="extendnmr +opengl" + +RDEPEND=" + dev-lang/tk[threads] + >=dev-python/numpy-1.4 + >=dev-tcltk/tix-8.4.3 + =sci-libs/ccpn-data-"${MY_MAJOR}"* + >=sci-libs/ccpn-data-2.2.1_p111011 + sci-biology/psipred + x11-libs/libXext + x11-libs/libX11 + opengl? ( + media-libs/freeglut + dev-python/pyglet )" +# We need to fix this +# sci-chemistry/mdd +DEPEND="${RDEPEND}" +PDEPEND=" + extendnmr? ( + >=sci-chemistry/aria-2.3.2-r1 + sci-chemistry/prodecomp )" + +RESTRICT="mirror" + +S="${WORKDIR}"/${MY_PN}/${MY_PN}$(get_version_component_range 1-2 ${PV}) + +pkg_setup() { + python_set_active_version 2 +} + +src_prepare() { + [[ -n ${PATCHSET} ]] && \ + epatch "${WORKDIR}"/ccpn-update-${MY_MAJOR}-${PATCHSET}.patch + + epatch "${FILESDIR}"/${MY_PV}-parallel.patch + + sed \ + -e "/PSIPRED_DIR/s:'data':'share/psipred/data':g" \ + -e "s:weights_s:weights:g" \ + -i python/ccpnmr/analysis/wrappers/Psipred.py || die + + local tk_ver + local myconf + + tk_ver="$(best_version dev-lang/tk | cut -d- -f3 | cut -d. -f1,2)" + + if use opengl; then + GLUT_NEED_INIT="-DNEED_GLUT_INIT" + IGNORE_GL_FLAG="" + GL_FLAG="-DUSE_GL_TRUE" + GL_DIR="${EPREFIX}/usr" + GL_LIB="-lglut -lGLU -lGL" + GL_INCLUDE_FLAGS="-I\$(GL_DIR)/include" + GL_LIB_FLAGS="-L\$(GL_DIR)/$(get_libdir)" + + else + IGNORE_GL_FLAG="-DIGNORE_GL" + GL_FLAG="-DUSE_GL_FALSE" + fi + + GLUT_NOT_IN_GL="" + GLUT_FLAG="\$(GLUT_NEED_INIT) \$(GLUT_NOT_IN_GL)" + + rm -rf data model doc license || die + + sed \ + -e "s|/usr|${EPREFIX}/usr|g" \ + -e "s|^\(CC =\).*|\1 $(tc-getCC)|g" \ + -e "s|^\(OPT_FLAG =\).*|\1 ${CFLAGS}|g" \ + -e "s|^\(LINK_FLAGS =.*\)|\1 ${LDFLAGS}|g" \ + -e "s|^\(IGNORE_GL_FLAG =\).*|\1 ${IGNORE_GL_FLAG}|g" \ + -e "s|^\(GL_FLAG =\).*|\1 ${GL_FLAG}|g" \ + -e "s|^\(GL_DIR =\).*|\1 ${GL_DIR}|g" \ + -e "s|^\(GL_LIB =\).*|\1 ${GL_LIB}|g" \ + -e "s|^\(GL_LIB_FLAGS =\).*|\1 ${GL_LIB_FLAGS}|g" \ + -e "s|^\(GL_INCLUDE_FLAGS =\).*|\1 ${GL_INCLUDE_FLAGS}|g" \ + -e "s|^\(GLUT_NEED_INIT =\).*|\1 ${GLUT_NEED_INIT}|g" \ + -e "s|^\(GLUT_NOT_IN_GL =\).*|\1|g" \ + -e "s|^\(X11_LIB_FLAGS =\).*|\1 -L${EPREFIX}/usr/$(get_libdir)|g" \ + -e "s|^\(TCL_LIB_FLAGS =\).*|\1 -L${EPREFIX}/usr/$(get_libdir)|g" \ + -e "s|^\(TK_LIB_FLAGS =\).*|\1 -L${EPREFIX}/usr/$(get_libdir)|g" \ + -e "s|^\(PYTHON_INCLUDE_FLAGS =\).*|\1 -I${EPREFIX}/$(python_get_includedir)|g" \ + -e "s|^\(PYTHON_LIB =\).*|\1 $(python_get_library -l)|g" \ + c/environment_default.txt > c/environment.txt +} + +src_compile() { + emake -C c all links || die +} + +src_install() { + local libdir + local tkver + local _wrapper + + find . -name "*.pyc" -type d -delete + + libdir=$(get_libdir) + tkver=$(best_version dev-lang/tk | cut -d- -f3 | cut -d. -f1,2) + + _wrapper="analysis dangle dataShifter depositionFileImporter eci formatConverter pipe2azara xeasy2azara" + use extendnmr && _wrapper="${_wrapper} extendNmr" + for wrapper in ${_wrapper}; do + sed \ + -e "s|gentoo_sitedir|${EPREFIX}$(python_get_sitedir)|g" \ + -e "s|gentoolibdir|${EPREFIX}/usr/${libdir}|g" \ + -e "s|gentootk|${EPREFIX}/usr/${libdir}/tk${tkver}|g" \ + -e "s|gentootcl|${EPREFIX}/usr/${libdir}/tclk${tkver}|g" \ + -e "s|gentoopython|${EPREFIX}/usr/bin/python|g" \ + -e "s|gentoousr|${EPREFIX}/usr|g" \ + -e "s|//|/|g" \ + "${FILESDIR}"/${wrapper} > "${T}"/${wrapper} || die "Fail fix ${wrapper}" + dobin "${T}"/${wrapper} || die "Failed to install ${wrapper}" + done + + local in_path + local files + local pydocs + + pydocs="$(find python -name doc -type d)" + rm -rf ${pydocs} || die + + in_path=$(python_get_sitedir)/${PN} + + for i in python/memops/format/compatibility/{Converters,part2/Converters2}.py; do + sed \ + -e 's|#from __future__|from __future__|g' \ + -i ${i} || die + done + + insinto ${in_path} + + dodir ${in_path}/c + + ebegin "Installing main files" + doins -r python || die "main files installation failed" + eend + + einfo "Adjusting permissions" + + files=" + cambridge/c/BayesPeakSeparator.so + ccp/c/StructUtil.so + ccp/c/StructStructure.so + ccp/c/StructBond.so + ccp/c/StructAtom.so + ccpnmr/c/DyAtomCoord.so + ccpnmr/c/DyDistConstraint.so + ccpnmr/c/DyDistForce.so + ccpnmr/c/AtomCoordList.so + ccpnmr/c/DyAtomCoordList.so + ccpnmr/c/ContourStyle.so + ccpnmr/c/ContourLevels.so + ccpnmr/c/SliceFile.so + ccpnmr/c/PeakCluster.so + ccpnmr/c/Dynamics.so + ccpnmr/c/Bacus.so + ccpnmr/c/Midge.so + ccpnmr/c/DyDistConstraintList.so + ccpnmr/c/WinPeakList.so + ccpnmr/c/PeakList.so + ccpnmr/c/DistConstraint.so + ccpnmr/c/CloudUtil.so + ccpnmr/c/DistForce.so + ccpnmr/c/DistConstraintList.so + ccpnmr/c/AtomCoord.so + ccpnmr/c/DyDynamics.so + ccpnmr/c/ContourFile.so + memops/c/ShapeFile.so + memops/c/BlockFile.so + memops/c/PdfHandler.so + memops/c/MemCache.so + memops/c/FitMethod.so + memops/c/PsHandler.so + memops/c/GlHandler.so + memops/c/StoreFile.so + memops/c/StoreHandler.so + memops/c/TkHandler.so" + for FILE in ${files}; do + fperms 755 ${in_path}/python/${FILE} + done +} + +pkg_postinst() { + python_mod_optimize ${PN} +} + +pkg_postrm() { + python_mod_cleanup ${PN} +} |