aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJustin Lecher <jlec@gentoo.org>2013-02-15 16:53:06 +0100
committerJustin Lecher <jlec@gentoo.org>2013-02-15 16:53:06 +0100
commit37524e665700b37970924243853f1bef9bb7c6ba (patch)
tree30f6210bc94a01181e6ad5085faeb362a07e5f27 /sci-chemistry/pymol
parentAdded changes suggested by Christoph Junghans <ottxor@gentoo.org>. (diff)
downloadsci-37524e665700b37970924243853f1bef9bb7c6ba.tar.gz
sci-37524e665700b37970924243853f1bef9bb7c6ba.tar.bz2
sci-37524e665700b37970924243853f1bef9bb7c6ba.zip
sci-chemistry/pymol: adopt to current HEAD
Package-Manager: portage-2.2.0_alpha163
Diffstat (limited to 'sci-chemistry/pymol')
-rw-r--r--sci-chemistry/pymol/ChangeLog7
-rw-r--r--sci-chemistry/pymol/files/pymol-9999-data-path.patch151
-rw-r--r--sci-chemistry/pymol/files/pymol-9999-flags.patch18
-rw-r--r--sci-chemistry/pymol/files/pymol-9999-nosplash.patch15
-rw-r--r--sci-chemistry/pymol/files/pymol-9999-prefix.patch52
-rw-r--r--sci-chemistry/pymol/files/pymol-9999-setup.py.patch39
-rw-r--r--sci-chemistry/pymol/files/pymol-9999-vmd.patch36
-rw-r--r--sci-chemistry/pymol/files/pymol-9999-web.patch16
-rw-r--r--sci-chemistry/pymol/metadata.xml2
-rw-r--r--sci-chemistry/pymol/pymol-9999.ebuild50
10 files changed, 40 insertions, 346 deletions
diff --git a/sci-chemistry/pymol/ChangeLog b/sci-chemistry/pymol/ChangeLog
index c88876abd..fe1b0b764 100644
--- a/sci-chemistry/pymol/ChangeLog
+++ b/sci-chemistry/pymol/ChangeLog
@@ -2,6 +2,13 @@
# Copyright 1999-2013 Gentoo Foundation; Distributed under the GPL v2
# $Header: $
+ 15 Feb 2013; Justin Lecher <jlec@gentoo.org> pymol-9999.ebuild,
+ -files/pymol-9999-data-path.patch, files/pymol-9999-flags.patch,
+ -files/pymol-9999-nosplash.patch, files/pymol-9999-prefix.patch,
+ -files/pymol-9999-setup.py.patch, -files/pymol-9999-vmd.patch,
+ -files/pymol-9999-web.patch, metadata.xml:
+ adopt to current HEAD
+
29 Jan 2013; Justin Lecher <jlec@gentoo.org> pymol-9999.ebuild, metadata.xml:
Bump python eclass
diff --git a/sci-chemistry/pymol/files/pymol-9999-data-path.patch b/sci-chemistry/pymol/files/pymol-9999-data-path.patch
deleted file mode 100644
index a2b09bb9e..000000000
--- a/sci-chemistry/pymol/files/pymol-9999-data-path.patch
+++ /dev/null
@@ -1,151 +0,0 @@
- layer0/ShaderMgr.c | 16 ++++++++--------
- layer1/Setting.c | 2 +-
- modules/chempy/__init__.py | 2 +-
- modules/chempy/tinker/__init__.py | 2 +-
- modules/pymol/commanding.py | 6 +++---
- modules/pymol/importing.py | 2 +-
- 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
---- a/layer0/ShaderMgr.c
-+++ b/layer0/ShaderMgr.c
-@@ -385,7 +385,7 @@ int CShaderMgr_ShadersPresent(CShaderMgr * I)
- char * CShaderMgr_ReadShaderFromDisk(PyMOLGlobals * G, const char * fileName) {
- FILE* f;
- long size;
-- char* buffer = NULL, *p, *pymol_path, *shader_path, *fullFile;
-+ char* buffer = NULL, *p, *pymol_data, *shader_path, *fullFile;
- size_t res;
-
- PRINTFB(G, FB_ShaderMgr, FB_Debugging)
-@@ -398,16 +398,16 @@ char * CShaderMgr_ReadShaderFromDisk(PyMOLGlobals * G, const char * fileName) {
- return NULL;
- }
-
-- pymol_path = getenv("PYMOL_PATH");
-- if (!pymol_path){
-+ pymol_data = getenv("PYMOL_DATA");
-+ if (!pymol_data){
- PRINTFB(G, FB_ShaderMgr, FB_Warnings)
-- " PyMOLShader_NewFromFile-Warning: PYMOL_PATH not set, cannot read shader config files from disk\n" ENDFB(G);
-+ " PyMOLShader_NewFromFile-Warning: PYMOL_DATA not set, cannot read shader config files from disk\n" ENDFB(G);
- return NULL;
- }
- /* make this a setting */
-- shader_path = "/data/shaders/";
-- fullFile = malloc( sizeof(char) * (strlen(pymol_path)+strlen(shader_path)+strlen(fileName)+1));
-- fullFile = strcpy(fullFile, pymol_path);
-+ shader_path = "/shaders/";
-+ fullFile = malloc( sizeof(char) * (strlen(pymol_data)+strlen(shader_path)+strlen(fileName)+1));
-+ fullFile = strcpy(fullFile, pymol_data);
- fullFile = strcat(fullFile, shader_path);
- fullFile = strcat(fullFile, fileName);
-
-@@ -416,7 +416,7 @@ char * CShaderMgr_ReadShaderFromDisk(PyMOLGlobals * G, const char * fileName) {
-
- if (!f) {
- PRINTFB(G, FB_ShaderMgr, FB_Errors)
-- " PyMOLShader_NewFromFile-Error: Unable to open file '%s' PYMOL_PATH='%s'\n", fullFile, pymol_path ENDFB(G);
-+ " PyMOLShader_NewFromFile-Error: Unable to open file '%s' PYMOL_DATA='%s'\n", fullFile, pymol_data ENDFB(G);
- return NULL;
- } else {
- PRINTFB(G, FB_ShaderMgr, FB_Blather)
-diff --git a/layer1/Setting.c b/layer1/Setting.c
-index c2b8bbb..4c6fdb7 100644
---- a/layer1/Setting.c
-+++ b/layer1/Setting.c
-@@ -4375,7 +4375,7 @@ void SettingInitGlobal(PyMOLGlobals * G, int alloc, int reset_gui, int use_defau
- set_b(I, cSetting_line_use_shader, 1);
- set_b(I, cSetting_sphere_use_shader, 1);
- set_b(I, cSetting_use_shaders, 0);
-- set_s(I, cSetting_shader_path, "data/shaders");
-+ set_s(I, cSetting_shader_path, "shaders");
- set_i(I, cSetting_volume_bit_depth, 8);
- set_color(I, cSetting_volume_color, "-1");
- set_f(I, cSetting_volume_layers, 256);
-diff --git a/modules/chempy/__init__.py b/modules/chempy/__init__.py
-index 23dbe45..795a223 100644
---- a/modules/chempy/__init__.py
-+++ b/modules/chempy/__init__.py
-@@ -235,7 +235,7 @@ if os.environ.has_key('CHEMPY_DATA'): #
- elif os.environ.has_key('PYMOL_DATA'):
- 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/'
- elif os.environ.has_key('FREEMOL_MODULES'):
- path = os.environ['FREEMOL_MODULES'] + '/chempy/'
- else:
-diff --git a/modules/chempy/tinker/__init__.py b/modules/chempy/tinker/__init__.py
-index a2d8eb1..1e48f81 100644
---- a/modules/chempy/tinker/__init__.py
-+++ b/modules/chempy/tinker/__init__.py
-@@ -147,7 +147,7 @@ else:
-
- if os.environ.has_key('PYMOL_PATH'):
- pymol_path = os.environ['PYMOL_PATH']
-- test_path = pymol_path + '/data/chempy/tinker/'
-+ test_path = pymol_path + '/chempy/tinker/'
- if os.path.exists(test_path):
- params_path = test_path
-
-diff --git a/modules/pymol/commanding.py b/modules/pymol/commanding.py
-index 5a202d0..5cb27a6 100644
---- a/modules/pymol/commanding.py
-+++ b/modules/pymol/commanding.py
-@@ -219,11 +219,11 @@ USAGE
- _self.unlock(0,_self)
- r = DEFAULT_SUCCESS
- if show_splash==1: # generic / open-source
-- png_path = _self.exp_path("$PYMOL_PATH/data/pymol/splash.png")
-+ png_path = _self.exp_path("$PYMOL_DATA/pymol/splash.png")
- elif show_splash==2: # evaluation builds
-- png_path = _self.exp_path("$PYMOL_PATH/data/pymol/epymol.png")
-+ png_path = _self.exp_path("$PYMOL_DATA/pymol/epymol.png")
- else: # incentive builds
-- png_path = _self.exp_path("$PYMOL_PATH/data/pymol/ipymol.png")
-+ png_path = _self.exp_path("$PYMOL_DATA/pymol/ipymol.png")
- if os.path.exists(png_path):
- _self.do("_ cmd.load_png('%s',0,quiet=1)"%png_path)
- else:
-diff --git a/modules/pymol/importing.py b/modules/pymol/importing.py
-index 457ace7..7cc2953 100644
---- a/modules/pymol/importing.py
-+++ b/modules/pymol/importing.py
-@@ -191,7 +191,7 @@ SEE ALSO
- '''
- r = DEFAULT_ERROR
-
-- tables = { 'cmyk' : "$PYMOL_PATH/data/pymol/cmyk.png",
-+ tables = { 'cmyk' : "$PYMOL_DATA/pymol/cmyk.png",
- 'pymol' : 'pymol',
- 'rgb' : 'rgb',
- 'greyscale': 'greyscale' }
-diff --git a/modules/pymol/wizard/mutagenesis.py b/modules/pymol/wizard/mutagenesis.py
-index 8a5250d..6c1b26c 100644
---- a/modules/pymol/wizard/mutagenesis.py
-+++ b/modules/pymol/wizard/mutagenesis.py
-@@ -52,8 +52,8 @@ class Mutagenesis(Wizard):
-
- self.dep = default_dep
-
-- 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
-@@ -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']+
-- "/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):
- cmd=self.cmd
diff --git a/sci-chemistry/pymol/files/pymol-9999-flags.patch b/sci-chemistry/pymol/files/pymol-9999-flags.patch
index 9bdba45f3..528e220b0 100644
--- a/sci-chemistry/pymol/files/pymol-9999-flags.patch
+++ b/sci-chemistry/pymol/files/pymol-9999-flags.patch
@@ -1,11 +1,11 @@
- setup.py | 5 +----
- 1 files changed, 1 insertions(+), 4 deletions(-)
+ pymol/setup.py | 5 +----
+ 1 file changed, 1 insertion(+), 4 deletions(-)
-diff --git a/setup.py b/setup.py
-index 2b6fa35..9c0556d 100755
---- a/setup.py
-+++ b/setup.py
-@@ -197,10 +197,7 @@ else: # linux or other unix
+diff --git a/pymol/setup.py b/pymol/setup.py
+index b8d7070..7fc11fb 100644
+--- a/pymol/setup.py
++++ b/pymol/setup.py
+@@ -252,10 +252,7 @@ else: # linux or other unix
("_PYMOL_GL_CALLLISTS",None),
("OPENGL_ES_2",None),
]
@@ -14,6 +14,6 @@ index 2b6fa35..9c0556d 100755
- "-O3",
- "-g" ]
+ ext_comp_args = []
- ext_link_args = []
-
+ def get_pymol_version():
+ return re.findall(r'_PyMOL_VERSION "(.*)"', open('layer0/Version.h').read())[0]
diff --git a/sci-chemistry/pymol/files/pymol-9999-nosplash.patch b/sci-chemistry/pymol/files/pymol-9999-nosplash.patch
deleted file mode 100644
index b296285e8..000000000
--- a/sci-chemistry/pymol/files/pymol-9999-nosplash.patch
+++ /dev/null
@@ -1,15 +0,0 @@
- modules/pymol/invocation.py | 2 --
- 1 files changed, 0 insertions(+), 2 deletions(-)
-
-diff --git a/modules/pymol/invocation.py b/modules/pymol/invocation.py
-index de47849..c5f4487 100644
---- a/modules/pymol/invocation.py
-+++ b/modules/pymol/invocation.py
-@@ -397,7 +397,5 @@ if __name__=='pymol.invocation':
- if loaded_something and (options.after_load_script!=""):
- options.deferred.append(options.after_load_script)
- options.deferred.extend(final_actions)
-- if options.show_splash and not options.no_gui and not restricted:
-- options.deferred.insert(0,"_do__ cmd.splash(1)")
- if options.full_screen:
- options.deferred.append("_do__ full_screen on")
diff --git a/sci-chemistry/pymol/files/pymol-9999-prefix.patch b/sci-chemistry/pymol/files/pymol-9999-prefix.patch
index 9b0bad342..0334845ca 100644
--- a/sci-chemistry/pymol/files/pymol-9999-prefix.patch
+++ b/sci-chemistry/pymol/files/pymol-9999-prefix.patch
@@ -1,33 +1,17 @@
-Index: setup.py
-===================================================================
---- setup.py (revision 3983)
-+++ setup.py (working copy)
-@@ -1,4 +1,4 @@
--#!/usr/bin/env python
-+#!@GENTOO_PORTAGE_EPREFIX@/usr/bin/env python
- #
- # This script only applies if you are performing a Python Distutils-based
- # installation of PyMOL.
-@@ -35,7 +35,7 @@
- "modules/cealign/src/tnt" ]
- libs=["glut32","opengl32","glu32","png"]
- pyogl_libs = ["glut32","opengl32","glu32"]
-- lib_dirs=["/usr/lib/w32api"]
-+ lib_dirs=["@GENTOO_PORTAGE_EPREFIX@/usr/lib/w32api"]
- def_macros=[("_PYMOL_MODULE",None),
- ("CYGWIN",None),
- ("_PYMOL_LIBPNG",None)]
-@@ -87,7 +87,7 @@
+ pymol/setup.py | 10 +++++-----
+ 1 file changed, 5 insertions(+), 5 deletions(-)
+
+diff --git a/pymol/setup.py b/pymol/setup.py
+index b8d7070..378bbf6 100644
+--- a/pymol/setup.py
++++ b/pymol/setup.py
+@@ -185,12 +185,12 @@ elif sys.platform=='darwin':
"/sw/include/freetype2/freetype",
"/sw/include/freetype2",
"/sw/include",
- "/usr/X11/include",
+ "@GENTOO_PORTAGE_EPREFIX@/usr/X11/include",
- "modules/cealign/src",
- "modules/cealign/src/tnt",
- #"contrib/uiuc/plugins/include/",
-@@ -114,8 +114,8 @@
- ext_comp_args=[]
+ ]
ext_link_args=[
"-L/sw/lib", "-lpng",
- "/usr/X11/lib/libGL.dylib",
@@ -37,21 +21,21 @@ Index: setup.py
"-lfreeglut",
"-lglew",
"-L/sw/lib/freetype219/lib", "-lfreetype"
-@@ -221,7 +221,7 @@
- "layer3",
- "layer4",
- "layer5",
+@@ -220,7 +220,7 @@ elif sys.platform=='darwin':
+ else: # linux or other unix
+
+ inc_dirs += [
- "/usr/include/freetype2",
+ "@GENTOO_PORTAGE_EPREFIX@/usr/include/freetype2",
- # VMD plugin support
- # "contrib/uiuc/plugins/include",
- # "contrib/uiuc/plugins/molfile_plugin/src",
-@@ -242,7 +242,7 @@
+ ]
+ libs = [ "GL",
+ "GLU",
+@@ -235,7 +235,7 @@ else: # linux or other unix
"GLU",
"glut",
"GLEW"]
- lib_dirs = [ "/usr/X11R6/lib64", ]
+ lib_dirs = [ "@GENTOO_PORTAGE_EPREFIX@/usr/X11R6/lib64", ]
- def_macros = [ ("_PYMOL_MODULE",None),
+ def_macros += [
("_PYMOL_INLINE",None),
("_PYMOL_FREETYPE",None),
diff --git a/sci-chemistry/pymol/files/pymol-9999-setup.py.patch b/sci-chemistry/pymol/files/pymol-9999-setup.py.patch
deleted file mode 100644
index 076d6907a..000000000
--- a/sci-chemistry/pymol/files/pymol-9999-setup.py.patch
+++ /dev/null
@@ -1,39 +0,0 @@
- setup.py | 28 ----------------------------
- 1 files changed, 0 insertions(+), 28 deletions(-)
-
-diff --git a/setup.py b/setup.py
-index 18866a2..705b0c5 100755
---- a/setup.py
-+++ b/setup.py
-@@ -487,31 +487,3 @@ distribution = setup ( # Distribution meta-data
- define_macros = def_macros
- )
- ])
--
--# make available for setup2.py
--try:
-- site_packages = distribution.command_obj['install'].install_libbase
--except KeyError:
-- print """
-- Error: Please run, 'setup.py install' not 'setup build' or other variant.
--
--"""
-- sys.exit(2)
--
--f = open('setup3.py', 'w')
--print >> f, 'site_packages =', repr(site_packages)
--f.close()
--
--print '''
-- After running:
--
-- python setup.py install
--
-- Please run, to complete the installation:
--
-- python setup2.py install
--
-- To uninstall PyMOL, run:
--
-- python setup2.py uninstall
--'''
diff --git a/sci-chemistry/pymol/files/pymol-9999-vmd.patch b/sci-chemistry/pymol/files/pymol-9999-vmd.patch
deleted file mode 100644
index cf47082ef..000000000
--- a/sci-chemistry/pymol/files/pymol-9999-vmd.patch
+++ /dev/null
@@ -1,36 +0,0 @@
- setup.py | 8 ++++----
- 1 files changed, 4 insertions(+), 4 deletions(-)
-
-diff --git a/setup.py b/setup.py
-index 366d552..ce0d271 100755
---- a/setup.py
-+++ b/setup.py
-@@ -161,8 +161,8 @@ else: # linux or other unix
- "layer5",
- "/usr/include/freetype2",
- # VMD plugin support
-- # "contrib/uiuc/plugins/include",
-- # "contrib/uiuc/plugins/molfile_plugin/src",
-+ "contrib/uiuc/plugins/include",
-+ "contrib/uiuc/plugins/molfile_plugin/src",
- "modules/cealign/src",
- "modules/cealign/src/tnt",
- "generated/include",
-@@ -190,7 +190,7 @@ else: # linux or other unix
- # Numeric Python support
- # ("_PYMOL_NUMPY",None),
- # VMD plugin support
-- # ("_PYMOL_VMD_PLUGINS",None)
-+ ("_PYMOL_VMD_PLUGINS",None),
- ("_PYMOL_CGO_DRAWARRAYS",None),
- ("_PYMOL_CGO_DRAWBUFFERS",None),
- ("_CGO_DRAWARRAYS",None),
-@@ -354,7 +354,7 @@ distribution = setup ( # Distribution meta-data
- "layer5/main.c"
- # VMD plugin support
- # switch the 0 to 1 to activate the additional source code
-- ] + 0 * [
-+ ] + 1 * [
- # (incomplete support -- only TRJ, TRR, XTC, DCD so far...)
- 'contrib/uiuc/plugins/molfile_plugin/src/PlugIOManagerInit.c',
- 'contrib/uiuc/plugins/molfile_plugin/src/avsplugin.cpp',
diff --git a/sci-chemistry/pymol/files/pymol-9999-web.patch b/sci-chemistry/pymol/files/pymol-9999-web.patch
deleted file mode 100644
index 2293670e1..000000000
--- a/sci-chemistry/pymol/files/pymol-9999-web.patch
+++ /dev/null
@@ -1,16 +0,0 @@
-Index: setup.py
-===================================================================
---- setup.py (revision 3983)
-+++ setup.py (working copy)
-@@ -292,10 +292,7 @@
- 'pymol/opengl/glu',
- 'pymol/opengl/glut',
- 'pymol/wizard',
- 'pymol/plugins',
-- 'pymol2',
-- 'web',
-- 'web/examples',
-- 'web/javascript', ],
-+ 'pymol2', ],
- ext_modules = [
- Extension("pymol._cmd", [
diff --git a/sci-chemistry/pymol/metadata.xml b/sci-chemistry/pymol/metadata.xml
index 8ada2f2fd..388b22d24 100644
--- a/sci-chemistry/pymol/metadata.xml
+++ b/sci-chemistry/pymol/metadata.xml
@@ -7,7 +7,5 @@
<use>
<flag name="apbs">Pymol supprt for sci-chemistry/apbs</flag>
<flag name="numpy">Enable numpy support for Pymol</flag>
- <flag name="vmd">Builds molfile plugin support</flag>
- <flag name="web">Install Pymodule needed for web app support</flag>
</use>
</pkgmetadata>
diff --git a/sci-chemistry/pymol/pymol-9999.ebuild b/sci-chemistry/pymol/pymol-9999.ebuild
index 00dc372c0..12bf73d1e 100644
--- a/sci-chemistry/pymol/pymol-9999.ebuild
+++ b/sci-chemistry/pymol/pymol-9999.ebuild
@@ -17,7 +17,7 @@ ESVN_REPO_URI="https://pymol.svn.sourceforge.net/svnroot/pymol/trunk/pymol"
LICENSE="PSF-2.2"
SLOT="0"
KEYWORDS="~amd64 ~ppc ~x86 ~amd64-linux ~x86-linux ~x64-macos ~x86-macos"
-IUSE="apbs numpy vmd web"
+IUSE="apbs +numpy"
DEPEND="
dev-python/numpy
@@ -34,7 +34,7 @@ DEPEND="
sci-chemistry/pdb2pqr
sci-chemistry/pymol-apbs-plugin
)
- web? ( !dev-python/webpy )"
+ !dev-python/webpy"
RDEPEND="${DEPEND}"
src_unpack() {
@@ -44,15 +44,10 @@ src_unpack() {
python_prepare_all() {
local PATCHES=(
- "${FILESDIR}"/${P}-setup.py.patch
- "${FILESDIR}"/${P}-data-path.patch
"${FILESDIR}"/${P}-flags.patch
"${FILESDIR}"/${P}-prefix.patch
)
- use web || PATCHES+=( "${FILESDIR}"/${P}-web.patch )
- use vmd && PATCHES+=( "${FILESDIR}"/${P}-vmd.patch )
-
if use numpy; then
sed \
-e '/PYMOL_NUMPY/s:^#::g' \
@@ -61,12 +56,8 @@ python_prepare_all() {
rm ./modules/pmg_tk/startup/apbs_tools.py || die
- python_export python2_7 EPYTHON PYTHON_SITEDIR
- echo "site_packages = \'$(python_get_sitedir)\'" > setup3.py || die
-
sed \
-e "s:/opt/local:${EPREFIX}/usr:g" \
- -e '/ext_comp_args/s:\[.*\]:[]:g' \
-i setup.py || die
distutils-r1_python_prepare_all
@@ -79,47 +70,18 @@ src_prepare() {
distutils-r1_src_prepare
}
+python_install() {
+ distutils-r1_python_install --pymol-path="${EPREFIX}/usr/share/pymol"
+}
+
python_install_all() {
distutils-r1_python_install_all
- python_export python2_7 EPYTHON
-
- # 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)/${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
- ${EPYTHON} -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,png}
make_desktop_entry pymol PyMol ${PN} "Graphics;Education;Science;Chemistry" "MimeType=chemical/x-pdb;"
}
pkg_postinst() {
- elog "\t USE=shaders was removed,"
- elog "please use pymol config settings (~/.pymolrc)"
- elog "\t set use_shaders, 1"
- elog "in case of crashes, please deactivate this experimental feature by setting"
- elog "\t set use_shaders, 0"
- elog "\t set sphere_mode, 0"
fdo-mime_desktop_database_update
fdo-mime_mime_database_update
}