From 81644deb3c6b278ff7de7450f29df9dedd9bc4bc Mon Sep 17 00:00:00 2001 From: Lubomir Rintel Date: Thu, 30 Nov 2017 10:42:04 +0100 Subject: [PATCH] Drop libnm-glib for Fedora 28 --- NetworkManager-l2tp.spec | 34 ++++++++++++++++++++++++++-------- 1 file changed, 26 insertions(+), 8 deletions(-) diff --git a/NetworkManager-l2tp.spec b/NetworkManager-l2tp.spec index cfbb524..ec30797 100644 --- a/NetworkManager-l2tp.spec +++ b/NetworkManager-l2tp.spec @@ -1,7 +1,14 @@ +%if 0%{?fedora} < 28 && 0%{?rhel} < 8 +%bcond_without libnm_glib +%else +# Disable the legacy version by default +%bcond_with libnm_glib +%endif + Summary: NetworkManager VPN plugin for L2TP and L2TP/IPsec Name: NetworkManager-l2tp Version: 1.2.8 -Release: 3%{?dist} +Release: 4%{?dist} License: GPLv2+ URL: https://github.com/nm-l2tp/network-manager-l2tp Source: https://github.com/nm-l2tp/network-manager-l2tp/archive/%{version}/%{name}-%{version}.tar.gz @@ -10,25 +17,27 @@ Source: https://github.com/nm-l2tp/network-manager-l2tp/archive/%{version}/%{ BuildRequires: gtk3-devel BuildRequires: NetworkManager-devel -BuildRequires: NetworkManager-glib-devel >= 1:1.2.0 BuildRequires: NetworkManager-libnm-devel >= 1:1.2.0 BuildRequires: glib2-devel BuildRequires: ppp-devel BuildRequires: libtool intltool gettext BuildRequires: libsecret-devel -BuildRequires: libnm-gtk-devel >= 1.2.0 BuildRequires: libnma-devel >= 1.2.0 BuildRequires: libsecret-devel +%if %with libnm_glib +BuildRequires: NetworkManager-glib-devel >= 1:1.2.0 +BuildRequires: libnm-gtk-devel >= 1.2.0 +%endif + Requires: dbus Requires: NetworkManager >= 1:1.2.0 Requires: ppp = %{ppp_version} Requires: xl2tpd Recommends: libreswan -%global _privatelibs libnm-l2tp-properties[.]so.* -%global __provides_exclude ^(%{_privatelibs})$ -%global __requires_exclude ^(%{_privatelibs})$ +%global __provides_exclude ^libnm-.*\\.so + %description This package contains software for integrating L2TP and L2TP over @@ -50,6 +59,9 @@ autoreconf -fi intltoolize %configure \ --disable-static \ +%if %without libnm_glib + --without-libnm-glib \ +%endif --with-pppd-plugin-dir=%{_libdir}/pppd/%{ppp_version} \ --with-dist-version=%{version}-%{release} make %{?_smp_mflags} @@ -76,14 +88,20 @@ rm -f %{buildroot}%{_libdir}/pppd/%{ppp_version}/*.la %files gnome %{_libexecdir}/nm-l2tp-auth-dialog -%{_libdir}/NetworkManager/libnm-*-properties.so %{_libdir}/NetworkManager/libnm-vpn-plugin-l2tp-editor.so %dir %{_datadir}/gnome-vpn-properties/l2tp %{_datadir}/gnome-vpn-properties/l2tp/nm-l2tp-dialog.ui -%{_sysconfdir}/NetworkManager/VPN/nm-l2tp-service.name %{_datadir}/appdata/network-manager-l2tp.metainfo.xml +%if %with libnm_glib +%{_sysconfdir}/NetworkManager/VPN/nm-l2tp-service.name +%{_libdir}/NetworkManager/libnm-*-properties.so +%endif + %changelog +* Thu Nov 30 2017 Lubomir Rintel - 1.2.8-4 +- Drop libnm-glib for Fedora 28 + * Wed Aug 02 2017 Fedora Release Engineering - 1.2.8-3 - Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Binutils_Mass_Rebuild