-
Notifications
You must be signed in to change notification settings - Fork 194
Description
Hi,
i am trying to compile the project on my windows 7 machine.
I have the following configuration:
Environment: Toolset=v140; Configuration: Debug; Platform: x86
However, i got the following error:
C:\Program Files (x86)\Windows Kits\10\Include\10.0.10240.0\ucrt\stdio.h(1421): fatal error C1189: #error: Macro definition of vsnprintf conflicts with Standard Library function declaration [C:\projects\openigtlink\build\Deps\openHEVC-bin\LibOpenHevcWrapper.vcxproj] [C:\projects\openigtlink\build\openHEVC.vcxproj]
I could fix the error by deleting the vsnprintf definition in CmakeLists file, showed as below:
if(WIN32)
add_definitions(
-Dsnprintf=avpriv_snprintf
-Dvsnprintf=avpriv_vsnprintf
-Dinline=__inline
-Drestrict=__restrict
)
endif()
Do you have a general solution for this problem?
Another issue is the function:
static attribute(always_inline)) inline ...................
This function also create error in compiling
after deleting the attribute(always_inline)) , the compiling succeeded.
Your kind answer to my questions would be greatly appreciated.
Best Regards,
Chan