Installing Python in a path that contains a blank

K

Konrad Hinsen

I am trying to install Python from sources in my home directory on a
Mac cluster (running MacOS X 10.4.8). The path to my home directory
contains a blank, and since the installation procedure insists on
getting an absolute path for the prefix, I cannot avoid installing to
a path whose name contains a blank. Python does not seem to be
prepared for this, as it uses only the part before the blank,
resulting in numerous error messages.

Does anyone know a workaround?

Thanks,
Konrad.
 
S

Stargaming

Konrad said:
I am trying to install Python from sources in my home directory on a
Mac cluster (running MacOS X 10.4.8). The path to my home directory
contains a blank, and since the installation procedure insists on
getting an absolute path for the prefix, I cannot avoid installing to a
path whose name contains a blank. Python does not seem to be prepared
for this, as it uses only the part before the blank, resulting in
numerous error messages.

Does anyone know a workaround?

Thanks,
Konrad.

You could give /foo/bar\ baz/ham or "/foo/bar baz/ham" (either escaping
the blanks or wrapping the path in quotation marks) a try. I can't
verify it either, just guess from other terminals' behaviour.

HTH,
Stargaming
 
J

John Machin

I am trying to install Python from sources in my home directory on a Mac
cluster (running MacOS X 10.4.8). The path to my home directory contains
a blank, and since the installation procedure insists on getting an
absolute path for the prefix, I cannot avoid installing to a path whose
name contains a blank. Python does not seem to be prepared for this, as
it uses only the part before the blank, resulting in numerous error
messages.

Does anyone know a workaround?

On Windows, the workaround for pesky paths (i.e. containing blanks or
just inconveniently long) is the subst command:

command-prompt>subst X: "C:\Documents and Settings"

Thereafter X:\foo can be used wherever "C:\Documents and Settings\foo"
would otherwise be required.

Is there not a similar trick on MacOS X?

HTH,
John
 
K

Konrad Hinsen

You could give /foo/bar\ baz/ham or "/foo/bar baz/ham" (either
escaping
the blanks or wrapping the path in quotation marks) a try. I can't
verify it either, just guess from other terminals' behaviour.

I tried both already, but neither one works. If I use a backslash, it
doesn't end up in the Makefile, and if I use quotes, I get lots of
error messages that I don't really want to analyze.

Thanks for your reply anyway!

Konrad.
 
K

Konrad Hinsen

It's called a symlink:

ln -s /Users/gdonald /foo

Right, but since I have no write permissions anywhere except in my
home directory (whose path already has the blank), links won't help me.

Konrad.
 
N

Neil Cerutti

I tried both already, but neither one works. If I use a
backslash, it doesn't end up in the Makefile, and if I use
quotes, I get lots of error messages that I don't really want
to analyze.

Try adding *more* backslashes. Sometimes, it's the only way. ;)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,772
Messages
2,569,593
Members
45,111
Latest member
KetoBurn
Top