Komnomnomnom / swigibpy

Third party Interactive Brokers Python API generated from TWS C++ API using SWIG.
http://github.com/Komnomnomnom/swigibpy/
Other
157 stars 35 forks source link

fails with VS11 #2

Closed asemx closed 12 years ago

asemx commented 12 years ago

below is the error msg

"\afx.h(24) : fatal error C1189: #error : Building MFC application with /MD[d](CRT dll version) requires MFC shared dll version. Please #define _AFXDLL or do not use /MD[d]"

asemx commented 12 years ago

was able to compile by defining below flag (just temporarily modified afx.h file), i think we need to get into the build config

define _AFXDLL

Komnomnomnom commented 12 years ago

Thanks algopats, I'll look into including that directive.

Komnomnomnom commented 12 years ago

Distutils adds the /MD flag so I think the issue lies with them and Visual Studio 11.

However after reading around this a bit it seems it is not recommended to built Python extensions on Windows with Visual Studio versions other than 2008 (version 9), as that is what the windows version of Python is built with. So it seems distutils will only properly support that version....

asemx commented 12 years ago

agree.

just want to note, VS11 did work using the above workaround. I am now successfully using tws with swigibpy.

Komnomnomnom commented 12 years ago

Thanks, I'll update the documentation with some info about visual studio.