CLucene: Fix compilation with win32-g++ and C++11
authorKai Koehne <kai.koehne@nokia.com>
Thu, 6 Sep 2012 12:40:02 +0000 (14:40 +0200)
committerQt by Nokia <qt-info@nokia.com>
Thu, 13 Sep 2012 12:41:52 +0000 (14:41 +0200)
We plan to enable -std=c++0x for MinGW gcc. However, this let gcc set
__STRICT_ANSI__, and the MinGW headers then do not declare e.g. _i64tow.

Instead of working around this in clucene we just switch to less strict -std=gnu++0x mode.

Change-Id: I734908048a8ab93f7b68a7be6b8a6cb8edae7b43
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
src/assistant/clucene/clucene.pro

index 725d1b8..a50fb43 100644 (file)
@@ -31,6 +31,9 @@ CONFIG(exceptions_off) {
     }
 }
 
+# otherwise mingw headers do not declare common functions like _i64tow
+win32-g++*:QMAKE_CXXFLAGS_CXX11 = -std=gnu++0x
+
 win32-msvc.net | win32-msvc2* {
     QMAKE_CFLAGS_RELEASE       -= -O2
     QMAKE_CXXFLAGS_RELEASE     -= -O2