Home | History | Annotate | Download | only in distutils

Lines Matching refs:pathname

110 def convert_path (pathname):
111 """Return 'pathname' as a name that will work on the native filesystem,
116 ValueError on non-Unix-ish systems if 'pathname' either starts or
120 return pathname
121 if not pathname:
122 return pathname
123 if pathname[0] == '/':
124 raise ValueError, "path '%s' cannot be absolute" % pathname
125 if pathname[-1] == '/':
126 raise ValueError, "path '%s' cannot end with '/'" % pathname
128 paths = string.split(pathname, '/')
145 def change_root (new_root, pathname):
146 """Return 'pathname' with 'new_root' prepended. If 'pathname' is
147 relative, this is equivalent to "os.path.join(new_root,pathname)".
148 Otherwise, it requires making 'pathname' relative and then joining the
152 if not os.path.isabs(pathname):
153 return os.path.join(new_root, pathname)
155 return os.path.join(new_root, pathname[1:])
158 (drive, path) = os.path.splitdrive(pathname)
164 (drive, path) = os.path.splitdrive(pathname)