From 0699d22b7aa6dcb95e117f9b2264330b4853e826 Mon Sep 17 00:00:00 2001 From: Juergen Buchmueller Date: Fri, 28 Oct 2016 19:41:59 +0200 Subject: [PATCH] qbittorrent: fix cross --- .../files/cross-configure_ac.patch | 23 ++++++++++++++++ srcpkgs/qbittorrent/template | 26 ++++++++++++------- 2 files changed, 39 insertions(+), 10 deletions(-) create mode 100644 srcpkgs/qbittorrent/files/cross-configure_ac.patch diff --git a/srcpkgs/qbittorrent/files/cross-configure_ac.patch b/srcpkgs/qbittorrent/files/cross-configure_ac.patch new file mode 100644 index 00000000000..04a113d1c42 --- /dev/null +++ b/srcpkgs/qbittorrent/files/cross-configure_ac.patch @@ -0,0 +1,23 @@ +--- configure.ac 2016-09-11 21:24:45.000000000 +0200 ++++ configure.ac 2016-10-28 19:25:11.753180214 +0200 +@@ -121,20 +121,6 @@ + [AC_MSG_RESULT([$enable_webui]) + AC_MSG_ERROR([Unknown option "$enable_webui". Use either "yes" or "no".])]) + +-AC_MSG_CHECKING([whether Qt4 should be enabled]) +-AS_CASE(["x$with_qt4"], +- ["xno"], +- [AC_MSG_RESULT([no]) +- FIND_QT5()], +- ["xyes"], +- [AC_MSG_RESULT([yes]) +- FIND_QT4()], +- [AC_MSG_RESULT([$with_qt4]) +- AC_MSG_ERROR([Unknown option "$with_qt4". Use either "yes" or "no".])]) +-AS_IF([test "x$QT_QMAKE" = "x"], +- [AC_MSG_ERROR([Could not find qmake]) +- ]) +- + AC_MSG_CHECKING([whether QtDBus should be enabled]) + AS_CASE(["x$enable_qt_dbus"], + ["xyes"], diff --git a/srcpkgs/qbittorrent/template b/srcpkgs/qbittorrent/template index f6f71dc0cab..343d07f113b 100644 --- a/srcpkgs/qbittorrent/template +++ b/srcpkgs/qbittorrent/template @@ -1,18 +1,17 @@ # Template file for 'qbittorrent' pkgname=qbittorrent version=3.3.7 -revision=3 +revision=4 build_style=qmake -hostmakedepends="automake libtool pkg-config qt5-tools" -makedepends="boost-devel libtorrent-rasterbar-devel - qt5-declarative-devel qt5-devel qt5-qmake" +hostmakedepends="automake libtool pkg-config qt5-qmake qt5-tools + qt5-host-tools qt5-declarative-devel" +makedepends="libtorrent-rasterbar-devel qt5-declarative-devel" short_desc="Free software alternative to µtorrent" maintainer="Jürgen Buchmüller " license="GPL-2" homepage="http://www.qbittorrent.org/" distfiles="${SOURCEFORGE_SITE}/${pkgname}/${pkgname}-${version}.tar.xz" checksum=72dc824a90fadc0825e6be6f1c215e38f976262c7f83b625061d542b2b664c40 -nocross=yes build_options="gui webui" desc_option_gui="Enable the graphical user interface" @@ -20,9 +19,16 @@ desc_option_webui="Enable the web user interface" build_options_default="gui" pre_configure() { - ./configure --prefix=/usr \ - --disable-systemd \ - --with-qt5 \ - $(vopt_enable gui) \ - $(vopt_enable webui) + local _args + _args="--prefix=/usr" + _args+=" --with-qt4=no" + _args+=" --disable-systemd" + if [ -n "$CROSS_BUILD" ]; then + _args+=" --host=${XBPS_CROSS_TRIPLET}" + _args+=" --with-boost=${XBPS_CROSS_BASE}/usr" + patch -p0 < ${FILESDIR}/cross-configure_ac.patch + export QT_QMAKE=/usr/bin/qmake-qt5 + fi + ./bootstrap.sh + ./configure ${_args} $(vopt_enable gui) $(vopt_enable webui) }