Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #88047 > unrolled thread

sys.exec_prefix doesn't seem to reflect --exec-prefix path

Started byRalph Heinkel <ralph.heinkel@web.de>
First post2015-03-26 05:37 -0700
Last post2015-03-26 14:54 -0700
Articles 2 — 2 participants

Back to article view | Back to comp.lang.python


Contents

  sys.exec_prefix doesn't seem to reflect --exec-prefix path Ralph Heinkel <ralph.heinkel@web.de> - 2015-03-26 05:37 -0700
    Re: sys.exec_prefix doesn't seem to reflect --exec-prefix path Ned Deily <nad@acm.org> - 2015-03-26 14:54 -0700

#88047 — sys.exec_prefix doesn't seem to reflect --exec-prefix path

FromRalph Heinkel <ralph.heinkel@web.de>
Date2015-03-26 05:37 -0700
Subjectsys.exec_prefix doesn't seem to reflect --exec-prefix path
Message-ID<548dcac1-fa00-4fc1-81d1-ccae28cafcbc@googlegroups.com>
Hi,

on my linux box there is a python version 2.7.5 installed in /usr/local.

Now I want to install the newer version 2.7.9, but in a different directory to avoid clashes with the current installation.

What I did was:

./configure --prefix /usr/local/Python-2.7.9 --exec-prefix /usr/local/Python-2.7.9
make
make install

Everything looks fine, Python is installed in the proper directory.

BUT: When I run /usr/local/Python-2.7.9/bin/python and do 'print sys.exec_prefix' it prints '/usr/local' instead of '/usr/local/Python-2.7.9'.

This has the effect that the old libraries of version 2.7.5 are used instead of the 2.7.9 ones.

The docs in https://docs.python.org/2/library/sys.html state that sys.exec_prefix will reflect the value given to option --exec-prefix at configuration time. Any idea what I did wrong? 

Thanks for your help,

Ralph

[toc] | [next] | [standalone]


#88098

FromNed Deily <nad@acm.org>
Date2015-03-26 14:54 -0700
Message-ID<mailman.218.1427406955.10327.python-list@python.org>
In reply to#88047
In article <548dcac1-fa00-4fc1-81d1-ccae28cafcbc@googlegroups.com>,
 Ralph Heinkel <ralph.heinkel@web.de> wrote:
> on my linux box there is a python version 2.7.5 installed in /usr/local.
> 
> Now I want to install the newer version 2.7.9, but in a different directory 
> to avoid clashes with the current installation.
> 
> What I did was:
> 
> ./configure --prefix /usr/local/Python-2.7.9 --exec-prefix 
> /usr/local/Python-2.7.9
> make
> make install

Configure arguments need to be specified with '='.  Try instead:

./configure --prefix=/usr/local/Python-2.7.9

And --exec-prefix isn't needed in this case as it defaults to the value 
of --prefix.

-- 
 Ned Deily,
 nad@acm.org

[toc] | [prev] | [standalone]


Back to top | Article view | comp.lang.python


csiph-web