On vendredi 5 janvier 2018 17:51:26 CET Gregory, Matthew wrote: > Hi all, > > I'm sure to show my ignorance here, but I've been periodically building both > the 2.2 and trunk branches on Windows using MSVC for Python 2.7 (as I think > the compiler version needs to match how Python itself was built [MSC v.1500 > 32 bit (Intel)]). With the recent update in trunk requiring C++11, MSVC > for Python 2.7 now errors out: > > c:\foss4g\gdal_trunk\gdal\port\cpl_port.h(187) : fatal error C1189: > #error : Must have C++11 or newer. > > Is there a way to compile the GDAL python bindings with still using MSVC for > Python 2.7 -or- if I update to MSVC 14, can I still build bindings that > will work with 2.7?
Define SET DISTUTILS_USE_SDK=1 SET MSSdk=1 so that the active MSVC version is used when building the Python bindings. This is what is used in gisinternals builds & appveyor builds We should likely document that somewhere appropriate. Perhaps in https://trac.osgeo.org/gdal/wiki/BuildingOnWindows Even -- Spatialys - Geospatial professional services http://www.spatialys.com
_______________________________________________ gdal-dev mailing list gdal-dev@lists.osgeo.org https://lists.osgeo.org/mailman/listinfo/gdal-dev