[issue11171] Python 2.7.1 does not start when "./configure" is used with "--prefix" != "--exec-prefix"
Berthold Höllmann
report at bugs.python.org
Thu Feb 10 14:47:46 CET 2011
New submission from Berthold Höllmann <hoel at users.sourceforge.net>:
I do get (with 2.7.1):
> python
Traceback (most recent call last):
File "/usr/local/gltools/python/Python-2.7/lib/python2.7/site.py", line 553, in <module>
main()
File "/usr/local/gltools/python/Python-2.7/lib/python2.7/site.py", line 535, in main
known_paths = addusersitepackages(known_paths)
File "/usr/local/gltools/python/Python-2.7/lib/python2.7/site.py", line 268, in addusersitepackages
user_site = getusersitepackages()
File "/usr/local/gltools/python/Python-2.7/lib/python2.7/site.py", line 243, in getusersitepackages
user_base = getuserbase() # this will also set USER_BASE
File "/usr/local/gltools/python/Python-2.7/lib/python2.7/site.py", line 233, in getuserbase
USER_BASE = get_config_var('userbase')
File "/usr/local/gltools/python/Python-2.7/lib/python2.7/sysconfig.py", line 535, in get_config_var
return get_config_vars().get(name)
File "/usr/local/gltools/python/Python-2.7/lib/python2.7/sysconfig.py", line 434, in get_config_vars
_init_posix(_CONFIG_VARS)
File "/usr/local/gltools/python/Python-2.7/lib/python2.7/sysconfig.py", line 287, in _init_posix
raise IOError(msg)
IOError: invalid Python installation: unable to open /usr/local/gltools/python/Python-2.7/lib/python2.7/config/Makefile (No such file or directory)
The Makefile is platform dependendent und is located at
/usr/local/gltools/python/Python-2.7/linux_x86_64/lib/python2.7/config/Makefile
This problem is fixed for me by a simple pach:
> diff -c /usr/local/gltools/python/Python-2.7/lib/python2.7/sysconfig.py /usr/local/gltools/python/Python-2.7/lib/python2.7/sysconfig.py~
*** /usr/local/gltools/python/Python-2.7/lib/python2.7/sysconfig.py 2011-02-10 14:33:34.000015000 +0100
--- /usr/local/gltools/python/Python-2.7/lib/python2.7/sysconfig.py~ 2011-02-10 14:28:17.001245000 +0100
***************
*** 271,277 ****
def _get_makefile_filename():
if _PYTHON_BUILD:
return os.path.join(_PROJECT_BASE, "Makefile")
! return os.path.join(get_path('platstdlib'), "config", "Makefile")
def _init_posix(vars):
--- 271,277 ----
def _get_makefile_filename():
if _PYTHON_BUILD:
return os.path.join(_PROJECT_BASE, "Makefile")
! return os.path.join(get_path('stdlib'), "config", "Makefile")
def _init_posix(vars):
----------
components: Installation
messages: 128292
nosy: hoel
priority: normal
severity: normal
status: open
title: Python 2.7.1 does not start when "./configure" is used with "--prefix" != "--exec-prefix"
type: behavior
versions: Python 2.7
_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue11171>
_______________________________________
More information about the Python-bugs-list
mailing list