Title: make install tries to install files outside of --prefix
Type: behavior Stage:
Components: Installation Versions: Python 2.6
Status: closed Resolution: not a bug
Dependencies: Superseder:
Assigned To: Nosy List: jjlee, pitrou
Priority: critical Keywords:

Created on 2008-09-13 11:17 by jjlee, last changed 2008-09-14 00:34 by pitrou. This issue is now closed.

Messages (3)
msg73175 - (view) Author: John J Lee (jjlee) Date: 2008-09-13 11:17
./configure --prefix=DIR && make && make install tries to install files
in directories outside of DIR.  This happens both with trunk (r66412)
and 2.6b3.  This is a problem for users of GNU stow, for example.  I
know that certainly this worked fairly recently on the py3k branch, for
example, and I believe it also used to work on trunk.

I'm not certain whether in this particular run the --prefix directory
existed or not prior to make install, but I certainly get essentially
the same failure regardless of whether that directory exists.

~/src/Python-2.6b3$ ./configure  --prefix=/home/john/stow/python26b3
~/src/Python-2.6b3$ make
~/src/Python-2.6b3$ make install
/usr/bin/install -c python-config
rm python-config
./python -E ./ install \
	   	--prefix=/home/john/stow/python26b3 \
		--install-scripts=/home/john/stow/python26b3/bin \
		--install-platlib=/home/john/stow/python26b3/lib/python2.6/lib-dynload \
running install
running build
running build_ext
INFO: Can't locate Tcl/Tk libs and/or headers

Failed to find the necessary bits to build these modules:
_bsddb             _tkinter           bsddb185        
dbm                gdbm               sunaudiodev     
To find the necessary bits, look in in detect_modules() for the
module's name.

running build_scripts
running install_lib
copying build/lib.linux-i686-2.6/ ->
error: could not delete
'/home/john/lib/python2.6/site-packages/': Permission denied
make: *** [sharedinstall] Error 1
msg73200 - (view) Author: John J Lee (jjlee) Date: 2008-09-13 22:15
OK, this was because I had a .pydistutils.cfg file containing the
following (ironically, put there following somebody's recipe for
installing setuptools packages using stow):


Removing that file, make install no longer tries to install files
outside of the directory passed to --prefix

So this bug is not valid, and I don't think there's any regression.

There's probably another bug about making it awkward to invent a
consistent way of installing Python software using tools like stow, but
I'm not sure whether that bug lies with Python or with setuptools, or both.
msg73202 - (view) Author: Antoine Pitrou (pitrou) * (Python committer) Date: 2008-09-14 00:34
OK, thanks for the report anyway :)
Date User Action Args
2008-09-14 00:34:43pitrousetstatus: open -> closed
resolution: not a bug
messages: + msg73202
nosy: + pitrou
2008-09-13 22:15:31jjleesetmessages: + msg73200
2008-09-13 11:33:36pitrousetpriority: critical
type: behavior
components: + Installation
versions: + Python 2.6
2008-09-13 11:17:16jjleecreate