Mercurial > mxe-octave
changeset 4353:ae1280afbc8c
wxwidgets: add fixes for stdc++11 issues in later gcc versions
* src/wxwidgets.mk: disable use of stl, enable unicode
* src/wxwidgets-1-c++11-related-fixes.patch: new file from mxe.cc
* dist-files.mk: add ref to wxwidgets-1-c++11-related-fixes.patch
author | John D |
---|---|
date | Thu, 23 Feb 2017 14:08:10 -0500 |
parents | bf358512f67e |
children | 79d895171597 |
files | dist-files.mk src/wxwidgets-1-c++11-related-fixes.patch src/wxwidgets.mk |
diffstat | 3 files changed, 35 insertions(+), 5 deletions(-) [+] |
line wrap: on
line diff
--- a/dist-files.mk Tue Feb 14 11:35:52 2017 -0800 +++ b/dist-files.mk Thu Feb 23 14:08:10 2017 -0500 @@ -686,6 +686,7 @@ winpcap.mk \ wt-1-fixes.patch \ wt.mk \ + wxwidgets-1-c++11-related-fixes.patch \ wxwidgets-test.cpp \ wxwidgets.mk \ x11.mk \
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/src/wxwidgets-1-c++11-related-fixes.patch Thu Feb 23 14:08:10 2017 -0500 @@ -0,0 +1,27 @@ +From: Boris Pek <tehnick-8@mail.ru> +Date: Thu, 05 May 2016 19:11:19 +0300 +Subject: [PATCH] fix build with GCC >= 6.x + +diff --git a/src/stc/scintilla/src/Editor.cxx b/src/stc/scintilla/src/Editor.cxx +--- a/src/stc/scintilla/src/Editor.cxx ++++ b/src/stc/scintilla/src/Editor.cxx +@@ -10,6 +10,7 @@ + #include <stdio.h> + #include <ctype.h> + #include <assert.h> ++#include <math.h> + + #include <string> + #include <vector> +@@ -5841,9 +5842,9 @@ + } + + static bool Close(Point pt1, Point pt2) { +- if (abs(pt1.x - pt2.x) > 3) ++ if (fabs(pt1.x - pt2.x) > 3) + return false; +- if (abs(pt1.y - pt2.y) > 3) ++ if (fabs(pt1.y - pt2.y) > 3) + return false; + return true; + }
--- a/src/wxwidgets.mk Tue Feb 14 11:35:52 2017 -0800 +++ b/src/wxwidgets.mk Thu Feb 23 14:08:10 2017 -0500 @@ -26,9 +26,9 @@ --enable-compat24 \ --enable-compat26 \ --enable-gui \ - --enable-stl \ + --disable-stl \ --enable-threads \ - --disable-unicode \ + --enable-unicode \ --disable-universal \ --with-themes=all \ --with-msw \ @@ -55,11 +55,13 @@ --without-hildon \ --without-dmalloc \ --without-odbc \ - LIBS=" `'$(MXE_PKG_CONFIG)' --libs-only-l libtiff-4`" + LIBS=" `'$(MXE_PKG_CONFIG)' --libs-only-l libtiff-4`" \ + CXXFLAGS='-std=gnu++11' \ + CXXCPP='$(MXE_CXX) -E -std=gnu++11' - $(MAKE) -C '$(1)' -j '$(JOBS)' bin_PROGRAMS= sbin_PROGRAMS= noinst_PROGRAMS= + $(MAKE) -C '$(1)' -j '$(JOBS)' $(MXE_DISABLE_DOCS) $(MXE_DISABLE_PROGS) - $(MAKE) -C '$(1)' -j 1 install bin_PROGRAMS= sbin_PROGRAMS= noinst_PROGRAMS= __install_wxrc___depname= + $(MAKE) -C '$(1)' -j 1 install $(MXE_DISABLE_DOCS) $(MXE_DISABLE_PROGS) __install_wxrc___depname= $(INSTALL) -m755 '$(HOST_BINDIR)/wx-config' '$(BUILD_TOOLS_PREFIX)/bin/$(MXE_TOOL_PREFIX)wx-config' mv $(HOST_LIBDIR)/wxbase30*.dll $(HOST_BINDIR)/