Add Qt6 subpackages

It turns out that version 1.1 supports building a Qt6 version as well
and Fedora already has Qt6 devel packages, so start building also the
Qt6 version for fun and profit.

Signed-off-by: Ondrej Mosnacek <omosnace@redhat.com>
epel9
Ondrej Mosnacek 4 years ago
parent a63557c563
commit ff87952be4

@ -2,7 +2,7 @@
Name: quazip Name: quazip
Version: 1.1 Version: 1.1
Release: 1%{?dist} Release: 2%{?dist}
Summary: Qt/C++ wrapper for the minizip library Summary: Qt/C++ wrapper for the minizip library
License: GPLv2+ or LGPLv2+ License: GPLv2+ or LGPLv2+
URL: https://github.com/stachenov/quazip URL: https://github.com/stachenov/quazip
@ -13,6 +13,8 @@ BuildRequires: cmake
BuildRequires: gcc-c++ BuildRequires: gcc-c++
BuildRequires: qt4-devel BuildRequires: qt4-devel
BuildRequires: qt5-qtbase-devel BuildRequires: qt5-qtbase-devel
BuildRequires: qt6-qtbase-devel
BuildRequires: qt6-qt5compat-devel
BuildRequires: doxygen graphviz BuildRequires: doxygen graphviz
@ -57,7 +59,31 @@ Requires: qt5-qtbase-devel%{?_isa}
Requires: zlib-devel%{?_isa} Requires: zlib-devel%{?_isa}
%description qt5-devel %description qt5-devel
The %{name}-devel package contains libraries, header files and documentation The %{name}-qt5-devel package contains libraries, header files and documentation
for developing applications that use %{name}.
%package qt6
Summary: Qt6 wrapper for the minizip library
%description qt6
QuaZIP is a simple C++ wrapper over Gilles Vollant's ZIP/UNZIP package that
can be used to access ZIP archives. It uses Trolltech's Qt toolkit.
QuaZIP allows you to access files inside ZIP archives using QIODevice API,
and - yes! - that means that you can also use QTextStream, QDataStream or
whatever you would like to use on your zipped files.
QuaZIP provides complete abstraction of the ZIP/UNZIP API, for both reading
from and writing to ZIP archives.
%package qt6-devel
Summary: Development files for %{name}
Requires: %{name}-qt6%{?_isa} = %{version}-%{release}
Requires: qt6-qtbase-devel%{?_isa}
Requires: qt6-qt5compat-devel%{?_isa}
Requires: zlib-devel%{?_isa}
%description qt6-devel
The %{name}-qt6-devel package contains libraries, header files and documentation
for developing applications that use %{name}. for developing applications that use %{name}.
@ -73,6 +99,10 @@ for developing applications that use %{name}.
%cmake -DQUAZIP_QT_MAJOR_VERSION=5 %cmake -DQUAZIP_QT_MAJOR_VERSION=5
%cmake_build %cmake_build
%global _vpath_builddir build-qt6
%cmake -DQUAZIP_QT_MAJOR_VERSION=6
%cmake_build
doxygen Doxyfile doxygen Doxyfile
for file in doc/html/*; do for file in doc/html/*; do
touch -r Doxyfile $file touch -r Doxyfile $file
@ -83,6 +113,8 @@ done
%cmake_install %cmake_install
%global _vpath_builddir build-qt5 %global _vpath_builddir build-qt5
%cmake_install %cmake_install
%global _vpath_builddir build-qt6
%cmake_install
# Create compat symlinks/files so that packages that use the old (pre-1.0) # Create compat symlinks/files so that packages that use the old (pre-1.0)
# library location, include paths, or CMake module still build against the # library location, include paths, or CMake module still build against the
@ -135,8 +167,25 @@ install -pm 0644 %{SOURCE1} %{buildroot}%{_datadir}/cmake/Modules/FindQuaZip5.cm
%{_libdir}/libquazip5.so %{_libdir}/libquazip5.so
%{_datadir}/cmake/Modules/FindQuaZip5.cmake %{_datadir}/cmake/Modules/FindQuaZip5.cmake
%files qt6
%doc NEWS.txt README.md
%license COPYING
%{_libdir}/libquazip1-qt6.so.1*
%files qt6-devel
%doc doc/html
%{_includedir}/QuaZip-Qt6-1.1/
%{_libdir}/libquazip1-qt6.so
%{_libdir}/cmake/QuaZip-Qt6-1.1/
# qt6-qtbase-devel currently doesn't provide pkgconfig(Qt6Core)
# https://bugreports.qt.io/browse/QTBUG-86080
%exclude %{_libdir}/pkgconfig/quazip1-qt6.pc
%changelog %changelog
* Thu Aug 19 2021 Ondrej Mosnacek <omosnace@rehdat.com> - 1.1-2
- Add Qt6 subpackages
* Sat Jul 31 2021 Ondrej Mosnacek <omosnace@rehdat.com> - 1.1-1 * Sat Jul 31 2021 Ondrej Mosnacek <omosnace@rehdat.com> - 1.1-1
- Update to 1.1 - Update to 1.1
- Resolves: rhbz#1895170 - Resolves: rhbz#1895170

Loading…
Cancel
Save