Page MenuHomeFreeBSD

D8121.diff
No OneTemporary

D8121.diff

Index: head/devel/qt5-qdoc/Makefile
===================================================================
--- head/devel/qt5-qdoc/Makefile
+++ head/devel/qt5-qdoc/Makefile
@@ -2,6 +2,7 @@
PORTNAME= qdoc
DISTVERSION= ${QT5_VERSION}
+PORTREVISION= 1
CATEGORIES= devel textproc
PKGNAMEPREFIX= qt5-
@@ -17,4 +18,10 @@
PLIST_FILES= ${QT_BINDIR}/qdoc
-.include <bsd.port.mk>
+.include <bsd.port.pre.mk>
+
+.if ${OPSYS} == FreeBSD && ${OSVERSION} < 1000000
+EXTRA_PATCHES= ${FILESDIR}/extrapatch-src_qdoc_qdocindexfiles.cpp
+.endif
+
+.include <bsd.port.post.mk>
Index: head/devel/qt5-qdoc/files/extrapatch-src_qdoc_qdocindexfiles.cpp
===================================================================
--- head/devel/qt5-qdoc/files/extrapatch-src_qdoc_qdocindexfiles.cpp
+++ head/devel/qt5-qdoc/files/extrapatch-src_qdoc_qdocindexfiles.cpp
@@ -0,0 +1,21 @@
+There is a bug [1] in the old gcc used on FreeBSD 9.3, which makes
+qdoc segfault on sorting while generating its index sections.
+
+As mentioned in [2] by Michael Hansen, we can circument this by using
+qSort instead of std::sort on FreeBSD 9.x.
+
+
+[1] https://gcc.gnu.org/bugzilla/show_bug.cgi?id=59391
+[2] https://bugreports.qt.io/browse/QTBUG-43057
+
+--- src/qdoc/qdocindexfiles.cpp.orig 2016-10-02 07:52:39 UTC
++++ src/qdoc/qdocindexfiles.cpp
+@@ -1476,7 +1476,7 @@ void QDocIndexFiles::generateIndexSectio
+ const Aggregate* inner = static_cast<const Aggregate*>(node);
+
+ NodeList cnodes = inner->childNodes();
+- std::sort(cnodes.begin(), cnodes.end(), compareNodes);
++ qSort(cnodes.begin(), cnodes.end(), compareNodes);
+
+ foreach (Node* child, cnodes) {
+ generateIndexSections(writer, child, generateInternalNodes);

File Metadata

Mime Type
text/plain
Expires
Fri, Feb 27, 2:57 AM (10 h, 7 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
29011475
Default Alt Text
D8121.diff (1 KB)

Event Timeline