Blob Blame History Raw
%global unstable 0

Name:           kpmcore
Version:        2.2.0
Release:        2%{?dist}
Summary:        Library for managing partitions by KDE programs

# Due to package split, some files conflicts with kde-partitionmanager.
# This will be correct with the update of kde-partitionmanager to 1.9.50
# which depends on kpmcore.
Conflicts:      kde-partitionmanager <= 1.2.1-6

# Renaming from KPMcore to kpmcore
Provides: KPMcore = %{version}-%{release}
Obsoletes: KPMcore <= 2.0.0-2

License:        GPLv3+
URL:            https://github.com/KDE/kpmcore
%if 0%{?unstable}
Source0:        http://download.kde.org/unstable/%{name}/%{version}/src/%{name}-%{version}.tar.xz
%else
Source0:        http://download.kde.org/stable/%{name}/%{version}/src/%{name}-%{version}.tar.xz
%endif

BuildRequires:  cmake
BuildRequires:  extra-cmake-modules
BuildRequires:  gettext
BuildRequires:  kf5-ki18n-devel
BuildRequires:  kf5-kiconthemes-devel
BuildRequires:  kf5-kio-devel
BuildRequires:  qt5-qtbase-devel
BuildRequires:  kf5-rpm-macros

BuildRequires:  pkgconfig
BuildRequires:  pkgconfig(blkid)
BuildRequires:  pkgconfig(libatasmart)
BuildRequires:  pkgconfig(libparted)

Requires:       parted
Requires:       e2fsprogs
Requires:       kf5-filesystem

Recommends:     f2fs-tools
Recommends:     hfsutils
Recommends:     hfsplusutils
Recommends:     jfsutils
Recommends:     nilfs-utils
Recommends:     reiserfs-utils

%description
KPMcore contains common code for managing partitions by KDE Partition Manager 
and other KDE projects


%package        devel
Summary:        Development files for %{name}
Requires:       %{name}%{?_isa} = %{version}-%{release}
Requires:       qt5-qtbase-devel

# Renaming from KPMcore to kpmcore
Provides: KPMcore-devel = %{version}-%{release}
Obsoletes: KPMcore-devel <= 2.0.0-2

%description    devel
The %{name}-devel package contains libraries and header files for
developing applications that use %{name}


%prep
%autosetup

%build
mkdir -p %{_target_platform}
pushd %{_target_platform}
%{cmake_kf5} ..
popd

make %{?_smp_mflags} -C %{_target_platform}


%install
make install/fast -C %{_target_platform} DESTDIR=%{buildroot}
%find_lang %{name} --with-kde

%post -p /sbin/ldconfig

%postun -p /sbin/ldconfig


%files -f %{name}.lang
%license COPYING.GPL3
%{_kf5_libdir}/libkpmcore.so.*
%{_kf5_qtplugindir}/libpm*.so
%{_kf5_datadir}/kservices5/pm*backendplugin.desktop
%{_kf5_datadir}/kservicetypes5/pm*backendplugin.desktop

%files devel
%{_includedir}/%{name}/
%{_kf5_libdir}/cmake/KPMcore
%{_kf5_libdir}/libkpmcore.so



%changelog
* Sun Jun 12 2016 Mattia Verga <mattia.verga@tiscali.it> - 2.2.0-2
- Add weak dependencies to less used filesystem tools

* Sat Jun 11 2016 Mattia Verga <mattia.verga@tiscali.it> - 2.2.0-1
- Update to stable 2.2.0
- Soname bump to libkpmcore.so.3

* Sun May 15 2016 Mattia Verga <mattia.verga@tiscali.it> - 2.1.1-1
- Update to stable 2.1.1

* Sun Mar 13 2016 Mattia Verga <mattia.verga@tiscali.it> - 2.1.0-1
- Update to stable 2.1.0
- Use pkgconfig for libparted

* Sun Feb 28 2016 Mattia Verga <mattia.verga@tiscali.it> - 2.0.1-1
- Update to stable 2.0.1
- Use pkgconfig for libraries
- Alphabetically ordered BR
- Fix Provides and Obsoletes also for -devel package

* Thu Feb 04 2016 Fedora Release Engineering <releng@fedoraproject.org> - 2.0.0-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild

* Sat Jan 16 2016 Mattia Verga <mattia.verga@tiscali.it> - 2.0.0-2
- Rename from KPMcore to kpmcore

* Thu Jan 14 2016 Mattia Verga <mattia.verga@tiscali.it> - 2.0.0-1
- Update to stable 2.0.0

* Sun Nov 29 2015 Mattia Verga <mattia.verga@tiscali.it> - 1.9.50-5
- Fix package naming

* Sun Nov 29 2015 Mattia Verga <mattia.verga@tiscali.it> - 1.9.50-4
- Replace Obsoletes with Conflicts

* Wed Nov 25 2015 Mattia Verga <mattia.verga@tiscali.it> - 1.9.50-3
- Patch to fix soname versioning

* Mon Nov 23 2015 Mattia Verga <mattia.verga@tiscali.it> - 1.9.50-2
- Make a devel subpackage

* Sun Nov 22 2015 Mattia Verga <mattia.verga@tiscali.it> - 1.9.50-1
- Initial release