diff options
author | jperkin <jperkin@pkgsrc.org> | 2018-01-31 12:36:57 +0000 |
---|---|---|
committer | jperkin <jperkin@pkgsrc.org> | 2018-01-31 12:36:57 +0000 |
commit | eb1ee2ccb91bda0ad8ae8b40c66194c6a170110b (patch) | |
tree | ca68e175492cb73d2d7e2d381252ed07663bf4a9 /x11 | |
parent | 82b721c43613c49d09d2fec8485836505b1c72bd (diff) | |
download | pkgsrc-eb1ee2ccb91bda0ad8ae8b40c66194c6a170110b.tar.gz |
qt5-qtbase: Various fixes, primarily for SunOS/clang.
Diffstat (limited to 'x11')
-rw-r--r-- | x11/qt5-qtbase/Makefile | 14 | ||||
-rw-r--r-- | x11/qt5-qtbase/Makefile.common | 5 | ||||
-rw-r--r-- | x11/qt5-qtbase/distinfo | 4 | ||||
-rw-r--r-- | x11/qt5-qtbase/files/qmake.conf | 1 | ||||
-rw-r--r-- | x11/qt5-qtbase/patches/patch-src_corelib_global_qconfig-bootstrapped.h | 18 | ||||
-rw-r--r-- | x11/qt5-qtbase/patches/patch-src_network_kernel_qnetworkinterface__unix.cpp | 44 |
6 files changed, 80 insertions, 6 deletions
diff --git a/x11/qt5-qtbase/Makefile b/x11/qt5-qtbase/Makefile index 25535f4b5f5..081ecfb18e5 100644 --- a/x11/qt5-qtbase/Makefile +++ b/x11/qt5-qtbase/Makefile @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.51 2018/01/28 20:11:10 wiz Exp $ +# $NetBSD: Makefile,v 1.52 2018/01/31 12:36:57 jperkin Exp $ DISTNAME= qtbase-everywhere-src-${QTVERSION} PKGNAME= qt5-qtbase-${QTVERSION} @@ -64,7 +64,7 @@ PLIST_VARS+= egl .include "../../mk/compiler.mk" .if ${OPSYS} == "SunOS" -. if !empty(CC_VERSION:Mgcc*) +. if !empty(PKGSRC_COMPILER:Mgcc) || !empty(PKGSRC_COMPILER:Mclang) . if ${ABI:U} == "64" CONFIGURE_ARGS+= -platform solaris-g++-64 . else @@ -77,7 +77,7 @@ CONFIGURE_ARGS+= -platform solaris-cc-64 CONFIGURE_ARGS+= -platform solaris-cc . endif . endif -SYS_LIBS= -lresolv -lsocket -lnsl -lrt +NETWORK_LIBS= -lsocket -lnsl .elif ${OPSYS} == "Interix" CONFIGURE_ARGS+= -platform interix-g++ CFLAGS+= -I/usr/local/include/bind @@ -104,7 +104,7 @@ LDFLAGS.FreeBSD+= -lutil REPLACE_PERL+= bin/fixqt4headers.pl REPLACE_PERL+= bin/syncqt.pl -REPLACE_PERL+= mkspecs/features/uikit/devices.pl +REPLACE_PERL+= mkspecs/features/data/unix/findclasslist.pl PTHREAD_OPTS+= require UNLIMIT_RESOURCES= datasize @@ -133,6 +133,11 @@ SUBST_FILES.opt= mkspecs/common/gcc-base.conf SUBST_SED.opt= -e 's,-O[s23],,' SUBST_SED.opt+= -e 's,-fvisibility=hidden,,' +SUBST_CLASSES.SunOS+= vscript +SUBST_STAGE.vscript= pre-configure +SUBST_FILES.vscript= mkspecs/common/gcc-base-unix.conf +SUBST_SED.vscript= -e '/QMAKE_LFLAGS_VERSION_SCRIPT/d' + SUBST_CLASSES+= path SUBST_STAGE.path= pre-configure SUBST_MESSAGE.path= Add to default XDG path. @@ -156,6 +161,7 @@ pre-configure: -e 's:@LDFLAGS@:${LDFLAGS:Q}:g' \ -e 's:@CFLAGS@:${CFLAGS:Q}:g' \ -e 's:@CXXFLAGS@:${CXXFLAGS:Q}:g' \ + -e 's:@NETWORK_LIBS@:${NETWORK_LIBS:Q}:g' \ -e 's:@SYS_LIBS@:${SYS_LIBS:Q}:g' \ -e 's:@LEX@:${LEX}:g' \ -e 's:@YACC@:${TOOLS_CMDLINE_YACC:Q}:g' \ diff --git a/x11/qt5-qtbase/Makefile.common b/x11/qt5-qtbase/Makefile.common index e72d669099c..3fbacd85a65 100644 --- a/x11/qt5-qtbase/Makefile.common +++ b/x11/qt5-qtbase/Makefile.common @@ -1,4 +1,4 @@ -# $NetBSD: Makefile.common,v 1.24 2018/01/18 09:15:29 markd Exp $ +# $NetBSD: Makefile.common,v 1.25 2018/01/31 12:36:57 jperkin Exp $ # used by x11/qt5-mysql/Makefile # used by x11/qt5-odbc/Makefile # used by x11/qt5-psql/Makefile @@ -32,6 +32,9 @@ BUILDLINK_TRANSFORM+= opt:-ldl:${BUILDLINK_LDADD.dl:M*} USE_LANGUAGES= c c++11 USE_TOOLS+= gmake perl:build pkg-config +# Avoid failures to due 'register' usage in X11 headers. +CFLAGS+= -Wno-register + # wcstof(3) etc. is used in C++ code. CFLAGS.NetBSD+= -D_NETBSD_SOURCE diff --git a/x11/qt5-qtbase/distinfo b/x11/qt5-qtbase/distinfo index b439444d9bd..cbd10b076b3 100644 --- a/x11/qt5-qtbase/distinfo +++ b/x11/qt5-qtbase/distinfo @@ -1,4 +1,4 @@ -$NetBSD: distinfo,v 1.35 2018/01/17 19:30:46 markd Exp $ +$NetBSD: distinfo,v 1.36 2018/01/31 12:36:57 jperkin Exp $ SHA1 (qtbase-everywhere-src-5.10.0.tar.xz) = 34fa3d4e7bb2b1545247a616190efaf74804db49 RMD160 (qtbase-everywhere-src-5.10.0.tar.xz) = d6f9ab8526ebe50791b9b948930806dc8b3be73b @@ -12,11 +12,13 @@ SHA1 (patch-qmake_Makefile.unix) = ec1af3d76dc5bd0b7b1d375ceeebbd016b6f555f SHA1 (patch-qmake_generators_makefile.cpp) = 26366f21108534a321d9d7c7f87066e9acf7d981 SHA1 (patch-qmake_generators_unix_unixmake2.cpp) = f0a4fdd304af2ee6c1b63022ccfcebd2640f0fcb SHA1 (patch-src_corelib_codecs_qiconvcodec.cpp) = 4387447f0f23f0f8c623c0c019ab632bc1cb5617 +SHA1 (patch-src_corelib_global_qconfig-bootstrapped.h) = ec5487cc27518b2588d40e7ad59eeee89e93b055 SHA1 (patch-src_corelib_io_io.pri) = fd2f93b5af4dda729b274dd0d8f82ca29b3cb62a SHA1 (patch-src_corelib_io_qstandardpaths_unix.cpp) = de4b6c6be89524763e40698bcf5e8f413abdb938 SHA1 (patch-src_corelib_io_qstorageinfo_unix.cpp) = 9919194e9f6b47f1f311b8f8223a6a7519152073 SHA1 (patch-src_corelib_thread_qwaitcondition__unix.cpp) = 37f61c305335ca6a690b0491220ca8de508bfdb6 SHA1 (patch-src_network_kernel_qhostinfo__unix.cpp) = 3131d74a547abdcca7594b49b739cc1c0eed68f5 +SHA1 (patch-src_network_kernel_qnetworkinterface__unix.cpp) = 2c5569eb2ba19999eb62e4fdb54f347c88f6e6a5 SHA1 (patch-src_openglextensions_openglextensions.pro) = 575d31c3a48f36d82dc1f342078e636f4c25e33f SHA1 (patch-src_plugins_platforminputcontexts_compose_compose.pro) = 1655b2320b250defcfa406c95e58a1b728c0f2d9 SHA1 (patch-src_plugins_platforminputcontexts_compose_generator_qtablegenerator.cpp) = 655ca6601ddd1768b92758cfdfd8d1c3514fba94 diff --git a/x11/qt5-qtbase/files/qmake.conf b/x11/qt5-qtbase/files/qmake.conf index 7ea283302ac..45a06273b56 100644 --- a/x11/qt5-qtbase/files/qmake.conf +++ b/x11/qt5-qtbase/files/qmake.conf @@ -38,6 +38,7 @@ QMAKE_LIBS_X11 = -lXext -lX11 -lm @SYS_LIBS@ QMAKE_LIBS_OPENGL = -lGL QMAKE_LIBS_OPENGL_QT = -lGL QMAKE_LIBS_THREAD = @PTHREAD_LIBS@ +QMAKE_LIBS_NETWORK = @NETWORK_LIBS@ QMAKE_AR = @AR@ cqs QMAKE_OBJCOPY = objcopy diff --git a/x11/qt5-qtbase/patches/patch-src_corelib_global_qconfig-bootstrapped.h b/x11/qt5-qtbase/patches/patch-src_corelib_global_qconfig-bootstrapped.h new file mode 100644 index 00000000000..80de4d1e86b --- /dev/null +++ b/x11/qt5-qtbase/patches/patch-src_corelib_global_qconfig-bootstrapped.h @@ -0,0 +1,18 @@ +$NetBSD: patch-src_corelib_global_qconfig-bootstrapped.h,v 1.1 2018/01/31 12:36:57 jperkin Exp $ + +SunOS does not have getauxval. + +--- src/corelib/global/qconfig-bootstrapped.h.orig 2017-11-30 13:49:46.000000000 +0000 ++++ src/corelib/global/qconfig-bootstrapped.h +@@ -78,7 +78,11 @@ + #define QT_FEATURE_cxx11_random (QT_HAS_INCLUDE(<random>) ? 1 : -1) + #define QT_NO_DATASTREAM + #define QT_FEATURE_datetimeparser -1 ++#ifdef __sun ++# define QT_FEATURE_getauxval -1 ++#else + #define QT_FEATURE_getauxval (QT_HAS_INCLUDE(<sys/auxv.h>) ? 1 : -1) ++#endif + #define QT_FEATURE_getentropy -1 + #define QT_NO_GEOM_VARIANT + #define QT_FEATURE_iconv -1 diff --git a/x11/qt5-qtbase/patches/patch-src_network_kernel_qnetworkinterface__unix.cpp b/x11/qt5-qtbase/patches/patch-src_network_kernel_qnetworkinterface__unix.cpp new file mode 100644 index 00000000000..4bad1c89c81 --- /dev/null +++ b/x11/qt5-qtbase/patches/patch-src_network_kernel_qnetworkinterface__unix.cpp @@ -0,0 +1,44 @@ +$NetBSD: patch-src_network_kernel_qnetworkinterface__unix.cpp,v 1.1 2018/01/31 12:36:57 jperkin Exp $ + +Support ifr_index. + +--- src/network/kernel/qnetworkinterface_unix.cpp.orig 2017-11-30 13:49:46.000000000 +0000 ++++ src/network/kernel/qnetworkinterface_unix.cpp +@@ -136,7 +136,11 @@ uint QNetworkInterfaceManager::interface + + uint id = 0; + if (qt_safe_ioctl(socket, SIOCGIFINDEX, &req) >= 0) ++#ifdef ifr_ifindex + id = req.ifr_ifindex; ++#else ++ id = req.ifr_index; ++#endif + qt_safe_close(socket); + return id; + #else +@@ -155,7 +159,11 @@ QString QNetworkInterfaceManager::interf + int socket = qt_safe_socket(AF_INET, SOCK_STREAM, 0); + if (socket >= 0) { + memset(&req, 0, sizeof(ifreq)); ++#ifdef ifr_ifindex + req.ifr_ifindex = index; ++#else ++ req.ifr_index = index; ++#endif + + if (qt_safe_ioctl(socket, SIOCGIFNAME, &req) >= 0) { + qt_safe_close(socket); +@@ -232,10 +240,10 @@ static QNetworkInterfacePrivate *findInt + // Get the interface index + # ifdef SIOCGIFINDEX + if (qt_safe_ioctl(socket, SIOCGIFINDEX, &req) >= 0) +-# if defined(Q_OS_HAIKU) +- ifindex = req.ifr_index; +-# else ++# ifdef ifr_ifindex + ifindex = req.ifr_ifindex; ++# else ++ ifindex = req.ifr_index; + # endif + # else + ifindex = if_nametoindex(req.ifr_name); |