You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@subversion.apache.org by Kumar McMillan <ku...@gmail.com> on 2005/10/24 20:54:04 UTC
problems compiling subversion python bindings
I have a working build of subversion (tests pass, etc) but I am having
problems compiling subversion bindings like:
$ make swig-py
However, it looks like my custom python build
(/usr/local/lib/python2.4, etc) is not getting detected correctly at
configuration time. What configure options am I missing??? Here are
some possibly related errors from configuration:
checking for compiling Python extensions... Traceback (most recent call last):
File "/home/kumar/build/subversion-1.2.3/build/get-py-info.py", line 38, in ?
cc, basecflags, opt, ccshared = \
File "/usr/lib/python2.2/distutils/sysconfig.py", line 417, in get_config_vars
func()
File "/usr/lib/python2.2/distutils/sysconfig.py", line 322, in _init_posix
raise DistutilsPlatformError(my_msg)
distutils.errors.DistutilsPlatformError: invalid Python installation:
unable to open /usr/lib/python2.2/config/Makefile (No such file or
directory)
checking for linking Python extensions... Traceback (most recent call last):
File "/home/kumar/build/subversion-1.2.3/build/get-py-info.py", line 74, in ?
print ldshared_process()
File "/home/kumar/build/subversion-1.2.3/build/get-py-info.py", line
46, in ldshared_process
ldshared = sysconfig.get_config_var('LDSHARED')
File "/usr/lib/python2.2/distutils/sysconfig.py", line 440, in get_config_var
return get_config_vars().get(name)
File "/usr/lib/python2.2/distutils/sysconfig.py", line 417, in get_config_vars
func()
File "/usr/lib/python2.2/distutils/sysconfig.py", line 322, in _init_posix
raise DistutilsPlatformError(my_msg)
distutils.errors.DistutilsPlatformError: invalid Python installation:
unable to open /usr/lib/python2.2/config/Makefile (No such file or
directory)
checking for linking Python libraries... Traceback (most recent call last):
File "/home/kumar/build/subversion-1.2.3/build/get-py-info.py", line 78, in ?
print ldshared_process(just_libs = 1)
File "/home/kumar/build/subversion-1.2.3/build/get-py-info.py", line
46, in ldshared_process
ldshared = sysconfig.get_config_var('LDSHARED')
File "/usr/lib/python2.2/distutils/sysconfig.py", line 440, in get_config_var
return get_config_vars().get(name)
File "/usr/lib/python2.2/distutils/sysconfig.py", line 417, in get_config_vars
func()
File "/usr/lib/python2.2/distutils/sysconfig.py", line 322, in _init_posix
raise DistutilsPlatformError(my_msg)
distutils.errors.DistutilsPlatformError: invalid Python installation:
unable to open /usr/lib/python2.2/config/Makefile (No such file or
directory)
------
and this was my configure string:
./configure --with-ssl --with-apr=../apr-0.9.7
--with-apr-util=../apr-util-0.9.7
--with-berkeley-db=/usr/local/BerkeleyDB.4.3 --with-neon=/usr/local
--prefix=/usr/local --with-swig=/usr/local
--with-python=/usr/local/bin/python
where ... $ /usr/local/bin/python -V
Python 2.4.2
configure --help doesn't offer any help here, unless I am missing
something painfully obvious.
Any ideas?
thanks, Kumar
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
Re: problems compiling subversion python bindings
Posted by Kumar McMillan <ku...@gmail.com>.
thanks David (posting back to the list for googling eyes). I waded
through configure-bash-madness and did find a reference to $PYTHON.
sure enough:
export PYTHON=/usr/local/bin/python
just before re-configuring made sure all the devel stuff linked
properly. This, with a little bit of hackery
[http://svn.haxx.se/users/archive-2005-10/0749.shtml], plus a run of
ldconfig got me some working python bindings! (Phew.) Now I can
install Trac :)
Kumar
On 10/25/05, David Ripton <dr...@ripton.net> wrote:
> On 2005.10.24 15:54:04 -0500, Kumar McMillan wrote:
> > I have a working build of subversion (tests pass, etc) but I am having
> > problems compiling subversion bindings like:
> >
> > $ make swig-py
> >
> > However, it looks like my custom python build
> > (/usr/local/lib/python2.4, etc) is not getting detected correctly at
> > configuration time. What configure options am I missing??? Here are
> > some possibly related errors from configuration:
> >
> >
> > checking for compiling Python extensions... Traceback (most recent call last):
> > distutils.errors.DistutilsPlatformError: invalid Python installation:
> > unable to open /usr/lib/python2.2/config/Makefile (No such file or
> > directory)
> >
> > checking for linking Python extensions... Traceback (most recent call last):
> > File "/home/kumar/build/subversion-1.2.3/build/get-py-info.py", line 74, in ?
> > print ldshared_process()
> > File "/home/kumar/build/subversion-1.2.3/build/get-py-info.py", line
> > 46, in ldshared_process
> > ldshared = sysconfig.get_config_var('LDSHARED')
> > File "/usr/lib/python2.2/distutils/sysconfig.py", line 440, in get_config_var
> > return get_config_vars().get(name)
> > File "/usr/lib/python2.2/distutils/sysconfig.py", line 417, in get_config_vars
> > func()
> > File "/usr/lib/python2.2/distutils/sysconfig.py", line 322, in _init_posix
> > raise DistutilsPlatformError(my_msg)
> > distutils.errors.DistutilsPlatformError: invalid Python installation:
> > unable to open /usr/lib/python2.2/config/Makefile (No such file or
> > directory)
> >
> > checking for linking Python libraries... Traceback (most recent call last):
> > File "/home/kumar/build/subversion-1.2.3/build/get-py-info.py", line 78, in ?
> > print ldshared_process(just_libs = 1)
> > File "/home/kumar/build/subversion-1.2.3/build/get-py-info.py", line
> > 46, in ldshared_process
> > ldshared = sysconfig.get_config_var('LDSHARED')
> > File "/usr/lib/python2.2/distutils/sysconfig.py", line 440, in get_config_var
> > return get_config_vars().get(name)
> > File "/usr/lib/python2.2/distutils/sysconfig.py", line 417, in get_config_vars
> > func()
> > File "/usr/lib/python2.2/distutils/sysconfig.py", line 322, in _init_posix
> > raise DistutilsPlatformError(my_msg)
> > distutils.errors.DistutilsPlatformError: invalid Python installation:
> > unable to open /usr/lib/python2.2/config/Makefile (No such file or
> > directory)
> >
> > ------
> > and this was my configure string:
> >
> > ./configure --with-ssl --with-apr=../apr-0.9.7
> > --with-apr-util=../apr-util-0.9.7
> > --with-berkeley-db=/usr/local/BerkeleyDB.4.3 --with-neon=/usr/local
> > --prefix=/usr/local --with-swig=/usr/local
> > --with-python=/usr/local/bin/python
> >
> > where ... $ /usr/local/bin/python -V
> > Python 2.4.2
> >
> > configure --help doesn't offer any help here, unless I am missing
> > something painfully obvious.
>
> Yep, it looks like --with-python is failing.
>
> I've seen similar problems with svn's configure script in the past --
> the various --with-foo arguments don't always work.
>
> If you look inside the configure script for Python stuff, you'll see
> that it checks the PATH, and looks for an environment variable called
> PYTHON. So try
> export PATH=/usr/local/bin:$PATH
> export PYTHON=/usr/local/bin/python
> then rerun configure
>
> If that fails, maybe try setting LDSHARED, based on the error messages.
> But I suspect that if you give it the right Python, the rest will work.
>
> --
> David Ripton dripton@ripton.net
>
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org