I have written some Cython code and compiled a .pyd to include as part of a package. The package is an ArcGIS toolbox that uses a different version of the msvc libraries (msvcr90.dll, msvcp90.dll, msvcm90.dll) and a different manifest. This causes a version compatibility problem when I import ArcGIS's main module, arcpy.

How can I tell my setup.py/distutils to use the msvc libraries that ArcGIS uses during compilation?

Alternatively, is there a work-around, e.g. excluding the manifest from the compiled code (which I have tried to do, but seemingly unsuccessfully)?

I have posted related issues to two other forums. If you have access, please see the following posts for more info: