File libcommuni.spec of Package libcommuni

#
# spec file for package libcommuni
#
# 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 soname 3
Name:           libcommuni
Version:        3.7.0+20240504.g3a7a8ab
Release:        0
Summary:        Cross-platform IRC framework written with Qt
License:        BSD-3-Clause
Group:          System/Libraries
URL:            https://communi.github.io/
Source0:        %{name}-%{version}.tar.xz
BuildRequires:  c++_compiler
BuildRequires:  fdupes
BuildRequires:  libqt5-qtbase-devel
BuildRequires:  libqt5-qtdeclarative-devel

%description
Communi provides a set of tools for enabling IRC connectivity in Qt-based
C++ and QML applications.

%package -n %{name}%{soname}
Summary:        A cross-platform IRC framework written with Qt
Group:          System/Libraries

%description -n %{name}%{soname}
Communi provides a set of tools for enabling IRC connectivity in Qt-based
C++ and QML applications.

%package -n %{name}-devel
Summary:        A cross-platform IRC framework written with Qt
Group:          Development/Libraries/C and C++
Requires:       %{name}%{soname} = %{version}

%description -n %{name}-devel
Communi provides a set of tools for enabling IRC connectivity in Qt-based
C++ and QML applications.

%prep
%setup -q

%build
%qmake5 CONFIG+=no_rpath
%make_build

%install
%make_install INSTALL_ROOT=%{buildroot}
%fdupes %{buildroot}

%post -n %{name}%{soname} -p /sbin/ldconfig
%postun -n %{name}%{soname} -p /sbin/ldconfig

%files -n %{name}%{soname}
%license LICENSE
%doc README.md CHANGELOG.md
%{_libdir}/libIrc*.so.*
%{_libdir}/qt5/qml/Communi

%files -n %{name}-devel
%{_libdir}/libIrc*.so
%{_libdir}/qt5/mkspecs/features/communi*.prf
%{_includedir}/qt5/Communi

%changelog
openSUSE Build Service is sponsored by