When attempting to install swigibpy using pip and Python 3.5.1 in Windows, I received the following error when attempting to compile swigibpy/IB/Shared/EClientSocketBase.cpp:
Macro definition of snprintf conflicts with Standard Library function declaration
A quick search on Google yielded a very helpful result. It appears that until now, many libraries (including IB API) used snprintf by defining it as _snprintf, since _snprintf was supported.
As of VS2015 (e.g. VC14), snprintf is officially supported, and it should therefore never be #define'd.
The offending line is in swigibpy/IB/Shared/StdAfx.h (8):
#define snprintf _snprintf
It would appear that IB fixed this in a release following the version included with swigibpy 0.4.1. I believe that this is also specific to the Python 3.x releases because Python 2.x builds point to earlier version of the VC++ compiler.
Not sure if this is super urgent given the pending push of version 0.5, but wanted to raise it in case it is a forcing function to move things along.
When attempting to install swigibpy using pip and Python 3.5.1 in Windows, I received the following error when attempting to compile swigibpy/IB/Shared/EClientSocketBase.cpp:
A quick search on Google yielded a very helpful result. It appears that until now, many libraries (including IB API) used
snprintfby defining it as_snprintf, since_snprintfwas supported.As of VS2015 (e.g. VC14),
snprintfis officially supported, and it should therefore never be#define'd.The offending line is in swigibpy/IB/Shared/StdAfx.h (8):
It would appear that IB fixed this in a release following the version included with swigibpy 0.4.1. I believe that this is also specific to the Python 3.x releases because Python 2.x builds point to earlier version of the VC++ compiler.
Not sure if this is super urgent given the pending push of version 0.5, but wanted to raise it in case it is a forcing function to move things along.