[Distutils] Building external libs with distutils

M.-A. Lemburg mal@lemburg.com
Thu May 17 13:47:01 2001


Robin Becker wrote:
> 
> In article <3B03EF8A.93043D9D@lemburg.com>, M.-A. Lemburg
> <mal@lemburg.com> writes
> >I was just wondering whether anybody has already tackled the
> >job of using distutils to build external libs. I am thinking
> >of the following setup here:
> >
> >* you have a source tree in ./libsrc
> >* building the lib is done in the usual Unix way:
> >  cd ./libsrc; ./configure; make
> >* now copy te resulting .a or .so to your Python package
> >  target build dir
> >* continue with the normal distutils procedure to build the
> >  Python wrapper
> >
> >Is this possible in a fairly portable way (at least with
> >respect to Unix platforms) ?
> >
> well I have used the standard lib building scheme, but that doesn't
> involve the configure make framework. All the flags were set in
> setup.py. Which is why the AIX build of my bitmap renderer went wrong;
> ie it didn't know about endianness which is presumably something that
> the configure script would normally figure out.

Right... I think we really need to get distutils to know
about the standard Unix autoconf-based build process in
order to include building external libs right along with
the Python extensions.

I'm currently looking at having iODBC built directly by the
mxODBC setup -- this would allow shipping a single archive
for the whole machinery and greatly simplify the installation
process.

This is also a prerequisite for auto-building in a CPAN like
way.

-- 
Marc-Andre Lemburg
CEO eGenix.com Software GmbH
______________________________________________________________________
Company & Consulting:                           http://www.egenix.com/
Python Software:                        http://www.lemburg.com/python/