1 |
commit: 61e0c3c7f9266ad55e969fa6aac83f4c2ad1a823 |
2 |
Author: Justin Lecher <jlec <AT> gentoo <DOT> org> |
3 |
AuthorDate: Mon Mar 25 07:56:54 2013 +0000 |
4 |
Commit: Justin Lecher <jlec <AT> gentoo <DOT> org> |
5 |
CommitDate: Mon Mar 25 07:56:54 2013 +0000 |
6 |
URL: http://git.overlays.gentoo.org/gitweb/?p=proj/sci.git;a=commit;h=61e0c3c7 |
7 |
|
8 |
sci-chemistry/pymol: Sync with tree |
9 |
|
10 |
Package-Manager: portage-2.2.0_alpha169 |
11 |
|
12 |
--- |
13 |
sci-chemistry/pymol/ChangeLog | 3 +++ |
14 |
sci-chemistry/pymol/metadata.xml | 1 + |
15 |
sci-chemistry/pymol/pymol-9999.ebuild | 33 +++++++++++++++++++++++++++------ |
16 |
3 files changed, 31 insertions(+), 6 deletions(-) |
17 |
|
18 |
diff --git a/sci-chemistry/pymol/ChangeLog b/sci-chemistry/pymol/ChangeLog |
19 |
index dad76a9..f5e0f9b 100644 |
20 |
--- a/sci-chemistry/pymol/ChangeLog |
21 |
+++ b/sci-chemistry/pymol/ChangeLog |
22 |
@@ -2,6 +2,9 @@ |
23 |
# Copyright 1999-2013 Gentoo Foundation; Distributed under the GPL v2 |
24 |
# $Header: $ |
25 |
|
26 |
+ 25 Mar 2013; Justin Lecher <jlec@g.o> pymol-9999.ebuild, metadata.xml: |
27 |
+ Sync with tree |
28 |
+ |
29 |
03 Mar 2013; Justin Lecher <jlec@g.o> metadata.xml: |
30 |
Fix missing DOCTYPE |
31 |
|
32 |
|
33 |
diff --git a/sci-chemistry/pymol/metadata.xml b/sci-chemistry/pymol/metadata.xml |
34 |
index 0ced419..bca2106 100644 |
35 |
--- a/sci-chemistry/pymol/metadata.xml |
36 |
+++ b/sci-chemistry/pymol/metadata.xml |
37 |
@@ -7,5 +7,6 @@ |
38 |
</maintainer> |
39 |
<use> |
40 |
<flag name="apbs">Pymol supprt for sci-chemistry/apbs</flag> |
41 |
+ <flag name="web">Install Pymodule needed for web app support</flag> |
42 |
</use> |
43 |
</pkgmetadata> |
44 |
|
45 |
diff --git a/sci-chemistry/pymol/pymol-9999.ebuild b/sci-chemistry/pymol/pymol-9999.ebuild |
46 |
index 6f6c5f7..564732c 100644 |
47 |
--- a/sci-chemistry/pymol/pymol-9999.ebuild |
48 |
+++ b/sci-chemistry/pymol/pymol-9999.ebuild |
49 |
@@ -7,7 +7,7 @@ EAPI=5 |
50 |
PYTHON_COMPAT=( python2_7 ) |
51 |
PYTHON_REQ_USE="tk" |
52 |
|
53 |
-inherit distutils-r1 fdo-mime prefix subversion versionator |
54 |
+inherit distutils-r1 fdo-mime subversion versionator |
55 |
|
56 |
DESCRIPTION="A Python-extensible molecular graphics system" |
57 |
HOMEPAGE="http://pymol.sourceforge.net/" |
58 |
@@ -17,10 +17,10 @@ ESVN_REPO_URI="https://pymol.svn.sourceforge.net/svnroot/pymol/trunk/pymol" |
59 |
LICENSE="PSF-2.2" |
60 |
SLOT="0" |
61 |
KEYWORDS="~amd64 ~ppc ~x86 ~amd64-linux ~x86-linux ~x64-macos ~x86-macos" |
62 |
-IUSE="apbs" |
63 |
+IUSE="apbs web" |
64 |
|
65 |
DEPEND=" |
66 |
- dev-python/numpy |
67 |
+ dev-python/numpy[${PYTHON_USEDEP}] |
68 |
dev-python/pmw[${PYTHON_USEDEP}] |
69 |
media-libs/freetype:2 |
70 |
media-libs/glew |
71 |
@@ -34,7 +34,7 @@ DEPEND=" |
72 |
sci-chemistry/pdb2pqr |
73 |
sci-chemistry/pymol-apbs-plugin |
74 |
) |
75 |
- !dev-python/webpy" |
76 |
+ web? ( !dev-python/webpy )" |
77 |
RDEPEND="${DEPEND}" |
78 |
|
79 |
src_unpack() { |
80 |
@@ -50,9 +50,12 @@ python_prepare_all() { |
81 |
|
82 |
rm ./modules/pmg_tk/startup/apbs_tools.py || die |
83 |
|
84 |
- distutils-r1_python_prepare_all |
85 |
+ sed \ |
86 |
+ -e "s:/opt/local:${EPREFIX}/usr:g" \ |
87 |
+ -e '/ext_comp_args/s:\[.*\]:[]:g' \ |
88 |
+ -i setup.py || die |
89 |
|
90 |
- eprefixify setup.py |
91 |
+ distutils-r1_python_prepare_all |
92 |
} |
93 |
|
94 |
src_prepare() { |
95 |
@@ -67,8 +70,26 @@ python_install() { |
96 |
python_install_all() { |
97 |
distutils-r1_python_install_all |
98 |
|
99 |
+ python_export python2_7 EPYTHON |
100 |
+ |
101 |
+ # These environment variables should not go in the wrapper script, or else |
102 |
+ # it will be impossible to use the PyMOL libraries from Python. |
103 |
+ cat >> "${T}"/20pymol <<- EOF |
104 |
+ PYMOL_PATH="$(python_get_sitedir)/${PN}" |
105 |
+ PYMOL_DATA="${EPREFIX}/usr/share/pymol/data" |
106 |
+ PYMOL_SCRIPTS="${EPREFIX}/usr/share/pymol/scripts" |
107 |
+ EOF |
108 |
+ |
109 |
+ doenvd "${T}"/20pymol |
110 |
+ |
111 |
doicon "${WORKDIR}"/${PN}.{xpm,png} |
112 |
make_desktop_entry pymol PyMol ${PN} "Graphics;Education;Science;Chemistry" "MimeType=chemical/x-pdb;" |
113 |
+ |
114 |
+ if ! use web; then |
115 |
+ rm -rvf "${D}/$(python_get_sitedir)/web" || die |
116 |
+ fi |
117 |
+ |
118 |
+ rm -f "${ED}"/usr/share/${PN}/LICENSE || die |
119 |
} |
120 |
|
121 |
pkg_postinst() { |