Rafael Sadowski writes:

> On Sun Jan 19, 2020 at 03:38:29PM -0800, Nam Nguyen wrote:
>> Here is a diff to update net/qbittorrent to 4.2.1, released on December
>> 17, 2019.
>> 
>> * Uses the proposed update to net/libtorrent-rasterbar 1.2.3 that moves
>>   to python 3 and proposed fix for devel/boost python 3 bindings.
>> * python 2 is an optional dependency used at runtime for this port for
>>   some runtime search plugin stuff among other things. I left it as is.
>> * Builds translations
>> * Regen WANTLIB
>> 
>> Changelog:
>> https://github.com/qbittorrent/qBittorrent/blob/118af03534e5ded6d3c8323b5dbeeff57b177193/Changelog
>> Feedback and tests are welcome.
>
> Thanks, see comments below.
>> +# compile translations
>> +pre-build:
>> +    @cd ${WRKBUILD}/src && make compiler_lrelease_make_all
>> +    @cd ${WRKBUILD}/src && make compiler_uic_make_all
>
> Please use: ${SETENV} ${MAKE_ENV} ${MAKE_PROGRAM} ${MAKE_FLAGS} -f
> Makefile compiler_lrelease_make_all instead pure make.

Investigating this revealed incorrect qmake/gmake behavior. src/Makefile
is generated by qmake. It contains include directives of the form:

-include .deps/app/application.d
-include .deps/app/applicationinstancemanager.d
-include .deps/app/cmdoptions.d

With the -include directives, gmake tries to compile files that depend
on the translations before the translations have been generated. It also
tries to compile files that depend on the generated src/ui_*.h before
they have been generated.

Here is an updated diff that removes all -include directives.

https://www.gnu.org/software/make/manual/html_node/Include.html

Index: Makefile.inc
===================================================================
RCS file: /cvs/ports/net/qbittorrent/Makefile.inc,v
retrieving revision 1.6
diff -u -p -r1.6 Makefile.inc
--- Makefile.inc        12 Jul 2019 20:48:47 -0000      1.6
+++ Makefile.inc        23 Jan 2020 04:48:58 -0000
@@ -1,6 +1,6 @@
 # $OpenBSD: Makefile.inc,v 1.6 2019/07/12 20:48:47 sthen Exp $
 
-VER =          4.1.5
+VER =          4.2.1
 DISTNAME =     qbittorrent-${VER}
 
 DIST_SUBDIR =  qbittorrent
Index: qbittorrent/Makefile
===================================================================
RCS file: /cvs/ports/net/qbittorrent/qbittorrent/Makefile,v
retrieving revision 1.7
diff -u -p -r1.7 Makefile
--- qbittorrent/Makefile        7 Nov 2019 17:40:36 -0000       1.7
+++ qbittorrent/Makefile        23 Jan 2020 04:48:58 -0000
@@ -1,10 +1,9 @@
 # $OpenBSD: Makefile,v 1.7 2019/11/07 17:40:36 fcambus Exp $
 
 COMMENT =              BitTorrent client with Qt interface
-REVISION =             2
 
 WANTLIB += ${COMPILER_LIBCXX} Qt5Core Qt5Network Qt5Xml boost_system
-WANTLIB += boost_system-mt c m torrent-rasterbar z
+WANTLIB += boost_system-mt c crypto m ssl torrent-rasterbar z
 WANTLIB += GL Qt5DBus Qt5Gui Qt5Svg Qt5Widgets
 
 LIB_DEPENDS +=         net/libtorrent-rasterbar \
@@ -14,6 +13,11 @@ LIB_DEPENDS +=               net/libtorrent-rasterbar
 RUN_DEPENDS +=         lang/python/2.7 \
                        x11/gtk+3,-guic \
                        devel/desktop-file-utils
+
+# remove include directives which cause incorrect gmake behavior
+pre-build:
+       @cd ${WRKBUILD}/src && \
+               sed -ie "/^\-include/d" Makefile
 
 pre-install:
        ${SUBST_CMD} ${WRKSRC}/conf.pri
Index: qbittorrent/distinfo
===================================================================
RCS file: /cvs/ports/net/qbittorrent/qbittorrent/distinfo,v
retrieving revision 1.4
diff -u -p -r1.4 distinfo
--- qbittorrent/distinfo        4 Jan 2019 22:20:49 -0000       1.4
+++ qbittorrent/distinfo        23 Jan 2020 04:48:58 -0000
@@ -1,2 +1,2 @@
-SHA256 (qbittorrent/qbittorrent-4.1.5.tar.gz) = 
SrEkunYL1T3XYP/O8CHjWUKIkjYH6BZAkwPAmNNzD6w=
-SIZE (qbittorrent/qbittorrent-4.1.5.tar.gz) = 7739271
+SHA256 (qbittorrent/qbittorrent-4.2.1.tar.gz) = 
/9wg388BBqlBroQiHkXuL5F36xjuxsD8ULJhVvC6MSY=
+SIZE (qbittorrent/qbittorrent-4.2.1.tar.gz) = 7843513
Index: qbittorrent/patches/patch-configure
===================================================================
RCS file: /cvs/ports/net/qbittorrent/qbittorrent/patches/patch-configure,v
retrieving revision 1.2
diff -u -p -r1.2 patch-configure
--- qbittorrent/patches/patch-configure 4 Jan 2019 22:20:49 -0000       1.2
+++ qbittorrent/patches/patch-configure 23 Jan 2020 04:48:58 -0000
@@ -3,7 +3,7 @@ $OpenBSD: patch-configure,v 1.2 2019/01/
 Index: configure
 --- configure.orig
 +++ configure
-@@ -5405,12 +5405,12 @@ if test -n "$zlib_CFLAGS"; then
+@@ -5478,12 +5478,12 @@ if test -n "$zlib_CFLAGS"; then
      pkg_cv_zlib_CFLAGS="$zlib_CFLAGS"
   elif test -n "$PKG_CONFIG"; then
      if test -n "$PKG_CONFIG" && \
@@ -19,7 +19,7 @@ Index: configure
                      test "x$?" != "x0" && pkg_failed=yes
  else
    pkg_failed=yes
-@@ -5422,12 +5422,12 @@ if test -n "$zlib_LIBS"; then
+@@ -5495,12 +5495,12 @@ if test -n "$zlib_LIBS"; then
      pkg_cv_zlib_LIBS="$zlib_LIBS"
   elif test -n "$PKG_CONFIG"; then
      if test -n "$PKG_CONFIG" && \
@@ -35,7 +35,7 @@ Index: configure
                      test "x$?" != "x0" && pkg_failed=yes
  else
    pkg_failed=yes
-@@ -5448,14 +5448,14 @@ else
+@@ -5521,14 +5521,14 @@ else
          _pkg_short_errors_supported=no
  fi
          if test $_pkg_short_errors_supported = yes; then
Index: qbittorrent/pkg/PLIST
===================================================================
RCS file: /cvs/ports/net/qbittorrent/qbittorrent/pkg/PLIST,v
retrieving revision 1.2
diff -u -p -r1.2 PLIST
--- qbittorrent/pkg/PLIST       28 Sep 2018 13:25:04 -0000      1.2
+++ qbittorrent/pkg/PLIST       23 Jan 2020 04:48:58 -0000
@@ -1,9 +1,9 @@
 @comment $OpenBSD: PLIST,v 1.2 2018/09/28 13:25:04 rsadowski Exp $
+@tag gtk-update-icon-cache %D/share/icons/hicolor
+@tag update-desktop-database
 @bin bin/qbittorrent
 @man man/man1/qbittorrent.1
-share/appdata/
-share/appdata/qbittorrent.appdata.xml
-share/applications/qbittorrent.desktop
+share/applications/org.qbittorrent.qBittorrent.desktop
 share/icons/hicolor/128x128/apps/qbittorrent.png
 share/icons/hicolor/128x128/status/qbittorrent-tray.png
 share/icons/hicolor/16x16/apps/qbittorrent.png
@@ -29,7 +29,7 @@ share/icons/hicolor/96x96/status/qbittor
 share/icons/hicolor/scalable/status/qbittorrent-tray-dark.svg
 share/icons/hicolor/scalable/status/qbittorrent-tray-light.svg
 share/icons/hicolor/scalable/status/qbittorrent-tray.svg
+share/metainfo/
+share/metainfo/org.qbittorrent.qBittorrent.appdata.xml
 share/pixmaps/
 share/pixmaps/qbittorrent.png
-@tag gtk-update-icon-cache %D/share/icons/hicolor
-@tag update-desktop-database
Index: qbittorrent-nox/Makefile
===================================================================
RCS file: /cvs/ports/net/qbittorrent/qbittorrent-nox/Makefile,v
retrieving revision 1.5
diff -u -p -r1.5 Makefile
--- qbittorrent-nox/Makefile    5 May 2019 15:44:13 -0000       1.5
+++ qbittorrent-nox/Makefile    23 Jan 2020 04:48:58 -0000
@@ -2,15 +2,19 @@
 
 COMMENT =              BitTorrent client with web interface
 PKGNAME =              qbittorrent-nox-${VER}
-REVISION =             1
 
 WANTLIB += ${COMPILER_LIBCXX} Qt5Core Qt5Network Qt5Xml boost_system
-WANTLIB += boost_system-mt c m torrent-rasterbar z
+WANTLIB += boost_system-mt c crypto m ssl torrent-rasterbar z
 
 LIB_DEPENDS +=         net/libtorrent-rasterbar \
                        devel/boost
 
 CONFIGURE_ARGS +=      --disable-gui
+
+# remove include directives which cause incorrect gmake behavior
+pre-build:
+       @cd ${WRKBUILD}/src && \
+               sed -ie "/^\-include/d" Makefile
 
 pre-install:
        ${SUBST_CMD} ${WRKSRC}/conf.pri
Index: qbittorrent-nox/distinfo
===================================================================
RCS file: /cvs/ports/net/qbittorrent/qbittorrent-nox/distinfo,v
retrieving revision 1.4
diff -u -p -r1.4 distinfo
--- qbittorrent-nox/distinfo    4 Jan 2019 22:20:49 -0000       1.4
+++ qbittorrent-nox/distinfo    23 Jan 2020 04:48:58 -0000
@@ -1,2 +1,2 @@
-SHA256 (qbittorrent/qbittorrent-4.1.5.tar.gz) = 
SrEkunYL1T3XYP/O8CHjWUKIkjYH6BZAkwPAmNNzD6w=
-SIZE (qbittorrent/qbittorrent-4.1.5.tar.gz) = 7739271
+SHA256 (qbittorrent/qbittorrent-4.2.1.tar.gz) = 
/9wg388BBqlBroQiHkXuL5F36xjuxsD8ULJhVvC6MSY=
+SIZE (qbittorrent/qbittorrent-4.2.1.tar.gz) = 7843513
Index: qbittorrent-nox/patches/patch-configure
===================================================================
RCS file: /cvs/ports/net/qbittorrent/qbittorrent-nox/patches/patch-configure,v
retrieving revision 1.2
diff -u -p -r1.2 patch-configure
--- qbittorrent-nox/patches/patch-configure     4 Jan 2019 22:20:49 -0000       
1.2
+++ qbittorrent-nox/patches/patch-configure     23 Jan 2020 04:48:58 -0000
@@ -3,7 +3,7 @@ $OpenBSD: patch-configure,v 1.2 2019/01/
 Index: configure
 --- configure.orig
 +++ configure
-@@ -5405,12 +5405,12 @@ if test -n "$zlib_CFLAGS"; then
+@@ -5478,12 +5478,12 @@ if test -n "$zlib_CFLAGS"; then
      pkg_cv_zlib_CFLAGS="$zlib_CFLAGS"
   elif test -n "$PKG_CONFIG"; then
      if test -n "$PKG_CONFIG" && \
@@ -19,7 +19,7 @@ Index: configure
                      test "x$?" != "x0" && pkg_failed=yes
  else
    pkg_failed=yes
-@@ -5422,12 +5422,12 @@ if test -n "$zlib_LIBS"; then
+@@ -5495,12 +5495,12 @@ if test -n "$zlib_LIBS"; then
      pkg_cv_zlib_LIBS="$zlib_LIBS"
   elif test -n "$PKG_CONFIG"; then
      if test -n "$PKG_CONFIG" && \
@@ -35,7 +35,7 @@ Index: configure
                      test "x$?" != "x0" && pkg_failed=yes
  else
    pkg_failed=yes
-@@ -5448,14 +5448,14 @@ else
+@@ -5521,14 +5521,14 @@ else
          _pkg_short_errors_supported=no
  fi
          if test $_pkg_short_errors_supported = yes; then

Reply via email to