File qtkeychain-qt5.spec of Package qtkeychain-qt6

#
# spec file for package qtkeychain-qt5
#
# Copyright (c) 2022 SUSE LLC
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.

# Please submit bugfixes or comments via https://bugs.opensuse.org/
#


%define sover 1
Name:           qtkeychain-qt5
Version:        0.13.2
Release:        0
Summary:        A password store library
License:        BSD-2-Clause
Group:          Development/Libraries/C and C++
URL:            https://github.com/frankosterfeld/qtkeychain
Source:         https://github.com/frankosterfeld/qtkeychain/archive/v%{version}.tar.gz#/%{name}-%{version}.tar.gz
# PATCH-FIX-UPSTREAM
Patch0:         0001-Define-a-poper-exported-CMake-target-instead-of-intr.patch
BuildRequires:  cmake
BuildRequires:  pkgconfig
BuildRequires:  cmake(Qt5Core)
BuildRequires:  cmake(Qt5DBus)
BuildRequires:  cmake(Qt5LinguistTools)
BuildRequires:  pkgconfig(libsecret-1)

%description
qtkeychain can be used to store passwords.

%package -n libqt5keychain%{sover}
Summary:        A password store library
Group:          System/Libraries
Recommends:     libqt5keychain%{sover}-lang

%description -n libqt5keychain%{sover}
qtkeychain can be used to store passwords.

%package devel
Summary:        Development files for the qtkeychain library
Group:          Development/Libraries/C and C++
Requires:       libqt5keychain%{sover} = %{version}

%description devel
qtkeychain can be used to store passwords.

This package contains development files for libqtkeychain.

%lang_package -n libqt5keychain%{sover}

%prep
%autosetup -p1 -n qtkeychain-%{version}

%build
%cmake -DBUILD_TEST_APPLICATION=OFF ..
%cmake_build

%install
%cmake_install
%find_lang qtkeychain --with-qt

%post -n libqt5keychain%{sover} -p /sbin/ldconfig
%postun -n libqt5keychain%{sover} -p /sbin/ldconfig

%files -n libqt5keychain%{sover}
%license COPYING
%{_libdir}/libqt5keychain.so.%{sover}
%{_libdir}/libqt5keychain.so.%{version}

%files devel
%license COPYING
%{_includedir}/qt5keychain
%{_libdir}/cmake/Qt5Keychain
%{_libdir}/libqt5keychain.so
%{_libdir}/qt5/mkspecs/modules/qt_Qt5Keychain.pri

%files -n libqt5keychain%{sover}-lang -f qtkeychain.lang
%license COPYING
%dir %{_datadir}/qt5keychain
%dir %{_datadir}/qt5keychain/translations

%changelog
openSUSE Build Service is sponsored by