This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

classification
Title: builds fail when installing to --prefix with space in path name
Type: Stage: resolved
Components: Build Versions: Python 3.2, Python 3.3, Python 2.7
process
Status: closed Resolution: wont fix
Dependencies: Superseder:
Assigned To: Nosy List: eric.araujo, iritkatriel, ned.deily, rzn8tr
Priority: low Keywords:

Created on 2011-09-10 15:55 by rzn8tr, last changed 2022-04-11 14:57 by admin. This issue is now closed.

Messages (5)
msg143871 - (view) Author: Ned Deily (ned.deily) * (Python committer) Date: 2011-09-11 16:08
gcc -o Python.framework/Versions/2.7/Python   -dynamiclib \
		-all_load libpython2.7.a -Wl,-single_module \
		-install_name /tmp/a/empty space/Python.framework/Versions/2.7/Python \
		-compatibility_version 2.7 \
		-current_version 2.7;
i686-apple-darwin11-llvm-gcc-4.2: space/Python.framework/Versions/2.7/Python: No such file or directory
msg144005 - (view) Author: Ned Deily (ned.deily) * (Python committer) Date: 2011-09-14 02:24
It turns out that supporting a framework path name that contains spaces (or other special characters) is a much more pervasive change that I had originally expected.  That's because the path specified by ./configure --enable-framework= also becomes the default for --prefix which is referenced directly (and indirectly via derived variables) throughout Makefile.pre.in and currently the Makefile does not handle installing a standard Unix-style build on any platform to prefix path that includes spaces, much less a Mac framework build.  That is the following will fail during the install phases:

    ./configure --prefix="/path/with space"
    make && make install

This needs to be addressed first, primarily by quote-protecting all uses of prefix and its derivatives in Makefile shell rules and then the uses of PYTHONFRAMEWORK* variables in the Makefile also need to be protected.  It should be fairly straightforward to find all such uses but there are many of them and changes would affect all platforms that use the Makefile to build and the many variants for each platform (i.e. --enable-shared, --enable-framework, etc) so proper testing would be a major effort.

While I'm sympathetic to supporting arbitrary path names, I'm not sure if it is worth the effort.  I'm going to leave this open for now but I don't plan to work on it myself in the near future.
msg144196 - (view) Author: Éric Araujo (eric.araujo) * (Python committer) Date: 2011-09-17 15:35
> While I'm sympathetic to supporting arbitrary path names, I'm not sure
> if it is worth the effort.

My sentiment too.  Supporting non-ASCII characters seems clearly important to me, as it’s a reasonable and common thing to run or install Python from a patch that may contain non-ASCII characters (a first name, “downloads” in French, etc.); supporting spaces is less important.
msg144214 - (view) Author: LMO (rzn8tr) Date: 2011-09-17 18:23
I don't see supporting spaces as being important, either.  Since the failure is not obviously related to the presence of spaces, I would like to see the limitation documented.

> 
> Éric Araujo <merwok@netwok.org> added the comment:
> 
>> While I'm sympathetic to supporting arbitrary path names, I'm not sure
>> if it is worth the effort.
> 
> My sentiment too.  Supporting non-ASCII characters seems clearly important to me, as it’s a reasonable and common thing to run or install Python from a patch that may contain non-ASCII characters (a first name, “downloads” in French, etc.); supporting spaces is less important.
> 
> ----------
> nosy: +eric.araujo
> 
> _______________________________________
> Python tracker <report@bugs.python.org>
> <http://bugs.python.org/issue12956>
> _______________________________________
msg381134 - (view) Author: Irit Katriel (iritkatriel) * (Python committer) Date: 2020-11-16 17:45
LMO, if you are still interested in this issue, could you be more specific about where you think this should be documented? If you want to create a patch, go for it.
History
Date User Action Args
2022-04-11 14:57:21adminsetgithub: 57165
2021-03-09 18:10:28iritkatrielsetstatus: pending -> closed
resolution: wont fix
stage: needs patch -> resolved
2020-11-16 17:45:21iritkatrielsetstatus: open -> pending
nosy: + iritkatriel
messages: + msg381134

2011-09-17 18:23:08rzn8trsetmessages: + msg144214
2011-09-17 15:35:16eric.araujosetnosy: + eric.araujo
messages: + msg144196
2011-09-14 02:24:55ned.deilysetpriority: normal -> low
title: 2.7.2 build fails with --enable-framework and space in pathname on OS X 10.7.1 -> builds fail when installing to --prefix with space in path name
messages: + msg144005

assignee: ned.deily ->
components: - macOS
2011-09-11 16:08:36ned.deilysetassignee: ned.deily
components: + macOS
versions: + Python 3.2, Python 3.3
nosy: + ned.deily

messages: + msg143871
stage: needs patch
2011-09-10 15:55:14rzn8trcreate