[Distutils] setup.py for a wrapper extension?

Mike Olson Mike.Olson@fourthought.com
Sun Oct 1 13:05:01 2000


Pete Shinners wrote:


Just thought of something else that is probably cleaner.  Add som
command line options and have the user specify where the library and
header files are....

Mike



> 
> i've got a python extension that is simply a wrapping
> around another C library. (not an uncommon case :])
> 
> i cannot figure out the 'right' way to check for and
> link/include this dependency into my distutils
> setup.py script.
> 
> under linux, it's pretty easy to assume the correct
> header and shared library will be somewhere in the
> standard include and library directories
> /usr/local/include, /usr/local/lib, etc
> 
> my main concern is getting it working with windows
> (and keeping it crossplatform happy for linux). my best
> bet in windows seems to be walk around the parent directory
> tree trying to find directories for the dependency??
> if that is the best way, it would probably be nice for
> the linux version to use this method or look in the
> standard compiler directories ???????
> 
> i'm hoping someone out there has an example doing just
> this sort of stuff i could look at. the documentation doesn't
> mention anything about this sort of stuff. (except for
> adding library and include info to the Extensions() call
> 
> thanks for any help and/or guidance. the distutils have
> just amazed me.
> 
> (please help, i couldn't get any responses on c.l.python)
> 
> _______________________________________________
> Distutils-SIG maillist  -  Distutils-SIG@python.org
> http://www.python.org/mailman/listinfo/distutils-sig

-- 
Mike Olson				 Principal Consultant
mike.olson@fourthought.com               (303)583-9900 x 102
Fourthought, Inc.                         http://Fourthought.com 
Software-engineering, knowledge-management, XML, CORBA, Linux, Python