[geos-commits] r3109 - trunk/src
svn_geos at osgeo.org
svn_geos at osgeo.org
Sun Oct 10 17:28:29 EDT 2010
Author: mloskot
Date: 2010-10-10 14:28:29 -0700 (Sun, 10 Oct 2010)
New Revision: 3109
Modified:
trunk/src/inlines.cpp
Log:
Disable inline.obj if GEOS_INLINE defined while building with Visual C++
Modified: trunk/src/inlines.cpp
===================================================================
--- trunk/src/inlines.cpp 2010-10-10 21:15:11 UTC (rev 3108)
+++ trunk/src/inlines.cpp 2010-10-10 21:28:29 UTC (rev 3109)
@@ -23,18 +23,19 @@
// Otherwise we'll end up with duplicated symbols
#ifdef GEOS_INLINE
+// If using Visual C++ with GEOS_INLINE, do not build inline.obj
+// otherwise linker will complain "multiple definition" errors.
// If using MingW with GEOS_INLINE to build a DLL then MingW's gcc
// has already generated the stubs for the contents of this file.
// Hence we need to supress it to avoid "multiple definition" errors
// during the final link phase
-#if ! defined(__MINGW32__) || defined(__MINGW32__) && !defined(DLL_EXPORT)
+#if !defined(_MSC_VER) && (!defined(__MINGW32__) || defined(__MINGW32__) && !defined(DLL_EXPORT))
// If using cygwin then we suppress the "multiple definition" errors by
// ignoring this section completely; the cygwin linker seems to handle
// the stubs correctly at link time by itself
-#if ! defined(__CYGWIN__)
+#if !defined(__CYGWIN__)
-
// Undefine GEOS_INLINE so that .inl files
// will be ready for an implementation file
#undef GEOS_INLINE
More information about the geos-commits
mailing list