From owner-svn-ports-head@freebsd.org Sun Jan 7 21:53:16 2018 Return-Path: Delivered-To: svn-ports-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 90A34E60A9B; Sun, 7 Jan 2018 21:53:16 +0000 (UTC) (envelope-from rakuco@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "mxrelay.nyi.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 536FB7AB2B; Sun, 7 Jan 2018 21:53:16 +0000 (UTC) (envelope-from rakuco@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 9C5EC26DF2; Sun, 7 Jan 2018 21:53:15 +0000 (UTC) (envelope-from rakuco@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id w07LrF2O081939; Sun, 7 Jan 2018 21:53:15 GMT (envelope-from rakuco@FreeBSD.org) Received: (from rakuco@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id w07LrFbr081938; Sun, 7 Jan 2018 21:53:15 GMT (envelope-from rakuco@FreeBSD.org) Message-Id: <201801072153.w07LrFbr081938@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: rakuco set sender to rakuco@FreeBSD.org using -f From: Raphael Kubo da Costa Date: Sun, 7 Jan 2018 21:53:15 +0000 (UTC) To: ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org Subject: svn commit: r458386 - head/x11-toolkits/qt4-gui/files X-SVN-Group: ports-head X-SVN-Commit-Author: rakuco X-SVN-Commit-Paths: head/x11-toolkits/qt4-gui/files X-SVN-Commit-Revision: 458386 X-SVN-Commit-Repository: ports MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-ports-head@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: SVN commit messages for the ports tree for head List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 07 Jan 2018 21:53:16 -0000 Author: rakuco Date: Sun Jan 7 21:53:15 2018 New Revision: 458386 URL: https://svnweb.freebsd.org/changeset/ports/458386 Log: Fix the build on i386 with clang 6.0. kernel/qx11embed_x11.cpp:486:20: error: non-constant-expression cannot be narrowed from type 'unsigned int' to 'long' in initializer list [-Wc++11-narrowing] long data[] = {XEMBED_VERSION, XEMBED_MAPPED}; ^~~~~~~~~~~~~~ kernel/qx11embed_x11.cpp:486:20: note: insert an explicit cast to silence this issue long data[] = {XEMBED_VERSION, XEMBED_MAPPED}; ^~~~~~~~~~~~~~ static_cast( ) PR: 224945 Added: head/x11-toolkits/qt4-gui/files/ head/x11-toolkits/qt4-gui/files/patch-src_gui_kernel_qx11embed__x11.cpp (contents, props changed) Added: head/x11-toolkits/qt4-gui/files/patch-src_gui_kernel_qx11embed__x11.cpp ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/x11-toolkits/qt4-gui/files/patch-src_gui_kernel_qx11embed__x11.cpp Sun Jan 7 21:53:15 2018 (r458386) @@ -0,0 +1,48 @@ +Fixes the build on i386 with clang 6.0: + +kernel/qx11embed_x11.cpp:486:20: error: non-constant-expression cannot be narrowed from type 'unsigned int' to 'long' in initializer list [-Wc++11-narrowing] + long data[] = {XEMBED_VERSION, XEMBED_MAPPED}; + ^~~~~~~~~~~~~~ +kernel/qx11embed_x11.cpp:486:20: note: insert an explicit cast to silence this issue + long data[] = {XEMBED_VERSION, XEMBED_MAPPED}; + ^~~~~~~~~~~~~~ + static_cast( ) + +--- src/gui/kernel/qx11embed_x11.cpp.orig 2018-01-07 21:44:01 UTC ++++ src/gui/kernel/qx11embed_x11.cpp +@@ -275,7 +275,7 @@ class QHackWidget : public QWidget (public) + QTLWExtra* topData() { return d_func()->topData(); } + }; + +-static unsigned int XEMBED_VERSION = 0; ++static quint32 XEMBED_VERSION = 0; + + enum QX11EmbedMessageType { + XEMBED_EMBEDDED_NOTIFY = 0, +@@ -483,7 +483,7 @@ QX11EmbedWidget::QX11EmbedWidget(QWidget *parent) + | ExposureMask | StructureNotifyMask + | SubstructureNotifyMask | PropertyChangeMask); + +- long data[] = {XEMBED_VERSION, XEMBED_MAPPED}; ++ quint32 data[] = {XEMBED_VERSION, XEMBED_MAPPED}; + XChangeProperty(x11Info().display(), internalWinId(), ATOM(_XEMBED_INFO), + ATOM(_XEMBED_INFO), 32, PropModeReplace, + (unsigned char*) data, 2); +@@ -1578,7 +1578,7 @@ void QX11EmbedContainer::showEvent(QShowEvent *) + { + Q_D(QX11EmbedContainer); + if (d->client) { +- long data[] = {XEMBED_VERSION, XEMBED_MAPPED}; ++ quint32 data[] = {XEMBED_VERSION, XEMBED_MAPPED}; + XChangeProperty(x11Info().display(), d->client, ATOM(_XEMBED_INFO), ATOM(_XEMBED_INFO), 32, + PropModeReplace, (unsigned char *) data, 2); + } +@@ -1594,7 +1594,7 @@ void QX11EmbedContainer::hideEvent(QHideEvent *) + { + Q_D(QX11EmbedContainer); + if (d->client) { +- long data[] = {XEMBED_VERSION, XEMBED_MAPPED}; ++ quint32 data[] = {XEMBED_VERSION, XEMBED_MAPPED}; + XChangeProperty(x11Info().display(), d->client, ATOM(_XEMBED_INFO), ATOM(_XEMBED_INFO), 32, + PropModeReplace, (unsigned char *) data, 2); + }