summaryrefslogtreecommitdiff
path: root/src/3rdparty/clip2tri/clip2tri.pro
diff options
context:
space:
mode:
authorPaolo Angelelli <paolo.angelelli@theqtcompany.com>2016-04-07 15:50:46 +0200
committerPaolo Angelelli <paolo.angelelli@theqtcompany.com>2016-06-15 09:41:05 +0000
commit0da6abc2cb62ec9cf51c594493142c1626c83ffe (patch)
treebdd0db1afb49a0a54007e7ee305417ef935d38a0 /src/3rdparty/clip2tri/clip2tri.pro
parentd90b2bffd76bf74ab4b6e6c0c68a26f6830c8d6f (diff)
downloadqtlocation-0da6abc2cb62ec9cf51c594493142c1626c83ffe.tar.gz
Fix for crash on tessellation of self-intersectiong GeoPolygons
QtLocation makes use of a 3rd party library for polygon tessellation, poly2tri. This library is known to be weak in handling complex input, like, for example, polygons with self intersecting edges. Sanitizing the input data through clipper solves the problem, and it has already been implemented in the clip2tri library, which this patch includes and uses. Task-number: QTBUG-52076 Change-Id: I071a58e202345bc71da583995f7245361f00e8c4 Reviewed-by: Lars Knoll <lars.knoll@qt.io> Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
Diffstat (limited to 'src/3rdparty/clip2tri/clip2tri.pro')
-rw-r--r--src/3rdparty/clip2tri/clip2tri.pro18
1 files changed, 18 insertions, 0 deletions
diff --git a/src/3rdparty/clip2tri/clip2tri.pro b/src/3rdparty/clip2tri/clip2tri.pro
new file mode 100644
index 00000000..50901c06
--- /dev/null
+++ b/src/3rdparty/clip2tri/clip2tri.pro
@@ -0,0 +1,18 @@
+TARGET = clip2tri
+
+CONFIG += staticlib exceptions
+
+load(qt_helper_lib)
+
+# workaround for QTBUG-31586
+contains(QT_CONFIG, c++11): CONFIG += c++11
+
+*-g++* {
+ QMAKE_CXXFLAGS += -O3 -ftree-vectorize -ffast-math -funsafe-math-optimizations -Wno-error=return-type
+}
+
+HEADERS += clip2tri.h
+SOURCES += clip2tri.cpp
+
+LIBS_PRIVATE += -L$$MODULE_BASE_OUTDIR/lib -lpoly2tri$$qtPlatformTargetSuffix() -lclipper$$qtPlatformTargetSuffix()
+