From 27998029123f1134408240a23981d826a8c8cb7341a60f2e456ba758ea1c159d Mon Sep 17 00:00:00 2001 From: Atri Bhattacharya Date: Tue, 20 Feb 2024 15:21:06 +0000 Subject: [PATCH] Accepting request 1148077 from home:dimstar:rpm4.20:q Prepare for RPM 4.20 OBS-URL: https://build.opensuse.org/request/show/1148077 OBS-URL: https://build.opensuse.org/package/show/science/qwtplot3d?expand=0&rev=11 --- qwtplot3d.changes | 6 ++++ qwtplot3d.spec | 84 ++++++++++++++++++++--------------------------- 2 files changed, 41 insertions(+), 49 deletions(-) diff --git a/qwtplot3d.changes b/qwtplot3d.changes index 9cf5980..8cdb2cb 100644 --- a/qwtplot3d.changes +++ b/qwtplot3d.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Tue Feb 20 14:06:15 UTC 2024 - Dominique Leuenberger + +- Use %autosetup macro. Allows to eliminate the usage of deprecated + %patchN + ------------------------------------------------------------------- Sat Apr 27 12:59:02 UTC 2019 - christophe@krop.fr diff --git a/qwtplot3d.spec b/qwtplot3d.spec index a558d28..3892e2b 100644 --- a/qwtplot3d.spec +++ b/qwtplot3d.spec @@ -1,7 +1,7 @@ # # spec file for package qwtplot3d # -# Copyright (c) 2017 SUSE LINUX GmbH, Nuernberg, Germany. +# Copyright (c) 2019 SUSE LINUX GmbH, Nuernberg, Germany. # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -12,41 +12,41 @@ # license that conforms to the Open Source Definition (Version 1.9) # published by the Open Source Initiative. -# Please submit bugfixes or comments via http://bugs.opensuse.org/ +# Please submit bugfixes or comments via https://bugs.opensuse.org/ # -%define soname 0 +%define soname 0 Name: qwtplot3d -Version: 0.2.7 +Version: 0.2.7+git20190410.a6d0890d Release: 0 Summary: A feature-rich Qt/OpenGL-based C++ programming library License: Zlib Group: Development/Libraries/C and C++ -Url: http://qwtplot3d.sourceforge.net/ -Source: qwtplot3d-%{version}.tar.bz2 -# PATCH-MISSING-TAG -- See http://wiki.opensuse.org/openSUSE:Packaging_Patches_guidelines -Patch0: qwtplot3d-gcc43.patch -# PATCH-MISSING-TAG -- See http://wiki.opensuse.org/openSUSE:Packaging_Patches_guidelines -Patch1: glu_include.patch +URL: https://github.com/copasi/copasi-dependencies/tree/master/src/qwtplot3d-qt4 +Source: %{name}-%{version}.tar.xz +# PATCH-FIX-OPENSUSE +Patch0: build_a_shared_lib.patch BuildRequires: Mesa-devel -BuildRequires: dos2unix -%if 0%{?suse_version} > 1220 -BuildRequires: glu-devel -%endif -BuildRequires: qt-devel -BuildRoot: %{_tmppath}/%{name}-%{version}-build +BuildRequires: cmake +BuildRequires: pkgconfig +BuildRequires: cmake(Qt5Core) +BuildRequires: cmake(Qt5Gui) +BuildRequires: cmake(Qt5OpenGL) +BuildRequires: cmake(Qt5Xml) +BuildRequires: pkgconfig(glu) +BuildRequires: pkgconfig(zlib) %description QwtPlot3D is not a program, but a feature-rich Qt/OpenGL-based C++ programming library. It provides essentially a bunch of 3D widgets for programmers. -%package -n lib%{name}%{soname} +%package -n libqwtplot3d-qt5-%{soname} Summary: Shared library containing the QwtPlot3D Widget set Group: System/Libraries -%description -n lib%{name}%{soname} +%description -n libqwtplot3d-qt5-%{soname} QwtPlot3D is not a program, but a feature-rich Qt/OpenGL-based C++ programming library. It provides essentially a bunch of 3D widgets for programmers. @@ -54,50 +54,36 @@ for programmers. %package devel Summary: Development tools for programs which uses QwtPlot3D Widget set Group: Development/Libraries/C and C++ -Requires: lib%{name}%{soname} = %{version} -Requires: qt-devel +Requires: libqwtplot3d-qt5-%{soname} = %{version} %description devel QwtPlot3D is a feature-rich Qt/OpenGL-based C++ programming library. It provides essentially a bunch of 3D widgets for programmers. %prep -%setup -q -n qwtplot3d -%patch0 -p1 -%patch1 -p0 -dos2unix COPYING -find examples -type f -exec dos2unix {} + +%autosetup -p1 %build -qmake qwtplot3d.pro -o Makefile -make %{?_smp_mflags} +%cmake -DSELECT_QT=Qt5 \ + -DWITH_ZLIB=ON \ + -DCMAKE_INSTALL_INCLUDEDIR=%{_libqt5_includedir}/%{name} + +%make_jobs %install -mkdir -p %{buildroot}%{_includedir}/qwtplot3d -mkdir -p %{buildroot}%{_libdir} -for n in include/*.h ; do - install -m 644 $n %{buildroot}%{_includedir}/qwtplot3d -done -# install, preserving links -chmod 644 lib/libqwtplot3d.so* -for n in lib/libqwtplot3d.so* ; do - cp -d $n %{buildroot}%{_libdir} -done +%cmake_install -%post -n lib%{name}%{soname} -p /sbin/ldconfig +%post -n libqwtplot3d-qt5-%{soname} -p /sbin/ldconfig +%postun -n libqwtplot3d-qt5-%{soname} -p /sbin/ldconfig -%postun -n lib%{name}%{soname} -p /sbin/ldconfig - -%files -n lib%{name}%{soname} -%defattr(-,root,root) -%doc COPYING -%{_libdir}/lib%{name}.so.* +%files -n libqwtplot3d-qt5-%{soname} +%license COPYING +%{_libdir}/libqwtplot3d-qt5.so.* %files devel -%defattr(-,root,root) -%doc COPYING examples -%{_libdir}/lib%{name}.so -%dir %{_includedir}/qwtplot3d -%{_includedir}/qwtplot3d/qwt3d*.h +%license COPYING +%doc examples +%{_libdir}/libqwtplot3d-qt5.so +%{_libqt5_includedir}/qwtplot3d/ %changelog