blob: 9543729456931f4d0639ad555cc3caabb89d55f4 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
|
# Copyright 1999-2006 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/sci-chemistry/pymol/pymol-0.99_rc6.ebuild,v 1.2 2006/03/16 03:41:54 ribosome Exp $
inherit distutils eutils multilib
MY_PV=${PV/_}
MY_S_P="${PN}-${MY_PV}"
MY_PV=${MY_PV/./_}
MY_P="${PN}-${MY_PV}"
DESCRIPTION="A Python-extensible molecular graphics system."
HOMEPAGE="http://pymol.sourceforge.net/"
SRC_URI="mirror://sourceforge/pymol/${MY_P}-src.tgz"
LICENSE="PSF-2.2"
IUSE=""
SLOT="0"
KEYWORDS="~amd64 ~ppc ~x86"
DEPEND="dev-lang/python
dev-python/pmw
dev-python/numeric
dev-lang/tk
media-libs/libpng
sys-libs/zlib
virtual/glut"
S="${WORKDIR}/${MY_S_P}"
src_unpack() {
unpack ${A}
cd ${S}
# Turn off splash screen. Please do make a project contribution
# if you are able though.
[[ -n "$WANT_NOSPLASH" ]] && epatch ${FILESDIR}/nosplash-gentoo.patch
# Respect CFLAGS
sed -i \
-e "s:\(ext_comp_args=\).*:\1[]:g" \
${S}/setup.py
}
src_install() {
python_version
distutils_src_install
cd ${S}
#The following three lines probably do not do their jobs and should be
#changed
PYTHONPATH="${D}/usr/$(get_libdir)/site-packages" ${python} setup2.py
# Make our own wrapper
cat >> ${T}/pymol << EOF
#!/bin/sh
PYMOL_PATH=/usr/lib/python${PYVER}/site-packages/pymol
PYMOL_DATA="/usr/share/pymol/data"
PYMOL_SCRIPTS="/usr/share/pymol/scripts"
export PYMOL_PATH PYMOL_DATA PYMOL_SCRIPTS
${python} \${PYMOL_PATH}/__init__.py \$*
EOF
exeinto /usr/bin
doexe ${T}/pymol
dodoc DEVELOPERS CHANGES
mv examples ${D}/usr/share/doc/${PF}/
dodir /usr/share/pymol
mv test ${D}/usr/share/pymol/
mv data ${D}/usr/share/pymol/
mv scripts ${D}/usr/share/pymol/
}
|