summaryrefslogtreecommitdiff
path: root/numpy/distutils/command/scons.py
diff options
context:
space:
mode:
authorDavid Cournapeau <cournape@gmail.com>2009-09-09 00:44:39 +0000
committerDavid Cournapeau <cournape@gmail.com>2009-09-09 00:44:39 +0000
commita3c5de2585b44b8b697161dfad2859dd2ffbb536 (patch)
treef07351a4df7a92b01a87e4619ae7b9d9a9b60f31 /numpy/distutils/command/scons.py
parentcc9799e0981534cbb40ac6075bcefd90bdefdb87 (diff)
downloadnumpy-a3c5de2585b44b8b697161dfad2859dd2ffbb536.tar.gz
Handle None in protect path.
Diffstat (limited to 'numpy/distutils/command/scons.py')
-rw-r--r--numpy/distutils/command/scons.py9
1 files changed, 6 insertions, 3 deletions
diff --git a/numpy/distutils/command/scons.py b/numpy/distutils/command/scons.py
index b887d598c..fcc4223a4 100644
--- a/numpy/distutils/command/scons.py
+++ b/numpy/distutils/command/scons.py
@@ -228,9 +228,12 @@ def get_cxx_tool_path(compiler):
def protect_path(path):
"""Convert path (given as a string) to something the shell will have no
problem to understand (space, etc... problems)."""
- # XXX: to this correctly, this is totally bogus for now (does not check for
- # already quoted path, for example).
- return '"' + path + '"'
+ if path:
+ # XXX: to this correctly, this is totally bogus for now (does not check for
+ # already quoted path, for example).
+ return '"' + path + '"'
+ else:
+ return '""'
def parse_package_list(pkglist):
return pkglist.split(",")