summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJustin Lecher <jlec@gentoo.org>2012-03-28 12:34:56 +0000
committerJustin Lecher <jlec@gentoo.org>2012-03-28 12:34:56 +0000
commite485a2dae896e2724f8506f466e49881dcb94d04 (patch)
treebf078768f7803e07c8e98c705e52dd17ad4b0551 /sci-chemistry/pymol
parentinitial import, ebuild by me (diff)
downloadgentoo-2-e485a2dae896e2724f8506f466e49881dcb94d04.tar.gz
gentoo-2-e485a2dae896e2724f8506f466e49881dcb94d04.tar.bz2
gentoo-2-e485a2dae896e2724f8506f466e49881dcb94d04.zip
Add missing wrong usage of PYMOL_PATH, #409971
(Portage version: 2.2.0_alpha96/cvs/Linux x86_64)
Diffstat (limited to 'sci-chemistry/pymol')
-rw-r--r--sci-chemistry/pymol/ChangeLog8
-rw-r--r--sci-chemistry/pymol/files/pymol-1.5.0.1-data-path.patch18
-rw-r--r--sci-chemistry/pymol/pymol-1.5.0.3-r1.ebuild120
3 files changed, 138 insertions, 8 deletions
diff --git a/sci-chemistry/pymol/ChangeLog b/sci-chemistry/pymol/ChangeLog
index 3aa6322d350e..b32f325782c0 100644
--- a/sci-chemistry/pymol/ChangeLog
+++ b/sci-chemistry/pymol/ChangeLog
@@ -1,6 +1,12 @@
# ChangeLog for sci-chemistry/pymol
# Copyright 1999-2012 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/sci-chemistry/pymol/ChangeLog,v 1.86 2012/03/10 09:31:31 jlec Exp $
+# $Header: /var/cvsroot/gentoo-x86/sci-chemistry/pymol/ChangeLog,v 1.87 2012/03/28 12:34:56 jlec Exp $
+
+*pymol-1.5.0.3-r1 (28 Mar 2012)
+
+ 28 Mar 2012; Justin Lecher <jlec@gentoo.org>
+ files/pymol-1.5.0.1-data-path.patch, +pymol-1.5.0.3-r1.ebuild:
+ Add missing wrong usage of PYMOL_PATH, #409971
*pymol-1.5.0.3 (10 Mar 2012)
diff --git a/sci-chemistry/pymol/files/pymol-1.5.0.1-data-path.patch b/sci-chemistry/pymol/files/pymol-1.5.0.1-data-path.patch
index e865bfd04174..a2b09bb9eee3 100644
--- a/sci-chemistry/pymol/files/pymol-1.5.0.1-data-path.patch
+++ b/sci-chemistry/pymol/files/pymol-1.5.0.1-data-path.patch
@@ -4,8 +4,8 @@
modules/chempy/tinker/__init__.py | 2 +-
modules/pymol/commanding.py | 6 +++---
modules/pymol/importing.py | 2 +-
- modules/pymol/wizard/mutagenesis.py | 4 ++--
- 7 files changed, 17 insertions(+), 17 deletions(-)
+ modules/pymol/wizard/mutagenesis.py | 8 ++++----
+ 7 files changed, 19 insertions(+), 19 deletions(-)
diff --git a/layer0/ShaderMgr.c b/layer0/ShaderMgr.c
index cc760ae..364277f 100644
@@ -74,7 +74,7 @@ index 23dbe45..795a223 100644
path = os.environ['PYMOL_DATA'] + '/chempy/'
elif os.environ.has_key('PYMOL_PATH'):
- path = os.environ['PYMOL_PATH'] + '/data/chempy/'
-+ path = os.environ['PYMOL_PATH'] + '/chempy/'
++ path = os.environ['PYMOL_PATH'] + '/chempy/'
elif os.environ.has_key('FREEMOL_MODULES'):
path = os.environ['FREEMOL_MODULES'] + '/chempy/'
else:
@@ -127,20 +127,24 @@ diff --git a/modules/pymol/wizard/mutagenesis.py b/modules/pymol/wizard/mutagene
index 8a5250d..6c1b26c 100644
--- a/modules/pymol/wizard/mutagenesis.py
+++ b/modules/pymol/wizard/mutagenesis.py
-@@ -53,7 +53,7 @@ class Mutagenesis(Wizard):
+@@ -52,8 +52,8 @@ class Mutagenesis(Wizard):
+
self.dep = default_dep
- self.ind_library = io.pkl.fromFile(os.environ['PYMOL_PATH']+
+- self.ind_library = io.pkl.fromFile(os.environ['PYMOL_PATH']+
- "/data/chempy/sidechains/sc_bb_ind.pkl")
++ self.ind_library = io.pkl.fromFile(os.environ['PYMOL_DATA']+
+ "/chempy/sidechains/sc_bb_ind.pkl")
self.load_library()
self.status = 0 # 0 no selection, 1 mutagenizing
self.bump_check = 1
-@@ -218,7 +218,7 @@ class Mutagenesis(Wizard):
+@@ -217,8 +217,8 @@ class Mutagenesis(Wizard):
+ def load_library(self):
if self.dep == 'dep':
if not hasattr(self,'dep_library'):
- self.dep_library = io.pkl.fromFile(os.environ['PYMOL_PATH']+
+- self.dep_library = io.pkl.fromFile(os.environ['PYMOL_PATH']+
- "/data/chempy/sidechains/sc_bb_dep.pkl")
++ self.dep_library = io.pkl.fromFile(os.environ['PYMOL_DATA']+
+ "/chempy/sidechains/sc_bb_dep.pkl")
def set_mode(self,mode):
diff --git a/sci-chemistry/pymol/pymol-1.5.0.3-r1.ebuild b/sci-chemistry/pymol/pymol-1.5.0.3-r1.ebuild
new file mode 100644
index 000000000000..c3a348f84c11
--- /dev/null
+++ b/sci-chemistry/pymol/pymol-1.5.0.3-r1.ebuild
@@ -0,0 +1,120 @@
+# Copyright 1999-2012 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/sci-chemistry/pymol/pymol-1.5.0.3-r1.ebuild,v 1.1 2012/03/28 12:34:56 jlec Exp $
+
+EAPI=4
+
+PYTHON_DEPEND="2:2.7"
+SUPPORT_PYTHON_ABIS="1"
+RESTRICT_PYTHON_ABIS="2.4 2.5 2.6 3.* *-jython 2.7-pypy-*"
+PYTHON_USE_WITH="tk"
+PYTHON_MODNAME="${PN} chempy pmg_tk pmg_wx"
+
+inherit distutils eutils fdo-mime prefix versionator
+
+DESCRIPTION="A Python-extensible molecular graphics system"
+HOMEPAGE="http://pymol.sourceforge.net/"
+SRC_URI="
+ http://dev.gentoo.org/~jlec/distfiles/${P}.tar.xz
+ http://dev.gentoo.org/~jlec/distfiles/${PN}.xpm.tar"
+
+LICENSE="PSF-2.2"
+SLOT="0"
+KEYWORDS="~amd64 ~ppc ~x86 ~amd64-linux ~x86-linux"
+IUSE="apbs numpy vmd web"
+
+DEPEND="
+ dev-python/numpy
+ dev-python/pmw
+ media-libs/freetype:2
+ media-libs/glew
+ media-libs/libpng
+ media-video/mpeg-tools
+ sys-libs/zlib
+ media-libs/freeglut
+ apbs? (
+ dev-libs/maloc
+ sci-chemistry/apbs
+ sci-chemistry/pdb2pqr
+ sci-chemistry/pymol-apbs-plugin
+ )
+ web? ( !dev-python/webpy )"
+RDEPEND="${DEPEND}"
+
+src_prepare() {
+ epatch \
+ "${FILESDIR}"/${PN}-1.5.0.1-setup.py.patch \
+ "${FILESDIR}"/${PN}-1.5.0.1-data-path.patch \
+ "${FILESDIR}"/${PN}-1.5.0.1-flags.patch
+
+ use web || epatch "${FILESDIR}"/${P}-web.patch
+
+ epatch "${FILESDIR}"/${P}-prefix.patch && \
+ eprefixify setup.py
+
+ use vmd && epatch "${FILESDIR}"/${PN}-1.5.0.1-vmd.patch
+
+ if use numpy; then
+ sed \
+ -e '/PYMOL_NUMPY/s:^#::g' \
+ -i setup.py || die
+ fi
+
+ rm ./modules/pmg_tk/startup/apbs_tools.py || die
+
+ echo "site_packages = \'$(python_get_sitedir -f)\'" > setup3.py || die
+
+ # python 3.* fix
+ # sed '452,465d' -i setup.py
+ distutils_src_prepare
+}
+
+src_configure() {
+ :
+}
+
+src_install() {
+ distutils_src_install
+
+ # These environment variables should not go in the wrapper script, or else
+ # it will be impossible to use the PyMOL libraries from Python.
+ cat >> "${T}"/20pymol <<- EOF
+ PYMOL_PATH="${EPREFIX}/$(python_get_sitedir -f)/${PN}"
+ PYMOL_DATA="${EPREFIX}/usr/share/pymol/data"
+ PYMOL_SCRIPTS="${EPREFIX}/usr/share/pymol/scripts"
+ EOF
+
+ doenvd "${T}"/20pymol
+
+ cat >> "${T}"/pymol <<- EOF
+ #!/bin/sh
+ $(PYTHON -f) -O \${PYMOL_PATH}/__init__.py -q \$*
+ EOF
+
+ dobin "${T}"/pymol
+
+ insinto /usr/share/pymol
+ doins -r test data scripts
+
+ insinto /usr/share/pymol/examples
+ doins -r examples
+
+ dodoc DEVELOPERS README
+
+ doicon "${WORKDIR}"/${PN}.xpm
+ make_desktop_entry pymol PyMol ${PN} "Graphics;Science;Chemistry"
+}
+
+pkg_postinst() {
+ elog "\t USE=shaders was removed,"
+ elog "please use pymol config settings"
+ elog "\t set use_shaders, 1"
+ distutils_pkg_postinst
+ fdo-mime_desktop_database_update
+ fdo-mime_mime_database_update
+}
+
+pkg_postrm() {
+ fdo-mime_desktop_database_update
+ fdo-mime_mime_database_update
+}