[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: configure find wrong python path
From: |
Matthias Kilian |
Subject: |
Re: configure find wrong python path |
Date: |
Sun, 25 Jun 2006 20:57:19 +0200 |
User-agent: |
Mutt/1.4.2i |
On Wed, May 24, 2006 at 11:51:01PM +0200, Karl Hammar wrote:
> Given:
> $ ls -l /usr/bin/python*
> lrwxrwxrwx 1 root root 9 May 24 15:51 /usr/bin/python -> python2.3
> -rwxr-xr-x 1 root root 958764 Mar 6 11:32 /usr/bin/python2.3
> -rwxr-xr-x 1 root root 1024460 Apr 23 01:34 /usr/bin/python2.4
Similar setup here on OpenBSD:
$ ls -l /usr/local/bin/python*
lrwxr-xr-x 1 root wheel 9 Jun 4 23:02 /usr/local/bin/python -> python2.3
-r-xr-xr-x 1 root bin 20028 Jun 4 23:00 /usr/local/bin/python2.3
-r-xr-xr-x 1 root bin 20028 Jun 4 18:07 /usr/local/bin/python2.4
> configure will report wrong path of python:
>
> $ ./configure
> ...
> checking for bash... /bin/sh
> checking for python... python
> checking python version... 2.3.5
> checking for python... /usr/bin/python
> checking for gcc... gcc
> ...
> checking New Century Schoolbook PFB files... /usr/share/fonts/type...
> checking for python... /usr/bin/python
> checking /usr/bin/python version... 2.3.5
[...]
> Attached patch corrects the error above.
Unfortunately, configure completely bails out then using something like
$ PYTHON=/usr/local/bin/python2.4 ./configure ...
The problem is in STEPMAKE_GETVERSION, since it takes the first
line that looks like it contains a version number of the output
from [Path stripped to take the line shorter]:
$ python2.4 --version 2>&1 || python2.4 -V 2>&1
which is
Unknown option: --
usage: python2.4 [option] ... [-c cmd | -m mod | file | -] [arg] ...
Try `python -h' for more information.
Python 2.4.3
The net result is that, for whatever reason, configure first detects
2.4.3, but later 2.3.5.
I think the attached patch fixes this. (Works at least when configuring
on OpenBSD).
Note that the patch contains another quick hack to let the version
check work on OpenBSD and other systems where the shell has 32 bit
integer arithmetic (without it, you'll get too large version numbers
for fontforge, letting configure think that 20060413 is smaller
than the requested version).
Ciao,
Kili
ps: do we really still have to use backticks instead of $(...)?
Anyone running LilyPond on old systems with rotten shells?
pps: I *only* tested the configure step yet. No idea wether it will
actually build and run.
ppps: Matt J., I assume you're subscribed to this list, so I don'y cc: ;-)
--
Windows is so bootyful...
patch-stepmake_aclocal_m4
Description: Text document
- Re: configure find wrong python path,
Matthias Kilian <=