From owner-svn-ports-head@freebsd.org Mon Nov 26 21:20:40 2018 Return-Path: Delivered-To: svn-ports-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 552081144C07; Mon, 26 Nov 2018 21:20:40 +0000 (UTC) (envelope-from adridg@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 E991D6B7D6; Mon, 26 Nov 2018 21:20:39 +0000 (UTC) (envelope-from adridg@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 CB81D1163E; Mon, 26 Nov 2018 21:20:39 +0000 (UTC) (envelope-from adridg@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id wAQLKdPI033048; Mon, 26 Nov 2018 21:20:39 GMT (envelope-from adridg@FreeBSD.org) Received: (from adridg@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id wAQLKbjd033038; Mon, 26 Nov 2018 21:20:37 GMT (envelope-from adridg@FreeBSD.org) Message-Id: <201811262120.wAQLKbjd033038@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: adridg set sender to adridg@FreeBSD.org using -f From: Adriaan de Groot Date: Mon, 26 Nov 2018 21:20:37 +0000 (UTC) To: ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org Subject: svn commit: r485966 - in head/misc/qbrew: . files X-SVN-Group: ports-head X-SVN-Commit-Author: adridg X-SVN-Commit-Paths: in head/misc/qbrew: . files X-SVN-Commit-Revision: 485966 X-SVN-Commit-Repository: ports MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Rspamd-Queue-Id: E991D6B7D6 X-Spamd-Result: default: False [1.84 / 15.00]; local_wl_from(0.00)[FreeBSD.org]; NEURAL_SPAM_LONG(0.68)[0.678,0]; NEURAL_SPAM_MEDIUM(0.65)[0.649,0]; NEURAL_SPAM_SHORT(0.52)[0.518,0] X-Rspamd-Server: mx1.freebsd.org X-BeenThere: svn-ports-head@freebsd.org X-Mailman-Version: 2.1.29 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: Mon, 26 Nov 2018 21:20:40 -0000 Author: adridg Date: Mon Nov 26 21:20:37 2018 New Revision: 485966 URL: https://svnweb.freebsd.org/changeset/ports/485966 Log: Port misc/qbrew away from Qt4 to Qt5. While at it, assume maintainership. This was discussed over email with David. Upstream is unmaintained, but it works with these minor patches. Added: head/misc/qbrew/files/patch-src_beerxmlreader.cpp (contents, props changed) head/misc/qbrew/files/patch-src_databasetool.cpp (contents, props changed) head/misc/qbrew/files/patch-src_grainmodel.cpp (contents, props changed) head/misc/qbrew/files/patch-src_hopmodel.cpp (contents, props changed) head/misc/qbrew/files/patch-src_miscmodel.cpp (contents, props changed) head/misc/qbrew/files/patch-src_qbrew.cpp (contents, props changed) head/misc/qbrew/files/patch-src_stylemodel.cpp (contents, props changed) head/misc/qbrew/files/patch-src_view.cpp (contents, props changed) Modified: head/misc/qbrew/Makefile head/misc/qbrew/files/patch-qbrew.pro Modified: head/misc/qbrew/Makefile ============================================================================== --- head/misc/qbrew/Makefile Mon Nov 26 20:29:01 2018 (r485965) +++ head/misc/qbrew/Makefile Mon Nov 26 21:20:37 2018 (r485966) @@ -3,18 +3,20 @@ PORTNAME= qbrew PORTVERSION= 0.4.1 -PORTREVISION= 4 +PORTREVISION= 5 CATEGORIES= misc MASTER_SITES= http://www.usermode.org/code/ -MAINTAINER= david@usermode.org +MAINTAINER= adridg@FreeBSD.org COMMENT= Homebrewer's recipe calculator -BROKEN= fails to build +LICENSE= BSD2CLAUSE +LICENSE_FILE= ${WRKSRC}/LICENSE -USES= qmake qt:4 -USE_QT= moc_build uic_build rcc_build xml gui -PORTDOCS= * +USES= qmake qt:5 +USE_GL= gl +USE_QT= buildtools_build qmake_build \ + core gui printsupport widgets xml QMAKE_ARGS= CONFIG+="configure" QMAKE_ENV+= BINDIR="${PREFIX}/bin" \ @@ -22,6 +24,8 @@ QMAKE_ENV+= BINDIR="${PREFIX}/bin" \ DOCDIR="${DOCSDIR}" OPTIONS_DEFINE= DOCS + +PORTDOCS= * post-install: ${STRIP_CMD} ${STAGEDIR}${PREFIX}/bin/qbrew Modified: head/misc/qbrew/files/patch-qbrew.pro ============================================================================== --- head/misc/qbrew/files/patch-qbrew.pro Mon Nov 26 20:29:01 2018 (r485965) +++ head/misc/qbrew/files/patch-qbrew.pro Mon Nov 26 21:20:37 2018 (r485966) @@ -1,10 +1,24 @@ ---- qbrew.pro.org 2008-05-25 22:35:35.000000000 -0700 -+++ qbrew.pro 2008-05-25 22:35:44.000000000 -0700 +Q_WS_* is deprecated. Rather than editing the code, just +convince ourselves that on BSD, we would still be using X11. + + https://www.kdab.com/porting-from-qt-4-to-qt-5/ + +--- qbrew.pro.orig 2008-05-26 02:21:05 UTC ++++ qbrew.pro @@ -6,6 +6,7 @@ TARGET = qbrew TEMPLATE = app CONFIG += qt warn_on -+QT += xml - ++QT += printsupport widgets xml + MOC_DIR = build OBJECTS_DIR = build +@@ -72,6 +73,8 @@ unix:!macx { + doc.path = /usr/local/share/doc/qbrew + } + ++ DEFINES += Q_WS_X11 ++ + trans.files = translations/*.qm + data.files = data/* pics/splash.png + doc.files = docs/book/*.html docs/primer/*.html README LICENSE Added: head/misc/qbrew/files/patch-src_beerxmlreader.cpp ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/misc/qbrew/files/patch-src_beerxmlreader.cpp Mon Nov 26 21:20:37 2018 (r485966) @@ -0,0 +1,13 @@ +false no longer implicitly converts via integer. Return empty recipe. + +--- src/beerxmlreader.cpp.orig 2018-11-26 11:43:40 UTC ++++ src/beerxmlreader.cpp +@@ -254,7 +254,7 @@ Recipe BeerXmlReader::readSingleRecipe() + } + if (hasError()) { + raiseError("Problem reading recipe"); +- return false; ++ return Recipe(0); + } + + // set grain use according to recipe type Added: head/misc/qbrew/files/patch-src_databasetool.cpp ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/misc/qbrew/files/patch-src_databasetool.cpp Mon Nov 26 21:20:37 2018 (r485966) @@ -0,0 +1,40 @@ +QHeaderView API change. + +--- src/databasetool.cpp.orig 2018-11-26 11:45:00 UTC ++++ src/databasetool.cpp +@@ -65,7 +65,7 @@ DatabaseTool::DatabaseTool(QWidget* pare + + grainpage.view->verticalHeader()->setDefaultSectionSize(mh); + grainpage.view->verticalHeader()->hide(); +- grainpage.view->horizontalHeader()->setClickable(true); ++ grainpage.view->horizontalHeader()->setSectionsClickable(true); + grainpage.view->horizontalHeader()->setHighlightSections(false); + + grainpage.view->setColumnWidth(GrainModel::NAME, 20*mw); +@@ -88,7 +88,7 @@ DatabaseTool::DatabaseTool(QWidget* pare + + hoppage.view->verticalHeader()->setDefaultSectionSize(mh); + hoppage.view->verticalHeader()->hide(); +- hoppage.view->horizontalHeader()->setClickable(true); ++ hoppage.view->horizontalHeader()->setSectionsClickable(true); + hoppage.view->horizontalHeader()->setHighlightSections(false); + + hoppage.view->setColumnHidden(HopModel::WEIGHT, true); +@@ -110,7 +110,7 @@ DatabaseTool::DatabaseTool(QWidget* pare + + miscpage.view->verticalHeader()->setDefaultSectionSize(mh); + miscpage.view->verticalHeader()->hide(); +- miscpage.view->horizontalHeader()->setClickable(true); ++ miscpage.view->horizontalHeader()->setSectionsClickable(true); + miscpage.view->horizontalHeader()->setHighlightSections(false); + + miscpage.view->setColumnHidden(MiscModel::QUANTITY, true); +@@ -131,7 +131,7 @@ DatabaseTool::DatabaseTool(QWidget* pare + + stylepage.view->verticalHeader()->setDefaultSectionSize(mh); + stylepage.view->verticalHeader()->hide(); +- stylepage.view->horizontalHeader()->setClickable(true); ++ stylepage.view->horizontalHeader()->setSectionsClickable(true); + stylepage.view->horizontalHeader()->setHighlightSections(false); + + stylepage.view->setColumnWidth(StyleModel::NAME, 20*mw); Added: head/misc/qbrew/files/patch-src_grainmodel.cpp ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/misc/qbrew/files/patch-src_grainmodel.cpp Mon Nov 26 21:20:37 2018 (r485966) @@ -0,0 +1,14 @@ +QAbstractItemModel API change + +--- src/grainmodel.cpp.orig 2018-11-26 11:49:13 UTC ++++ src/grainmodel.cpp +@@ -38,7 +38,8 @@ GrainModel::~GrainModel(){} + + void GrainModel::flush() + { +- reset(); ++ beginResetModel(); ++ endResetModel(); + } + + ////////////////////////////////////////////////////////////////////////////// Added: head/misc/qbrew/files/patch-src_hopmodel.cpp ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/misc/qbrew/files/patch-src_hopmodel.cpp Mon Nov 26 21:20:37 2018 (r485966) @@ -0,0 +1,14 @@ +QAbstractItemModel API change + +--- src/hopmodel.cpp.orig 2018-11-26 11:54:52 UTC ++++ src/hopmodel.cpp +@@ -34,7 +34,8 @@ HopModel::~HopModel() {} + + void HopModel::flush() + { +- reset(); ++ beginResetModel(); ++ endResetModel(); + } + + ////////////////////////////////////////////////////////////////////////////// Added: head/misc/qbrew/files/patch-src_miscmodel.cpp ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/misc/qbrew/files/patch-src_miscmodel.cpp Mon Nov 26 21:20:37 2018 (r485966) @@ -0,0 +1,14 @@ +QAbstractItemModel API change + +--- src/miscmodel.cpp.orig 2018-11-26 11:55:17 UTC ++++ src/miscmodel.cpp +@@ -34,7 +34,8 @@ MiscModel::~MiscModel() {} + + void MiscModel::flush() + { +- reset(); ++ beginResetModel(); ++ endResetModel(); + } + + ////////////////////////////////////////////////////////////////////////////// Added: head/misc/qbrew/files/patch-src_qbrew.cpp ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/misc/qbrew/files/patch-src_qbrew.cpp Mon Nov 26 21:20:37 2018 (r485966) @@ -0,0 +1,17 @@ +Missing includes, these live in QtWidgets now. + +--- src/qbrew.cpp.orig 2018-11-26 11:56:17 UTC ++++ src/qbrew.cpp +@@ -9,6 +9,12 @@ + + #include + ++#include ++#include ++#include ++#include ++#include ++ + #include "alcoholtool.h" + #include "configure.h" + #include "data.h" Added: head/misc/qbrew/files/patch-src_stylemodel.cpp ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/misc/qbrew/files/patch-src_stylemodel.cpp Mon Nov 26 21:20:37 2018 (r485966) @@ -0,0 +1,14 @@ +QAbstractItemModel API change. + +--- src/stylemodel.cpp.orig 2018-11-26 11:58:44 UTC ++++ src/stylemodel.cpp +@@ -34,7 +34,8 @@ StyleModel::~StyleModel(){} + + void StyleModel::flush() + { +- reset(); ++ beginResetModel(); ++ endResetModel(); + } + + ////////////////////////////////////////////////////////////////////////////// Added: head/misc/qbrew/files/patch-src_view.cpp ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/misc/qbrew/files/patch-src_view.cpp Mon Nov 26 21:20:37 2018 (r485966) @@ -0,0 +1,31 @@ +QHeaderView API change + +--- src/view.cpp.orig 2018-11-26 11:59:12 UTC ++++ src/view.cpp +@@ -72,7 +72,7 @@ View::View(QWidget *parent, Recipe *reci + + grainpage.view->verticalHeader()->setDefaultSectionSize(mh); + grainpage.view->verticalHeader()->hide(); +- grainpage.view->horizontalHeader()->setClickable(true); ++ grainpage.view->horizontalHeader()->setSectionsClickable(true); + grainpage.view->horizontalHeader()->setHighlightSections(false); + + grainpage.view->setColumnWidth(GrainModel::NAME, 20*mw); +@@ -94,7 +94,7 @@ View::View(QWidget *parent, Recipe *reci + + hoppage.view->verticalHeader()->setDefaultSectionSize(mh); + hoppage.view->verticalHeader()->hide(); +- hoppage.view->horizontalHeader()->setClickable(true); ++ hoppage.view->horizontalHeader()->setSectionsClickable(true); + hoppage.view->horizontalHeader()->setHighlightSections(false); + + hoppage.view->setColumnWidth(HopModel::NAME, 20*mw); +@@ -115,7 +115,7 @@ View::View(QWidget *parent, Recipe *reci + + miscpage.view->verticalHeader()->setDefaultSectionSize(mh); + miscpage.view->verticalHeader()->hide(); +- miscpage.view->horizontalHeader()->setClickable(true); ++ miscpage.view->horizontalHeader()->setSectionsClickable(true); + miscpage.view->horizontalHeader()->setHighlightSections(false); + + miscpage.view->setColumnWidth(MiscModel::NAME, 20*mw);