diff options
author | Andreas Sturmlechner <andreas.sturmlechner@gmail.com> | 2016-10-09 15:05:13 +0200 |
---|---|---|
committer | Michael Palimaka <kensington@gentoo.org> | 2016-10-10 02:50:21 +1100 |
commit | 79f0cc6cde1905da4564a20fd1320df470774994 (patch) | |
tree | 29d8b01d00f2ef94738fee93826ab6e63b8a0c43 /kde-frameworks | |
parent | sci-libs/cblas-reference: fix eselect symlnk to pc file (diff) | |
download | gentoo-79f0cc6cde1905da4564a20fd1320df470774994.tar.gz gentoo-79f0cc6cde1905da4564a20fd1320df470774994.tar.bz2 gentoo-79f0cc6cde1905da4564a20fd1320df470774994.zip |
kde-frameworks/networkmanager-qt: More fixes for NM-1.4.0
Let's install kde-frameworks/networkmanager-qt-5.27.0 behind the scenes.
Package-Manager: portage-2.3.0
Diffstat (limited to 'kde-frameworks')
3 files changed, 153 insertions, 0 deletions
diff --git a/kde-frameworks/networkmanager-qt/files/networkmanager-qt-5.27.0-tests.patch b/kde-frameworks/networkmanager-qt/files/networkmanager-qt-5.27.0-tests.patch new file mode 100644 index 000000000000..0d4d9bf67443 --- /dev/null +++ b/kde-frameworks/networkmanager-qt/files/networkmanager-qt-5.27.0-tests.patch @@ -0,0 +1,111 @@ +commit cc9d198676e8c8afae9e55286bd401f40634ce6b +Author: Jan Grulich <jgrulich@redhat.com> +Date: Wed Oct 5 11:46:01 2016 +0200 + + Fix unit tests + + In case we build against NetworkManager 1.4.x, we have to avoid using + o.f.DBus.Properties interface for monitoring property changes, because + our FakeNetwork doesn't support that yet. + + BUG:369881 + +diff --git a/src/activeconnection.cpp b/src/activeconnection.cpp +index 6601d74..22ab7d0 100644 +--- a/src/activeconnection.cpp ++++ b/src/activeconnection.cpp +@@ -66,12 +66,19 @@ NetworkManager::ActiveConnection::ActiveConnection(const QString &path, QObject + d->propertiesChanged(initialProperties); + } + ++#ifndef NMQT_STATIC + #if NM_CHECK_VERSION(1, 4, 0) + QDBusConnection::systemBus().connect(NetworkManagerPrivate::DBUS_SERVICE, d->path, NetworkManagerPrivate::FDO_DBUS_PROPERTIES, + QLatin1String("PropertiesChanged"), d, SLOT(dbusPropertiesChanged(QString,QVariantMap,QStringList))); + #else + connect(&d->iface, &OrgFreedesktopNetworkManagerConnectionActiveInterface::PropertiesChanged, d, &ActiveConnectionPrivate::propertiesChanged); + #endif ++#endif ++ ++#ifdef NMQT_STATIC ++ connect(&d->iface, &OrgFreedesktopNetworkManagerConnectionActiveInterface::PropertiesChanged, d, &ActiveConnectionPrivate::propertiesChanged); ++#endif ++ + /* + * Workaround: Re-check connection state before we watch changes in case it gets changed too quickly + * BUG:352326 +diff --git a/src/manager.cpp b/src/manager.cpp +index 4cd3353..6565299 100644 +--- a/src/manager.cpp ++++ b/src/manager.cpp +@@ -97,6 +97,9 @@ NetworkManager::NetworkManagerPrivate::NetworkManagerPrivate() + this, &NetworkManagerPrivate::onDeviceAdded); + connect(&iface, &OrgFreedesktopNetworkManagerInterface::DeviceRemoved, + this, &NetworkManagerPrivate::onDeviceRemoved); ++ ++ ++#ifndef NMQT_STATIC + #if NM_CHECK_VERSION(1, 4, 0) + QDBusConnection::systemBus().connect(NetworkManagerPrivate::DBUS_SERVICE, NetworkManagerPrivate::DBUS_DAEMON_PATH, NetworkManagerPrivate::FDO_DBUS_PROPERTIES, + QLatin1String("PropertiesChanged"), this, SLOT(dbusPropertiesChanged(QString,QVariantMap,QStringList))); +@@ -104,6 +107,13 @@ NetworkManager::NetworkManagerPrivate::NetworkManagerPrivate() + connect(&iface, &OrgFreedesktopNetworkManagerInterface::PropertiesChanged, + this, &NetworkManagerPrivate::propertiesChanged); + #endif ++#endif ++ ++#ifdef NMQT_STATIC ++ connect(&iface, &OrgFreedesktopNetworkManagerInterface::PropertiesChanged, ++ this, &NetworkManagerPrivate::propertiesChanged); ++#endif ++ + connect(&watcher, &QDBusServiceWatcher::serviceRegistered, + this, &NetworkManagerPrivate::daemonRegistered); + connect(&watcher, &QDBusServiceWatcher::serviceUnregistered, +diff --git a/src/wireddevice.cpp b/src/wireddevice.cpp +index 8e66299..e64492f 100644 +--- a/src/wireddevice.cpp ++++ b/src/wireddevice.cpp +@@ -53,12 +53,18 @@ NetworkManager::WiredDevice::WiredDevice(const QString &path, QObject *parent) + d->propertiesChanged(initialProperties); + } + ++#ifndef NMQT_STATIC + #if NM_CHECK_VERSION(1, 4, 0) + QDBusConnection::systemBus().connect(NetworkManagerPrivate::DBUS_SERVICE, d->uni, NetworkManagerPrivate::FDO_DBUS_PROPERTIES, + QLatin1String("PropertiesChanged"), d, SLOT(dbusPropertiesChanged(QString,QVariantMap,QStringList))); + #else + connect(&d->wiredIface, &OrgFreedesktopNetworkManagerDeviceWiredInterface::PropertiesChanged, d, &WiredDevicePrivate::propertiesChanged); + #endif ++#endif ++ ++#ifdef NMQT_STATIC ++ connect(&d->wiredIface, &OrgFreedesktopNetworkManagerDeviceWiredInterface::PropertiesChanged, d, &WiredDevicePrivate::propertiesChanged); ++#endif + } + + NetworkManager::WiredDevice::~WiredDevice() +diff --git a/src/wirelessdevice.cpp b/src/wirelessdevice.cpp +index 1f47c28..10c47da 100644 +--- a/src/wirelessdevice.cpp ++++ b/src/wirelessdevice.cpp +@@ -66,12 +66,19 @@ NetworkManager::WirelessDevice::WirelessDevice(const QString &path, QObject *par + d->propertiesChanged(initialProperties); + } + ++#ifndef NMQT_STATIC + #if NM_CHECK_VERSION(1, 4, 0) + QDBusConnection::systemBus().connect(NetworkManagerPrivate::DBUS_SERVICE, d->uni, NetworkManagerPrivate::FDO_DBUS_PROPERTIES, + QLatin1String("PropertiesChanged"), d, SLOT(dbusPropertiesChanged(QString,QVariantMap,QStringList))); + #else + connect(&d->wirelessIface, &OrgFreedesktopNetworkManagerDeviceWirelessInterface::PropertiesChanged, d, &WirelessDevicePrivate::propertiesChanged); + #endif ++#endif ++ ++#ifdef NMQT_STATIC ++ connect(&d->wirelessIface, &OrgFreedesktopNetworkManagerDeviceWirelessInterface::PropertiesChanged, d, &WirelessDevicePrivate::propertiesChanged); ++#endif ++ + connect(&d->wirelessIface, &OrgFreedesktopNetworkManagerDeviceWirelessInterface::AccessPointAdded, d, &WirelessDevicePrivate::accessPointAdded); + connect(&d->wirelessIface, &OrgFreedesktopNetworkManagerDeviceWirelessInterface::AccessPointRemoved, d, &WirelessDevicePrivate::accessPointRemoved); + } diff --git a/kde-frameworks/networkmanager-qt/networkmanager-qt-5.26.0-r2.ebuild b/kde-frameworks/networkmanager-qt/networkmanager-qt-5.26.0-r2.ebuild new file mode 100644 index 000000000000..06f8c672c253 --- /dev/null +++ b/kde-frameworks/networkmanager-qt/networkmanager-qt-5.26.0-r2.ebuild @@ -0,0 +1,40 @@ +# Copyright 1999-2016 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Id$ + +EAPI=6 + +MY_PV="5.27.0" +inherit kde5 + +DESCRIPTION="NetworkManager bindings for Qt" +SRC_URI="mirror://kde/stable/frameworks/${MY_PV%.0}/${PN}-${MY_PV}.tar.xz" + +LICENSE="LGPL-2" +KEYWORDS="~amd64 ~arm ~x86" +IUSE="teamd" + +COMMON_DEPEND=" + $(add_qt_dep qtdbus) + $(add_qt_dep qtnetwork) + || ( + >=net-misc/networkmanager-1.4.0-r1[consolekit,teamd=] + >=net-misc/networkmanager-1.4.0-r1[systemd,teamd=] + ) +" +DEPEND="${COMMON_DEPEND} + virtual/pkgconfig +" +RDEPEND="${COMMON_DEPEND} + !net-libs/libnm-qt:5 +" + +S="${WORKDIR}/${PN}-${MY_PV}" + +PATCHES=( "${FILESDIR}/${PN}-5.27.0-tests.patch" ) + +src_prepare(){ + sed -e "s/${MY_PV}/${PV}/" \ + -i CMakeLists.txt || die "Failed to lower ECM version requirement" + kde5_src_prepare +} diff --git a/kde-frameworks/networkmanager-qt/networkmanager-qt-5.27.0.ebuild b/kde-frameworks/networkmanager-qt/networkmanager-qt-5.27.0.ebuild index 1696e349de28..9cd96e8a4af1 100644 --- a/kde-frameworks/networkmanager-qt/networkmanager-qt-5.27.0.ebuild +++ b/kde-frameworks/networkmanager-qt/networkmanager-qt-5.27.0.ebuild @@ -25,3 +25,5 @@ DEPEND="${COMMON_DEPEND} RDEPEND="${COMMON_DEPEND} !net-libs/libnm-qt:5 " + +PATCHES=( "${FILESDIR}/${PN}-5.27.0-tests.patch" ) |