| 1 | %global prerelease beta1
|
|---|
| 2 |
|
|---|
| 3 | Name: qpdfview
|
|---|
| 4 | Version: 0.4.17
|
|---|
| 5 | Release: 3%{?prerelease}%{?dist}
|
|---|
| 6 | License: GPLv2+
|
|---|
| 7 | Summary: Tabbed PDF Viewer
|
|---|
| 8 | Url: https://launchpad.net/qpdfview
|
|---|
| 9 |
|
|---|
| 10 | Vendor: bww bitwise works GmbH
|
|---|
| 11 | %scm_source github https://github.com/bitwiseworks/qpdfview %{version}
|
|---|
| 12 |
|
|---|
| 13 | Requires: bww-resources-rpm
|
|---|
| 14 | Requires: libqt4
|
|---|
| 15 | Requires: cups
|
|---|
| 16 | Requires: poppler-qt4
|
|---|
| 17 | Requires: libspectre ghostscript
|
|---|
| 18 | Requires: zlib
|
|---|
| 19 | Requires: djvulibre
|
|---|
| 20 | Requires: libjpeg libtiff libpng
|
|---|
| 21 | Requires: %{name}-common = %{version}-%{release}
|
|---|
| 22 |
|
|---|
| 23 | BuildRequires: libqt4-devel
|
|---|
| 24 | BuildRequires: cups-devel
|
|---|
| 25 | BuildRequires: poppler-qt4-devel
|
|---|
| 26 | BuildRequires: libspectre-devel ghostscript-devel
|
|---|
| 27 | BuildRequires: zlib-devel
|
|---|
| 28 | BuildRequires: djvulibre-devel
|
|---|
| 29 | BuildRequires: libjpeg-devel libtiff-devel libpng-devel
|
|---|
| 30 | BuildRequires: bww-resources-rpm-build
|
|---|
| 31 |
|
|---|
| 32 | %description
|
|---|
| 33 | qpdfview is a tabbed PDF viewer.
|
|---|
| 34 | It uses the Poppler library for rendering and CUPS for printing.
|
|---|
| 35 | It provides a clear and simple graphical user interface using the Qt framework.
|
|---|
| 36 |
|
|---|
| 37 | %package common
|
|---|
| 38 | Summary: Common files for %{name}
|
|---|
| 39 | BuildArch: noarch
|
|---|
| 40 |
|
|---|
| 41 | %description common
|
|---|
| 42 | This package provides common files for %{name}.
|
|---|
| 43 |
|
|---|
| 44 | %prep
|
|---|
| 45 | %scm_setup
|
|---|
| 46 |
|
|---|
| 47 |
|
|---|
| 48 | %build
|
|---|
| 49 | export QMAKE_SH=$SHELL
|
|---|
| 50 | # do a fast qt build, as runmapsym and wmapsym is not needed here
|
|---|
| 51 | export FAST_BUILD=1
|
|---|
| 52 | LDFLAGS="-Zhigh-mem -Zomf -Zargs-wild -Zargs-resp"
|
|---|
| 53 |
|
|---|
| 54 | /@unixroot/usr/lib/qt4/bin/lrelease qpdfview.pro
|
|---|
| 55 | qmake \
|
|---|
| 56 | TARGET_INSTALL_PATH="%{_bindir}" \
|
|---|
| 57 | PLUGIN_INSTALL_PATH="%{_libdir}/%{name}" \
|
|---|
| 58 | DATA_INSTALL_PATH="%{_datadir}/%{name}" \
|
|---|
| 59 | MANUAL_INSTALL_PATH="%{_mandir}/man1" \
|
|---|
| 60 | ICON_INSTALL_PATH="%{_datadir}/icons/hicolor/scalable/apps" \
|
|---|
| 61 | LAUNCHER_INSTALL_PATH="%{_datadir}/applications" \
|
|---|
| 62 | APPDATA_INSTALL_PATH="%{_datadir}/appdata" \
|
|---|
| 63 | "CONFIG+=no_install_debuginfo" "CONFIG+=without_dbus" "CONFIG+=without_magic" \
|
|---|
| 64 | qpdfview.pro
|
|---|
| 65 | make %{?_smp_mflags}
|
|---|
| 66 |
|
|---|
| 67 |
|
|---|
| 68 | %install
|
|---|
| 69 | make INSTALL_ROOT=%{buildroot} install
|
|---|
| 70 | %find_lang %{name} --with-qt --without-mo
|
|---|
| 71 | # unknown language
|
|---|
| 72 | rm -f %{buildroot}/%{_datadir}/%{name}/%{name}_ast.qm
|
|---|
| 73 |
|
|---|
| 74 | # remove not needed desktop files
|
|---|
| 75 | rm -rf %{buildroot}/%{_datadir}/appdata
|
|---|
| 76 | rm -rf %{buildroot}/%{_datadir}/applications
|
|---|
| 77 | rm -rf %{buildroot}/%{_datadir}/icons
|
|---|
| 78 |
|
|---|
| 79 | # adjust install.os2 with the right version and build
|
|---|
| 80 | sed -i -e "s|_VERSION_|%{version}|" -e "s|_BUILD_|%{release}|" %{_builddir}/%{buildsubdir}/install.os2
|
|---|
| 81 |
|
|---|
| 82 |
|
|---|
| 83 | %post
|
|---|
| 84 | if [ "$1" -ge 1 ]; then # (upon update)
|
|---|
| 85 | %wps_object_delete_all
|
|---|
| 86 | fi
|
|---|
| 87 | # for the definition of the parameters see macros.bww
|
|---|
| 88 | %define title Tabbed PDF viewer
|
|---|
| 89 | %bww_folder -s Y -d %_defaultdocdir/%{name}-common-%{version} -t %{title}
|
|---|
| 90 | %bww_app -e %{name} -s Y -a *.pdf,*.ps,*.eps,*.djvu,*.djv -t %{title}
|
|---|
| 91 | %bww_readme -r README -d %_defaultdocdir/%{name}-common-%{version}
|
|---|
| 92 |
|
|---|
| 93 |
|
|---|
| 94 | %postun
|
|---|
| 95 | if [ "$1" -eq 0 ]; then # (upon removal)
|
|---|
| 96 | %wps_object_delete_all
|
|---|
| 97 | fi
|
|---|
| 98 |
|
|---|
| 99 |
|
|---|
| 100 | %files
|
|---|
| 101 | %{_bindir}/%{name}.exe
|
|---|
| 102 | %{_libdir}/%{name}/
|
|---|
| 103 |
|
|---|
| 104 | %files common -f %{name}.lang
|
|---|
| 105 | %license COPYING
|
|---|
| 106 | %doc CHANGES CONTRIBUTORS README TODO
|
|---|
| 107 | %doc install.os2
|
|---|
| 108 | %dir %{_datadir}/%{name}
|
|---|
| 109 | %{_datadir}/%{name}/help*.html
|
|---|
| 110 | %{_mandir}/man?/*
|
|---|
| 111 |
|
|---|
| 112 | %changelog
|
|---|
| 113 | * Wed Jun 28 2017 Silvan Scherrer <silvan.scherrer@aroa.ch> - 0.4.17-3.beta1
|
|---|
| 114 | - rebuild with latest macro.bww to fix an install glitch
|
|---|
| 115 |
|
|---|
| 116 | * Mon Mar 20 2017 Silvan Scherrer <silvan.scherrer@aroa.ch> - 0.4.17-2.beta1
|
|---|
| 117 | - rebuild with latest bwwres
|
|---|
| 118 | - added noarch rpm for the really noarch files
|
|---|
| 119 |
|
|---|
| 120 | * Fri Mar 17 2017 Silvan Scherrer <silvan.scherrer@aroa.ch> - 0.4.17-1
|
|---|
| 121 | - initial version
|
|---|