[Distutils] Customizing for MinGW
andreas.held at smi-grp.com
andreas.held at smi-grp.com
Tue Sep 23 07:41:56 EDT 2003
Hi
I am distributing an extension that can be built either using MinGW or
MSVC on Windows.
However, the extension must link against some additional libraries, whose
name change
depending on the compiler that was used to build them.
For instance, using MSVC I have
# module declarations
module1 = Extension('_MyModule',
libraries=ExtLib_One)
and for MinGW I have
# module declarations
module1 = Extension('_MyModule',
libraries=ExtLibOne)
Unfortunately, I do not have any influence on the naming of those
libraries and I wondered
whether I can customize distutils to account for this. Basically, what I
want is the follwoing
if sys.platform=='win32':
if compiler=='mingw32':
libnames= ExtLibOne
else:
libnames=ExtLib_One
How can I obtain the information on what compiler the script was invoked
with, e.g. I would need the value
of the command line switch '--compiler'? Can this be done at all?
Thanks for your help
Regards
Andreas Held
pyfltk.sourceforge.net
More information about the Distutils-SIG
mailing list