Summary: Extension for creating pdf-Files with CUPS Summary(fr): Extension de CUPS pour créer des fichiers PDF Name: cups-pdf Version: 2.6.1 Release: 7%{?dist} Group: Applications/Publishing URL: http://www.cups-pdf.de/ License: GPLv2+ Source0: http://www.physik.uni-wuerzburg.de/~vrbehr/cups-pdf/src/%{name}_%{version}.tar.gz Source1: INSTALL.fedora.cups-pdf # Default value for Out ${DESKTOP} Patch1: cups-pdf-conf.patch # Handle ${DESKTOP} from config Patch2: cups-pdf-desktop.patch # Handle new lines in title Patch3: cups-pdf-title.patch # Fix build warning Patch4: cups-pdf-build.patch # Report error/success in log Patch5: cups-pdf-result.patch BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildRequires: cups-devel Requires: ghostscript, cups Requires(post): %{_bindir}/pgrep # These are the defaults paths defined in config.h # CUPS-PDF spool directory %global CPSPOOL %{_localstatedir}/spool/cups-pdf/SPOOL # CUPS-PDF output directory %global CPOUT %{_localstatedir}/spool/cups-pdf # CUPS-PDF log directory %global CPLOG %{_localstatedir}/log/cups # CUPS-PDF cups-pdf.conf config file %global ETCCUPS %(cups-config --serverroot 2>/dev/null || echo %{_sysconfdir}/cups) # Additional path to backend directory %global CPBACKEND %(cups-config --serverbin 2>/dev/null || echo %{_libdir}/cups)/backend %description "cups-pdf" is a backend script for use with CUPS - the "Common UNIX Printing System" (see more for CUPS under http://www.cups.org/). "cups-pdf" uses the ghostscript pdfwrite device to produce PDF Files. This version has been modified to store the PDF files on the Desktop of the user. This behavior can be changed by editing the configuration file. %description -l fr "cups-pdf" est un script de traitement CUPS - le "Common UNIX Printing System" (plus d'informations sur CUPS à l'adresse http://www.cups.org/). "cups-pdf" utilise ghostscript pour construire des fichiers au format PDF. Cette version a été modifiée pour produire les fichiers PDF sur le bureau de l'utilisateur (dossier Desktop du répertoire d'accueil de l'utilisateur). Ce comportement peut être modifié en éditant le fichier de configuration. %prep echo CIBLE = %{name}-%{version}-%{release} %setup -q -n %{name}-%{version} cp %{SOURCE1} INSTALL.RPM %patch1 -p0 -b .oldconf %patch2 -p0 -b .desktop %patch3 -p0 -b .title %patch4 -p0 -b .build %patch5 -p0 -b .result %build pushd src cc $RPM_OPT_FLAGS -o cups-pdf cups-pdf.c popd # Avoid perl dependencies chmod -x contrib/pstitleiconv-0.2/pstitleiconv chmod -x contrib/cups-pdf-dispatch-0.1/cups-pdf-dispatch chmod -x contrib/SELinux-HOWTO/update-module %install rm -rf %{buildroot} mkdir -p %{buildroot}%{CPBACKEND} mkdir -p %{buildroot}%{CPSPOOL} mkdir -p %{buildroot}%{CPOUT} mkdir -p %{buildroot}%{CPLOG} mkdir -p %{buildroot}%{CPBACKEND} mkdir -p %{buildroot}%{ETCCUPS} mkdir -p %{buildroot}%{_datadir}/cups/model/ install -m644 extra/CUPS-PDF.ppd %{buildroot}%{_datadir}/cups/model/ install -m644 extra/cups-pdf.conf %{buildroot}%{ETCCUPS}/ install -m700 src/cups-pdf %{buildroot}%{CPBACKEND}/ %clean rm -rf %{buildroot} %post # First install : create the printer if cupsd is running if [ "$1" -eq "1" ] && %{_bindir}/pgrep -u root -f %{_sbindir}/cupsd >/dev/null then %if 0%{?fedora}%{?rhel} < 5 # Restart CUPS on old Fedora/RHEL to discover the new "backend" /sbin/service cups condrestart %endif /usr/sbin/lpadmin -p Cups-PDF -v cups-pdf:/ -m CUPS-PDF.ppd -E || : fi %postun if [ "$1" -eq "0" ]; then # Delete the printer /usr/sbin/lpadmin -x Cups-PDF || : fi %files %defattr(-,root,root) %doc ChangeLog COPYING README INSTALL.RPM contrib/ %dir %{CPSPOOL} %dir %{CPOUT} %attr(700, root, root) %{CPBACKEND}/cups-pdf %config(noreplace) %{ETCCUPS}/cups-pdf.conf %{_datadir}/cups/model/CUPS-PDF.ppd %changelog * Mon Sep 23 2013 Remi Collet 2.6.1-7 - report success/error in log file #1010434 * Thu Sep 12 2013 Remi Collet 2.6.1-6 - log path of generated PDF #1007143 * Tue Mar 19 2013 Remi Collet 2.6.1-4 - fix title detection - fix build warning - rename INSTALL.fedora to INSTALL.RPM * Wed Feb 13 2013 Fedora Release Engineering - 2.6.1-3 - Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild * Wed Jul 18 2012 Fedora Release Engineering - 2.6.1-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild * Thu Jan 05 2012 Remi Collet 2.6.1-1 - update to 2.6.1 - fix %%post scriptlet (#757760) * Sat Feb 19 2011 Remi Collet 2.5.1-1 - update to 2.5.1 (bugfix) - remove old SELinux stuff from spec * Tue Feb 08 2011 Fedora Release Engineering - 2.5.0-5 - Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild * Fri May 21 2010 Remi Collet 2.5.0-4 - spec cleanup * Fri Jul 24 2009 Fedora Release Engineering - 2.5.0-3 - Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild * Tue Feb 24 2009 Fedora Release Engineering - 2.5.0-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild * Sat Jan 31 2009 Remi Collet 2.5.0-1 - update to 2.5.0 - Add SElinux notes in INSTALL.fedora * Fri Mar 28 2008 Remi Collet 2.4.8-1 - update to 2.4.8 * Mon Mar 24 2008 Remi Collet 2.4.7-1 - update to 2.4.7 * Mon Mar 17 2008 Remi Collet 2.4.6-7 - remove SElinux on F >= 9 (in selinux-policy, see #436671) * Sat Feb 9 2008 Remi Collet 2.4.6-6.fc9.2 - rebuild with gcc-4.3 * Thu Dec 06 2007 Remi Collet 2.4.6-6.fc9.1 - change module version from 2.4.6.1 to 2.4.7 * Tue Dec 04 2007 Remi Collet 2.4.6-6 - handle unconfined_home_dir_t and unconfined_home_t * Thu Nov 29 2007 Remi Collet 2.4.6-5 - update default conf: use ${DESKTOP} * Sat Nov 24 2007 Remi Collet 2.4.6-4 - add cups-pdf-desktop.patch to work with xdg prefs * Thu Aug 23 2007 Remi Collet 2.4.6-3 - Fix License - F-8 rebuild (BuildID) * Sun May 06 2007 Remi Collet 2.4.6-2 - spec changes for RHEL 4 and Fedora Core 3 and 4 (no selinux) * Sun May 06 2007 Remi Collet 2.4.6-1 - update to 2.4.6 * Sun Apr 08 2007 Remi Collet 2.4.5-1 - update to 2.4.5 * Sat Feb 03 2007 Remi Collet 2.4.4-1 - update to 2.4.4 * Mon Nov 13 2006 Remi Collet 2.4.2-2 - review comments (URL, INSTALL.fedora as Source2, descr. rewrap) * Mon Nov 13 2006 Remi Collet 2.4.2-1 - clean spec for Extras - don't use "service cups restart", only test if cups is running * Tue Oct 24 2006 Remi Collet 2.4.2-1.fc6.remi - FC6 build * Sat Oct 7 2006 Remi Collet 2.4.2-1.fc5.remi - update to 2.4.2 * Tue May 16 2006 Remi Collet 2.4.0-1.fc{3,4,5}.remi - update to 2.4.0 - add SElinux module - spec cleanning * Tue May 16 2006 Remi Collet 2.3.0-1.fc{3,4,5}.remi - update to 2.3.0 - chmod 700 on %%{CPBACKEND}/cups-pdf for cups-1.2.0 on FC5 * Fri Apr 14 2006 Remi Collet 2.2.0-1.fc{3,4,5}.remi - update to 2.2.0 * Sat Apr 8 2006 Remi Collet 2.1.1-1.fc{3,4,5}.remi - update to 2.1.1 * Sun Mar 26 2006 Remi Collet 2.1.0-1.fc{3,4,5}.remi - update to 2.1.0 * Sun Jan 29 2006 Remi Collet 2.0.5-1.fc{3,4}.remi - update to 2.0.5 * Sun Jan 29 2006 Remi Collet 2.0.4-1.fc{3,4}.remi - update to 2.0.4 * Sat Jan 7 2006 Remi Collet 2.0.3-1.fc{3,4}.remi - update to 2.0.3 * Wed Jan 4 2006 Remi Collet 2.0.1-1.fc{3,4}.remi - update to 2.0.1 * Tue Jan 3 2006 Remi Collet 2.0.0-2.fc#.remi - output to Desktop - defattr * Fri Dec 23 2005 Remi Collet 2.0.0-1.fc4.remi - update to 2.0.0 final * Sat Nov 5 2005 Remi Collet 2.0-0.1.fc3.remi - rebuild for FC3 * Sat Nov 5 2005 Remi Collet 2.0-0.1.fc4.remi - update to 2.0 beta2 - rebuild for FC4 - conditionnal "post" and "postun" script, more robust - cups-pdf-conf.patch (Out in $HOME) * Mon Sep 26 2005 Christian Ellsworth C. - adapted to fit the new runtime config file of version 2.0 * Sat Sep 10 2005 Remi Collet 1.7.4-1.fc4.remi - adapted to cups-pdf 1.7.4 - added auto remove a cups-pdf printer in "postun" - added CHANGELOG, COPYING, README - creating cups-pdf-home.patch * Sat Mar 05 2005 Christian Ellsworth C. - adapted to cups-pdf 1.7.0 - added auto configure a cups-pdf printer * Tue Feb 22 2005 Christian Ellsworth C. - adapted to cups-pdf 1.6.6 * Thu Aug 12 2004 Volker Behr - adapted to cups-pdf 1.5.2 * Sat Jan 31 2004 Volker Behr - adapetd to cups-pdf 1.4.0 and new building environment * Wed Jan 14 2004 Mark Lane - fixed the specfile so that x86_64 version installs the filter - in /usr/lib64 instead of /usr/lib * Sun Nov 02 2003 Volker Behr - third release of cups-pdf, RPM-Edition for cups-pdf 1.3 * Tue Sep 09 2003 Dirk Schwier - second Release of cups-pdf, RPM-Edition for cups-pdf 1.1 * Tue May 27 2003 Dirk Schwier - we're proud to present the first version of cups-pdf, RPM-Edition