summaryrefslogtreecommitdiffstats
path: root/Lib/site.py
diff options
context:
space:
mode:
authorGuido van Rossum <guido@python.org>2001-03-02 06:43:49 (GMT)
committerGuido van Rossum <guido@python.org>2001-03-02 06:43:49 (GMT)
commitd74fb6b12a9a53ce09648484076c84e727561612 (patch)
tree1dc433fdc367d5e2e26eef57606c95df8c2c089b /Lib/site.py
parent4ba3d657efc124a79b24cc9d8160191384d341de (diff)
downloadcpython-d74fb6b12a9a53ce09648484076c84e727561612.zip
cpython-d74fb6b12a9a53ce09648484076c84e727561612.tar.gz
cpython-d74fb6b12a9a53ce09648484076c84e727561612.tar.bz2
RISCOS changes by dschwertberger.
Diffstat (limited to 'Lib/site.py')
-rw-r--r--Lib/site.py8
1 files changed, 7 insertions, 1 deletions
diff --git a/Lib/site.py b/Lib/site.py
index 12fe71d..807ebc7 100644
--- a/Lib/site.py
+++ b/Lib/site.py
@@ -59,6 +59,12 @@ ImportError exception, it is silently ignored.
import sys, os
+if os.sep==".":
+ endsep = "/"
+else:
+ endsep = "."
+
+
def makepath(*paths):
dir = os.path.join(*paths)
return os.path.normcase(os.path.abspath(dir))
@@ -99,7 +105,7 @@ def addsitedir(sitedir):
names = map(os.path.normcase, names)
names.sort()
for name in names:
- if name[-4:] == ".pth":
+ if name[-4:] == endsep + "pth":
addpackage(sitedir, name)
def addpackage(sitedir, name):