summaryrefslogtreecommitdiff
path: root/dist/gdb
diff options
context:
space:
mode:
authorOrgad Shaneh <orgad.shaneh@audiocodes.com>2016-11-02 10:55:04 +0200
committerOrgad Shaneh <orgads@gmail.com>2016-11-02 12:07:33 +0000
commit7ccc5803dc0a3927b8bf95bcf6518cb51c6ff63e (patch)
tree2607bb904f6ebaed7bac29f5c326a341050d83da /dist/gdb
parente4086f45328eb73c4a70b7d3f898fbc4abab24f9 (diff)
downloadqt-creator-7ccc5803dc0a3927b8bf95bcf6518cb51c6ff63e.tar.gz
Dist/GDB: Upgrade to 7.12
Include a patch for MinGW Change-Id: I3bbed52e92b5ae657debb5b6045da31274ccf6c5 Reviewed-by: hjk <hjk@qt.io>
Diffstat (limited to 'dist/gdb')
-rw-r--r--dist/gdb/Makefile.linux2
-rw-r--r--dist/gdb/Makefile.mingw5
-rw-r--r--dist/gdb/Makefile.osx2
-rw-r--r--dist/gdb/patches/mingw-python.patch32
4 files changed, 37 insertions, 4 deletions
diff --git a/dist/gdb/Makefile.linux b/dist/gdb/Makefile.linux
index e93747baba..2b016af719 100644
--- a/dist/gdb/Makefile.linux
+++ b/dist/gdb/Makefile.linux
@@ -5,7 +5,7 @@ staging=${broot}/staging
pyversion=2.7
expatversion=2.1.1
arch=`uname -sm | sed 's/ /-/g' | tr A-Z a-z`
-version=7.11.1
+version=7.12
targetdir=${broot}/qtcreator-gdb-${version}
packagename=qtcreator-gdb-${version}-${arch}.tar.gz
diff --git a/dist/gdb/Makefile.mingw b/dist/gdb/Makefile.mingw
index 4a84e463f0..96cea0f364 100644
--- a/dist/gdb/Makefile.mingw
+++ b/dist/gdb/Makefile.mingw
@@ -6,7 +6,7 @@ pyversion=2.7
pydir=${broot}/python
expatversion=2.1.1
iconvversion=1.14
-version=7.11.1
+version=7.12
targetdir=${broot}/qtcreator-gdb-${version}
packageparts=${targetdir}/lib ${targetdir}/data-directory ${targetdir}/libiconv-2.dll ${targetdir}/python27.dll ${targetdir}/libexpat-1.dll
arch=`uname -sm | sed 's/ /-/g' | tr A-Z a-z`
@@ -71,7 +71,8 @@ ${staging}/gdb-${version}/configure: ${source}/gdb-${version}.tar.xz | makestagi
echo "Extracting gdb..." && \
tar xf ${source}/gdb-${version}.tar.xz && \
cd gdb-${version} && \
- touch configure
+ touch configure && \
+ patch -p1 < ${broot}/patches/mingw-python.patch
${staging}/lib/libiconv.a: ${source}/libiconv-${iconvversion}.tar.gz | makestagingdir
cd ${staging} && \
diff --git a/dist/gdb/Makefile.osx b/dist/gdb/Makefile.osx
index 9cc958138d..e8147f89ee 100644
--- a/dist/gdb/Makefile.osx
+++ b/dist/gdb/Makefile.osx
@@ -5,7 +5,7 @@ staging=${broot}/staging
pyversion=2.7
expatversion=2.1.1
arch=`uname -sm | sed 's/ /-/g' | tr A-Z a-z`
-version=7.11.1
+version=7.12
targetdir=${broot}/qtcreator-gdb-${version}
packagename=qtcreator-gdb-${version}-${arch}.tar.gz
diff --git a/dist/gdb/patches/mingw-python.patch b/dist/gdb/patches/mingw-python.patch
new file mode 100644
index 0000000000..3fb37f4bd4
--- /dev/null
+++ b/dist/gdb/patches/mingw-python.patch
@@ -0,0 +1,32 @@
+From a0d2825e7a15f8d2d5ac4e7dd315a8d29ab804e6 Mon Sep 17 00:00:00 2001
+From: Orgad Shaneh <orgad.shaneh@audiocodes.com>
+Date: Wed, 2 Nov 2016 11:52:52 +0200
+Subject: [PATCH] Fix C++ compilation on MinGW
+
+When compiling with MinGW, pyconfig.h renames hypot to _hypot.
+
+If math.h is included later, hypot is not declared correctly.
+
+When g++ is used, it has 'using ::hypot', which doesn't exist.
+---
+ gdb/python/python-internal.h | 4 ++++
+ 1 file changed, 4 insertions(+)
+
+diff --git a/gdb/python/python-internal.h b/gdb/python/python-internal.h
+index 8545c7b..5e80dce 100644
+--- a/gdb/python/python-internal.h
++++ b/gdb/python/python-internal.h
+@@ -88,6 +88,10 @@
+ /* Request clean size types from Python. */
+ #define PY_SSIZE_T_CLEAN
+
++/* math.h has to be included before Python.h, since pyconfig.h
++ renames hypot to _hypot, and this breaks MinGW compilation with g++. */
++#include <math.h>
++
+ /* Include the Python header files using angle brackets rather than
+ double quotes. On case-insensitive filesystems, this prevents us
+ from including our python/python.h header file. */
+--
+2.10.1.windows.1
+