[112194] trunk/dports/python/py-spyder
eborisch at macports.org
eborisch at macports.org
Mon Oct 14 19:12:43 PDT 2013
Revision: 112194
https://trac.macports.org/changeset/112194
Author: eborisch at macports.org
Date: 2013-10-14 19:12:43 -0700 (Mon, 14 Oct 2013)
Log Message:
-----------
py-spyder: Fix for buildbot missing USER environment variable. Fix for crash when LANG=UTF-8.
Modified Paths:
--------------
trunk/dports/python/py-spyder/Portfile
trunk/dports/python/py-spyder/files/spyderlib_utils_programs.py.diff
Added Paths:
-----------
trunk/dports/python/py-spyder/files/spyderlib_start_app.py.diff
Modified: trunk/dports/python/py-spyder/Portfile
===================================================================
--- trunk/dports/python/py-spyder/Portfile 2013-10-15 01:47:33 UTC (rev 112193)
+++ trunk/dports/python/py-spyder/Portfile 2013-10-15 02:12:43 UTC (rev 112194)
@@ -4,7 +4,7 @@
PortSystem 1.0
name py-spyder
version 2.2.5
-revision 0
+revision 1
epoch 20111202
PortGroup python 1.0
@@ -43,6 +43,7 @@
checksums \
rmd160 6422c9c18a81f5bc67c6e5f21f32e744ab6c1179 \
sha256 e2ae6155d6f84a9bdee7b3a6eca4b72f3f5e6d775ad23e8d0e82e125342eacaf
+
conflicts py${python.version}-spyder-devel
# Set the pylint executable name
@@ -52,6 +53,7 @@
spyderlib_baseconfig.py.diff \
spyderlib_plugins_editor.py.diff \
spyderlib_spyder.py.diff \
+ spyderlib_start_app.py.diff \
spyderlib_utils_programs.py.diff
post-patch {
@@ -76,17 +78,21 @@
# Bare minimum
depends_lib-append \
- port:py${python.version}-pyqt4 \
- port:py${python.version}-sphinx
+ port:py${python.version}-pyqt4
variant tiny description {
Remove all optional dependencies for quickest install. Dependencies\
- are detected/enabled at runtime and may be installed separately.
+ are detected/enabled at runtime and may be installed separately.\
+ Using these variants only affects MacPorts' dependency tracking (which\
+ will, in turn, force installation if needed.)
} conflicts small {}
variant small description {
Remove most optional dependencies for quicker install. Dependencies\
- are detected/enabled at runtime and may be installed separately.
+ are detected/enabled at runtime and may be installed separately.\
+ Using these variants only affects MacPorts' dependency tracking (which\
+ will, in turn, force installations if needed.)
+
} conflicts tiny {}
# These add very little to the install time
@@ -96,7 +102,9 @@
port:py${python.version}-pylint \
port:py${python.version}-pep8 \
port:py${python.version}-pyflakes \
- port:py${python.version}-rope
+ port:py${python.version}-rope \
+ port:py${python.version}-sphinx \
+ port:py${python.version}-sympy
}
# These add substantially to the install time
@@ -108,7 +116,7 @@
port:py${python.version}-zmq \
port:py${python.version}-matplotlib \
port:py${python.version}-scipy
- }
+ }
variant pil description {
Support image objects in editor through PIL (many dependencies.)
Added: trunk/dports/python/py-spyder/files/spyderlib_start_app.py.diff
===================================================================
--- trunk/dports/python/py-spyder/files/spyderlib_start_app.py.diff (rev 0)
+++ trunk/dports/python/py-spyder/files/spyderlib_start_app.py.diff 2013-10-15 02:12:43 UTC (rev 112194)
@@ -0,0 +1,19 @@
+--- spyderlib/start_app.py-orig 2013-10-14 12:43:43.000000000 -0500
++++ spyderlib/start_app.py 2013-10-14 12:45:50.000000000 -0500
+@@ -1,12 +1,16 @@
+ # -*- coding: utf-8 -*-
+
+ import os.path as osp
++import os
+ import socket
+ import time
+ import atexit
+ import random
+ import sys
+
++if os.environ['LANG'] == 'UTF-8':
++ os.environ['LANG'] = 'en_US.UTF-8'
++
+ # Local imports
+ from spyderlib.cli_options import get_options
+ from spyderlib.baseconfig import get_conf_path
Modified: trunk/dports/python/py-spyder/files/spyderlib_utils_programs.py.diff
===================================================================
--- trunk/dports/python/py-spyder/files/spyderlib_utils_programs.py.diff 2013-10-15 01:47:33 UTC (rev 112193)
+++ trunk/dports/python/py-spyder/files/spyderlib_utils_programs.py.diff 2013-10-15 02:12:43 UTC (rev 112194)
@@ -1,13 +1,25 @@
---- spyderlib/utils/programs.py.orig 2011-10-12 11:06:09.000000000 -0500
-+++ spyderlib/utils/programs.py 2011-10-12 11:07:28.000000000 -0500
-@@ -20,6 +20,10 @@
+--- spyderlib/utils/programs.py.orig 2013-10-14 10:55:09.000000000 -0500
++++ spyderlib/utils/programs.py 2013-10-14 10:55:23.000000000 -0500
+@@ -24,7 +24,11 @@
+ if os.name == 'nt':
+ TEMPDIR = tempfile.gettempdir() + osp.sep + 'spyder'
+ else:
+- username = encoding.to_unicode_from_fs(os.environ.get('USER'))
++ # Modified to support MacPorts' buildbot environment
++ username = os.environ.get('USER')
++ if not username:
++ username = 'ANON'
++ username = encoding.to_unicode_from_fs(username)
+ TEMPDIR = tempfile.gettempdir() + osp.sep + 'spyder-' + username
+
+
+@@ -33,6 +37,9 @@
+ Otherwise, return None"""
+ for path in os.environ["PATH"].split(os.pathsep):
abspath = osp.join(path, basename)
++ if not osp.isfile(abspath):
++ abspath = "/Applications/MacPorts/Qt4/" + basename + \
++ ".app/Contents/MacOS/" + basename
if osp.isfile(abspath):
return abspath
-+ else:
-+ abspath = "@@APPS_DIR@@/Qt4/" + basename + ".app/Contents/MacOS/" + basename
-+ if osp.isfile(abspath):
-+ return abspath
-
- def find_program(basename):
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/macports-changes/attachments/20131014/8c952671/attachment.html>
More information about the macports-changes
mailing list