2007-01-16 00:08:16 +01:00
|
|
|
#
|
2010-03-31 19:57:49 +02:00
|
|
|
# spec file for package cups (Version 1.4.3)
|
2007-01-16 00:08:16 +01:00
|
|
|
#
|
2010-03-18 23:08:53 +01:00
|
|
|
# Copyright (c) 2010 SUSE LINUX Products GmbH, Nuernberg, Germany.
|
2007-01-16 00:08:16 +01:00
|
|
|
#
|
2008-08-24 10:51:03 +02:00
|
|
|
# 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.
|
|
|
|
|
2007-01-16 00:08:16 +01:00
|
|
|
# Please submit bugfixes or comments via http://bugs.opensuse.org/
|
|
|
|
#
|
|
|
|
|
|
|
|
# norootforbuild
|
|
|
|
|
2008-02-29 22:34:42 +01:00
|
|
|
|
2007-01-16 00:08:16 +01:00
|
|
|
Name: cups
|
2008-07-14 18:17:01 +02:00
|
|
|
BuildRequires: avahi-compat-mDNSResponder-devel dbus-1-devel gcc-c++
|
|
|
|
BuildRequires: krb5-devel libpng-devel libtiff-devel openldap2-devel
|
|
|
|
BuildRequires: openslp-devel openssl-devel pam-devel pkg-config tcpd-devel
|
2009-09-21 20:58:48 +02:00
|
|
|
BuildRequires: fdupes update-desktop-files
|
2008-04-06 04:44:41 +02:00
|
|
|
PreReq: textutils, fileutils, sh-utils, %insserv_prereq,
|
|
|
|
PreReq: %fillup_prereq /usr/sbin/groupadd
|
2007-09-19 19:06:40 +02:00
|
|
|
Url: http://www.cups.org/
|
2010-04-28 22:21:38 +02:00
|
|
|
License: GPLv2+ ; LGPLv2.1+
|
2007-01-16 00:08:16 +01:00
|
|
|
Group: Hardware/Printing
|
|
|
|
Summary: The Common UNIX Printing System
|
2010-03-31 19:57:49 +02:00
|
|
|
Version: 1.4.3
|
2010-05-25 10:36:50 +02:00
|
|
|
Release: 4
|
2010-03-18 23:08:54 +01:00
|
|
|
# Require the exact matching version-release of the cups-libs sub-package because
|
|
|
|
# non-matching CUPS libraries may let CUPS software crash (e.g. segfault)
|
|
|
|
# because all CUPS software is built from the one same CUPS source tar ball
|
|
|
|
# so that there are CUPS-internal dependencies via CUPS private API calls
|
|
|
|
# (which do not happen for third-party software which uses only the CUPS public API).
|
|
|
|
# The exact matching version-release of the cups-libs sub-package is available
|
|
|
|
# on the same package repository where the cups package is because
|
|
|
|
# all are built simulaneously from the same cups source package
|
|
|
|
# and all required packages are provided on the same repository:
|
|
|
|
Requires: cups-libs = %{version}-%{release}
|
|
|
|
Requires: cups-client = %{version}
|
2007-01-16 00:08:16 +01:00
|
|
|
Requires: ghostscript_any, ghostscript-fonts-std, foomatic-filters
|
2008-04-25 16:01:41 +02:00
|
|
|
Requires: util-linux /usr/bin/pdftops
|
2008-05-26 19:00:02 +02:00
|
|
|
%if 0%{?suse_version} >= 1100
|
|
|
|
Requires: pdftools_any
|
|
|
|
%endif
|
2008-04-25 16:01:41 +02:00
|
|
|
Suggests: poppler-tools
|
2007-01-16 00:08:16 +01:00
|
|
|
Conflicts: plp lprold lprng
|
2008-11-03 11:59:49 +01:00
|
|
|
Obsoletes: cups-SUSE-ppds-dat
|
2010-05-07 15:35:59 +02:00
|
|
|
Provides: cups-SUSE-ppds-dat
|
2010-03-18 23:08:54 +01:00
|
|
|
# Source0...Source9 is for sources from upstream:
|
2010-03-31 19:57:49 +02:00
|
|
|
# URL for Source0: http://ftp.easysw.com/pub/cups/1.4.3/cups-1.4.3-source.tar.bz2
|
|
|
|
# MD5 sum for Source0 on http://www.cups.org/software.php is e70b1c3f60143d7310c1d74c111a21ab
|
2007-01-16 00:08:16 +01:00
|
|
|
Source0: cups-%{version}-source.tar.bz2
|
2010-03-18 23:08:54 +01:00
|
|
|
# Patch0...Patch9 is for patches from upstream:
|
|
|
|
# Source10...Source99 is for sources from Novell/openSUSE which are intended for upstream:
|
|
|
|
# Patch10...Patch99 is for patches from Novell/openSUSE which are intended for upstream:
|
|
|
|
# Patch10 adds 'smb://...' URIs to templates/choose-uri.tmpl:
|
|
|
|
Patch10: cups-1.2rc1-template.patch
|
2010-05-07 15:35:59 +02:00
|
|
|
# Patch11 changes the default path whereto the web content is installed
|
|
|
|
# from /usr/share/doc/cups to /usr/share/cups/webcontent because the
|
|
|
|
# files of the CUPS web content are no documentation, see CUPS STR #3578
|
|
|
|
# and http://bugzilla.novell.com/show_bug.cgi?id=546023#c6 and subsequent comments:
|
|
|
|
Patch11: cups-1.4.3-default-webcontent-path.patch
|
2010-03-18 23:08:54 +01:00
|
|
|
# Source100...Source999 is for private sources from Novell/openSUSE which are not intended for upstream:
|
|
|
|
Source101: cups.init
|
|
|
|
Source102: postscript.ppd.bz2
|
|
|
|
Source103: cups.sysconfig
|
|
|
|
Source104: cups.xinetd
|
|
|
|
Source105: PSLEVEL1.PPD.bz2
|
|
|
|
Source106: PSLEVEL2.PPD.bz2
|
|
|
|
Source108: cups-client.conf
|
|
|
|
Source109: baselibs.conf
|
|
|
|
# Patch100...Patch999 is for private patches from Novell/openSUSE which are not intended for upstream:
|
|
|
|
# Patch100 adds conf/pam.suse regarding support for PAM for Novell/openSUSE:
|
|
|
|
Patch100: cups-pam.diff
|
|
|
|
# Patch101 adds 'Allow 127.0.0.2' to cupsd.conf
|
|
|
|
# to allow access for the loopback IP address 127.0.0.2
|
|
|
|
# which is set for the hostname by Novell/openSUSE in /etc/hosts
|
|
|
|
Patch101: cups-1.3.6-access_conf.patch
|
|
|
|
# Patch102 changes desktop/cups.desktop according to what Novell/openSUSE needs:
|
|
|
|
Patch102: cups-1.3.9-desktop_file.patch
|
|
|
|
# Patch103 reverts the change which was added by Michael Sweet in Jan 2007
|
|
|
|
# which strips the word "recommended" from NickName in PPDs because
|
|
|
|
# at least yast2-printer in Novell/openSUSE needs it, compare the
|
|
|
|
# 'Why not "recommend" PPDs in the NickName?' and the subsequent
|
|
|
|
# 'RFC: New Driver Rating/Information Attributes' mail thread on cups@easysw.com:
|
|
|
|
Patch103: cups-1.4-do_not_strip_recommended_from_PPDs.patch
|
|
|
|
# Patch104 adds the 'allowallforanybody' policy to cupsd.conf
|
|
|
|
# see https://fate.novell.com/303515
|
|
|
|
Patch104: cups-1.4-additional_policies.patch
|
|
|
|
# Install into this non-root directory (required when norootforbuild is used):
|
2007-01-16 00:08:16 +01:00
|
|
|
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
|
|
|
|
|
|
|
%description
|
|
|
|
The Common UNIX Printing System provides a portable printing layer for
|
2010-03-18 23:08:54 +01:00
|
|
|
UNIX operating systems like BSD lp or lprng. CUPS provides some
|
2007-01-16 00:08:16 +01:00
|
|
|
additional features.
|
|
|
|
|
|
|
|
http://www.cups.org
|
|
|
|
|
|
|
|
%package libs
|
2010-03-18 23:08:53 +01:00
|
|
|
License: GPLv2+ ; LGPLv2.1+
|
2007-05-25 00:40:10 +02:00
|
|
|
Summary: Libraries for CUPS
|
2007-01-16 00:08:16 +01:00
|
|
|
Group: Hardware/Printing
|
2010-03-18 23:08:54 +01:00
|
|
|
# https://bugzilla.novell.com/show_bug.cgi?id=437293
|
2008-11-03 11:59:49 +01:00
|
|
|
%ifarch ppc64
|
2009-01-14 17:48:52 +01:00
|
|
|
Obsoletes: cups-libs-64bit
|
2008-11-03 11:59:49 +01:00
|
|
|
%endif
|
2007-01-16 00:08:16 +01:00
|
|
|
|
|
|
|
%description libs
|
|
|
|
The Common UNIX Printing System provides a portable printing layer for
|
2010-03-18 23:08:54 +01:00
|
|
|
UNIX operating systems like BSD lp or lprng. CUPS provides some
|
2007-01-16 00:08:16 +01:00
|
|
|
additional features. This package contains libraries needed by CUPS and
|
|
|
|
some other packages.
|
|
|
|
|
|
|
|
%package client
|
2010-03-18 23:08:53 +01:00
|
|
|
License: GPLv2+
|
2007-01-16 00:08:16 +01:00
|
|
|
Summary: CUPS Client Programs
|
|
|
|
Group: Hardware/Printing
|
|
|
|
Conflicts: plp lprold lprng
|
2010-03-18 23:08:54 +01:00
|
|
|
# Require the exact matching version-release of the cups-libs sub-package because
|
|
|
|
# non-matching CUPS libraries may let CUPS software crash (e.g. segfault)
|
|
|
|
# because all CUPS software is built from the one same CUPS source tar ball
|
|
|
|
# so that there are CUPS-internal dependencies via CUPS private API calls
|
|
|
|
# (which do not happen for third-party software which uses only the CUPS public API).
|
|
|
|
# The exact matching version-release of the cups-libs sub-package is available
|
|
|
|
# on the same package repository where the cups package is because
|
|
|
|
# all are built simulaneously from the same cups source package
|
|
|
|
# and all required packages are provided on the same repository:
|
|
|
|
Requires: cups-libs = %{version}-%{release}
|
2007-01-16 00:08:16 +01:00
|
|
|
|
|
|
|
%description client
|
|
|
|
The Common UNIX Printing System provides a portable printing layer for
|
2010-03-18 23:08:54 +01:00
|
|
|
UNIX operating systems like BSD lp or lprng. CUPS provides some
|
2007-01-16 00:08:16 +01:00
|
|
|
additional features. This package contains all programs needed for
|
|
|
|
running a CUPS client, not a server.
|
|
|
|
|
|
|
|
%package devel
|
2010-03-18 23:08:53 +01:00
|
|
|
License: GPLv2+
|
2007-01-16 00:08:16 +01:00
|
|
|
Summary: Development Environment for CUPS
|
|
|
|
Group: Development/Libraries/C and C++
|
2010-03-18 23:08:54 +01:00
|
|
|
# Do not require the exact matching version-release of cups-libs
|
|
|
|
# but only a cups-libs package with matching version because
|
|
|
|
# for building third-party software which uses only the CUPS public API
|
|
|
|
# there are no CUPS-internal dependencies via CUPS private API calls
|
|
|
|
# (the latter would require the exact matching cups-libs version-release):
|
|
|
|
Requires: cups-libs = %{version}
|
|
|
|
Requires: openssl-devel glibc-devel krb5-devel
|
|
|
|
# https://bugzilla.novell.com/show_bug.cgi?id=437293
|
2009-01-14 17:48:52 +01:00
|
|
|
%ifarch ppc64
|
|
|
|
Obsoletes: cups-devel-64bit
|
|
|
|
%endif
|
2007-01-16 00:08:16 +01:00
|
|
|
|
|
|
|
%description devel
|
|
|
|
The Common UNIX Printing System provides a portable printing layer for
|
2010-03-18 23:08:54 +01:00
|
|
|
UNIX operating systems like BSD lp or lprng. CUPS provides some
|
2007-01-16 00:08:16 +01:00
|
|
|
additional features. This is the development package.
|
|
|
|
|
|
|
|
http://www.cups.org
|
|
|
|
|
2010-03-18 23:08:54 +01:00
|
|
|
%package ddk
|
|
|
|
License: GPLv2+
|
|
|
|
Summary: CUPS Driver Development Kit
|
|
|
|
Group: Hardware/Printing
|
|
|
|
Requires: cups = %{version}
|
|
|
|
Requires: cups-devel = %{version}
|
|
|
|
# Since CUPS 1.4 the CUPS Driver Development Kit (DDK) is bundled with CUPS.
|
|
|
|
# For CUPS 1.2.x and 1.3.x, the DDK was separated software
|
|
|
|
# which we provided (up to openSUSE 11.1 / SLE11) in our cupsddk package:
|
|
|
|
Provides: cupsddk = %{version}
|
|
|
|
Obsoletes: cupsddk < %{version}
|
|
|
|
|
|
|
|
%description ddk
|
|
|
|
The CUPS Driver Development Kit (DDK) provides a suite of standard
|
|
|
|
drivers, a PPD file compiler, and other utilities that can be used to
|
|
|
|
develop printer drivers for CUPS and other printing environments. CUPS
|
|
|
|
provides a portable printing layer for UNIX(r)-based operating systems.
|
|
|
|
The CUPS DDK provides the means for mass-producing PPD files and
|
|
|
|
drivers or filters for CUPS-based printer drivers.
|
|
|
|
The Common UNIX Printing System provides a portable printing layer for
|
|
|
|
UNIX operating systems like BSD lp or lprng. CUPS provides some
|
|
|
|
additional features. This is the Driver Development Kit package.
|
2010-01-27 16:30:41 +01:00
|
|
|
|
2010-03-18 23:08:54 +01:00
|
|
|
http://www.cups.org
|
2010-01-27 16:30:41 +01:00
|
|
|
|
2007-01-16 00:08:16 +01:00
|
|
|
%prep
|
2009-07-08 20:00:22 +02:00
|
|
|
# Be quiet when unpacking:
|
2010-05-07 15:35:59 +02:00
|
|
|
%setup -q -n cups-%{version}
|
2010-03-18 23:08:54 +01:00
|
|
|
# Patch0...Patch9 is for patches from upstream:
|
|
|
|
# Patch10...Patch99 is for patches from Novell/openSUSE which are intended for upstream:
|
|
|
|
# Patch10 adds 'smb://...' URIs to templates/choose-uri.tmpl:
|
|
|
|
%patch10 -p1
|
2010-05-07 15:35:59 +02:00
|
|
|
# Patch11 changes the default path whereto the web content is installed
|
|
|
|
# from /usr/share/doc/cups to /usr/share/cups/webcontent because the
|
|
|
|
# files of the CUPS web content are no documentation, see CUPS STR #3578
|
|
|
|
# and http://bugzilla.novell.com/show_bug.cgi?id=546023#c6 and subsequent comments:
|
|
|
|
%patch11
|
2010-03-18 23:08:54 +01:00
|
|
|
# Patch100...Patch999 is for private patches from Novell/openSUSE which are not intended for upstream:
|
|
|
|
# Patch100 adds conf/pam.suse regarding support for PAM for Novell/openSUSE:
|
|
|
|
%patch100
|
|
|
|
# Patch101 adds 'Allow 127.0.0.2' to cupsd.conf:
|
|
|
|
%patch101 -p1
|
|
|
|
# Patch102 changes desktop/cups.desktop according to what Novell/openSUSE needs:
|
|
|
|
%patch102
|
|
|
|
# Patch103 reverts the change which strips the word "recommended" from NickName in PPDs:
|
|
|
|
%patch103
|
|
|
|
# Patch104 adds the 'allowallforanybody' policy to cupsd.conf:
|
|
|
|
%patch104
|
2007-01-16 00:08:16 +01:00
|
|
|
|
|
|
|
%build
|
|
|
|
%{?suse_update_config:%{suse_update_config -f . }}
|
|
|
|
libtoolize --force
|
|
|
|
aclocal
|
|
|
|
autoconf
|
|
|
|
export CXXFLAGS="$CXXFLAGS $RPM_OPT_FLAGS -O2 -fno-strict-aliasing -fstack-protector"
|
2007-01-23 01:13:49 +01:00
|
|
|
export CFLAGS="$RPM_OPT_FLAGS -fno-strict-aliasing -fstack-protector -DLDAP_DEPRECATED"
|
2007-01-16 00:08:16 +01:00
|
|
|
export CXX=g++
|
2010-05-07 15:35:59 +02:00
|
|
|
# As long as cups-1.4.3-default-webcontent-path.patch is applied
|
|
|
|
# configure --with-docdir=... would be no longer needed
|
|
|
|
# because cups-1.4.3-default-webcontent-path.patch changes the
|
|
|
|
# default with-docdir path whereto the web content is installed
|
|
|
|
# from /usr/share/doc/cups to /usr/share/cups/webcontent because the
|
|
|
|
# files of the CUPS web content are no documentation, see CUPS STR #3578
|
|
|
|
# and http://bugzilla.novell.com/show_bug.cgi?id=546023#c6 and subsequent comments
|
|
|
|
# so that the new default could be used as is but upstream may accept
|
|
|
|
# cups-1.4.3-default-webcontent-path.patch in general but change its default
|
|
|
|
# so that with-docdir is explicitely set here to be future proof:
|
2010-03-31 19:57:49 +02:00
|
|
|
./configure \
|
2007-01-16 00:08:16 +01:00
|
|
|
--mandir=%{_mandir} \
|
|
|
|
--sysconfdir=%{_sysconfdir} \
|
|
|
|
--libdir=%{_libdir} \
|
|
|
|
--datadir=%{_datadir} \
|
2010-05-07 15:35:59 +02:00
|
|
|
--with-docdir=%{_datadir}/cups/webcontent \
|
2007-01-16 00:08:16 +01:00
|
|
|
--with-cups-user=lp \
|
|
|
|
--with-cups-group=lp \
|
2010-06-02 18:10:51 +02:00
|
|
|
--enable-pie \
|
2008-04-08 22:37:35 +02:00
|
|
|
--enable-relro \
|
|
|
|
--enable-gssapi \
|
2009-06-12 17:24:31 +02:00
|
|
|
--disable-static \
|
2007-01-16 00:08:16 +01:00
|
|
|
--without-rcdir \
|
2007-12-18 18:29:38 +01:00
|
|
|
--enable-dbus \
|
2007-01-23 01:13:49 +01:00
|
|
|
--enable-ldap \
|
2008-04-08 22:37:35 +02:00
|
|
|
--with-java \
|
|
|
|
--with-php \
|
|
|
|
--with-python \
|
2010-03-18 23:08:54 +01:00
|
|
|
--with-cachedir=/var/cache/cups \
|
2008-04-11 12:03:51 +02:00
|
|
|
--with-pdftops=/usr/bin/pdftops \
|
2007-01-16 00:08:16 +01:00
|
|
|
--prefix=/
|
2010-03-18 23:08:54 +01:00
|
|
|
make %{?_smp_mflags} CXX=g++
|
2007-01-16 00:08:16 +01:00
|
|
|
|
|
|
|
%install
|
2010-03-18 23:08:54 +01:00
|
|
|
make BUILDROOT=$RPM_BUILD_ROOT install
|
|
|
|
install -d -m755 $RPM_BUILD_ROOT/etc/init.d
|
|
|
|
# Source101: cups.init
|
|
|
|
install -m755 %{SOURCE101} $RPM_BUILD_ROOT/etc/init.d/cups
|
2010-04-28 22:21:38 +02:00
|
|
|
ln -sf ../../etc/init.d/cups $RPM_BUILD_ROOT/usr/sbin/rccups
|
2010-04-28 22:21:37 +02:00
|
|
|
# Source103: cups.sysconfig
|
2010-04-28 22:21:38 +02:00
|
|
|
install -d -m755 $RPM_BUILD_ROOT/var/adm/fillup-templates
|
2010-03-18 23:08:54 +01:00
|
|
|
install -m 644 %{SOURCE103} $RPM_BUILD_ROOT/var/adm/fillup-templates/sysconfig.cups
|
2010-03-31 19:57:49 +02:00
|
|
|
# Use Ghostscript fonts instead of CUPS fonts:
|
2007-01-16 00:08:16 +01:00
|
|
|
rm -r $RPM_BUILD_ROOT/usr/share/cups/fonts
|
|
|
|
mkdir -p $RPM_BUILD_ROOT/usr/share/ghostscript/fonts
|
|
|
|
ln -sf /usr/share/ghostscript/fonts $RPM_BUILD_ROOT/usr/share/cups/
|
2010-03-31 19:57:49 +02:00
|
|
|
# Make directory for ssl files:
|
2007-01-16 00:08:16 +01:00
|
|
|
mkdir -p $RPM_BUILD_ROOT%{_sysconfdir}/cups/ssl
|
2010-03-31 19:57:49 +02:00
|
|
|
# Add a client.conf as template (Source108: cups-client.conf):
|
2010-03-18 23:08:54 +01:00
|
|
|
install -m644 %{SOURCE108} $RPM_BUILD_ROOT%{_sysconfdir}/cups/client.conf
|
2010-04-28 22:21:38 +02:00
|
|
|
# Add D-BUS Configuration:
|
2007-12-18 18:29:38 +01:00
|
|
|
install -m 644 -D packaging/cups-dbus.conf $RPM_BUILD_ROOT%{_sysconfdir}/dbus-1/system.d/cups.conf
|
2010-03-18 23:08:54 +01:00
|
|
|
# Source104: cups.xinetd
|
2010-04-28 22:21:38 +02:00
|
|
|
mkdir -p $RPM_BUILD_ROOT%{_sysconfdir}/xinetd.d
|
2010-03-18 23:08:54 +01:00
|
|
|
install -m 644 -D %{SOURCE104} $RPM_BUILD_ROOT%{_sysconfdir}/xinetd.d/cups-lpd
|
2010-03-31 19:57:49 +02:00
|
|
|
# Make the libraries accessible also via generic named links:
|
2007-01-16 00:08:16 +01:00
|
|
|
ln -sf libcupsimage.so.2 $RPM_BUILD_ROOT%{_libdir}/libcupsimage.so
|
|
|
|
ln -sf libcups.so.2 $RPM_BUILD_ROOT%{_libdir}/libcups.so
|
2010-03-31 19:57:49 +02:00
|
|
|
# Add missing usual directories:
|
2010-05-07 15:35:59 +02:00
|
|
|
install -d -m755 $RPM_BUILD_ROOT%{_datadir}/cups/drivers
|
2010-03-18 23:08:54 +01:00
|
|
|
install -d -m755 $RPM_BUILD_ROOT/var/cache/cups
|
2010-03-31 19:57:49 +02:00
|
|
|
# Add conf/pam.suse regarding support for PAM (see Patch100: cups-pam.diff):
|
2007-01-16 00:08:16 +01:00
|
|
|
install -m 644 -D conf/pam.suse $RPM_BUILD_ROOT/etc/pam.d/cups
|
2010-03-31 19:57:49 +02:00
|
|
|
# Add missing usual documentation:
|
2010-05-07 15:35:59 +02:00
|
|
|
install -d -m755 $RPM_BUILD_ROOT/%{_defaultdocdir}/cups
|
2010-03-31 19:57:49 +02:00
|
|
|
for f in CHANGES*.txt CREDITS.txt INSTALL.txt LICENSE.txt README.txt
|
2010-05-07 15:35:59 +02:00
|
|
|
do install -m 644 "$f" $RPM_BUILD_ROOT%{_defaultdocdir}/cups/
|
2007-01-16 00:08:16 +01:00
|
|
|
done
|
2010-03-18 23:08:54 +01:00
|
|
|
# Source102: postscript.ppd.bz2
|
|
|
|
bzip2 -cd < %{SOURCE102} > $RPM_BUILD_ROOT%{_datadir}/cups/model/Postscript.ppd
|
|
|
|
# Source105: PSLEVEL1.PPD.bz2
|
|
|
|
bzip2 -cd < %{SOURCE105} > $RPM_BUILD_ROOT%{_datadir}/cups/model/Postscript-level1.ppd
|
|
|
|
# Source106: PSLEVEL2.PPD.bz2
|
|
|
|
bzip2 -cd < %{SOURCE106} > $RPM_BUILD_ROOT%{_datadir}/cups/model/Postscript-level2.ppd
|
2007-01-16 00:08:16 +01:00
|
|
|
find %{buildroot}/usr/share/cups/model -name "*.ppd" | while read FILE
|
2010-03-31 19:57:49 +02:00
|
|
|
do # Change default paper size from Letter to A4 if possible
|
2010-03-18 23:08:54 +01:00
|
|
|
# https://bugzilla.novell.com/show_bug.cgi?id=suse30662
|
|
|
|
# and delete trailing whitespace:
|
|
|
|
perl -pi -e 's:^(\*Default.*)Letter\s*$:$1A4\n:; \
|
|
|
|
s:^(\*ImageableArea A4.*\:\s+)"0 0 595 842":$1"24 48 571 818":; \
|
|
|
|
s:^(\*ImageableArea Letter.*\:\s+)"0 0 612 792":$1"24 48 588 768":; \
|
|
|
|
s:\s\n:\n:' "$FILE"
|
|
|
|
gzip -9 "$FILE"
|
2007-01-16 00:08:16 +01:00
|
|
|
done
|
2010-03-31 19:57:49 +02:00
|
|
|
# Add files for desktop menu:
|
2010-03-18 23:08:54 +01:00
|
|
|
rm -f $RPM_BUILD_ROOT/usr/share/applications/cups.desktop
|
2010-05-25 10:36:50 +02:00
|
|
|
%suse_update_desktop_file -i cups PrintingUtility 2>/dev/null
|
2007-01-16 00:08:16 +01:00
|
|
|
mkdir $RPM_BUILD_ROOT/usr/share/pixmaps
|
|
|
|
install -m 644 $RPM_BUILD_ROOT/usr/share/icons/hicolor/64x64/apps/cups.png $RPM_BUILD_ROOT/usr/share/pixmaps
|
|
|
|
rm -rf $RPM_BUILD_ROOT/usr/share/icons
|
2010-03-31 19:57:49 +02:00
|
|
|
# Remove unpackaged files:
|
2007-01-16 00:08:16 +01:00
|
|
|
rm -rf $RPM_BUILD_ROOT/%{_mandir}/es/cat?
|
|
|
|
rm -rf $RPM_BUILD_ROOT/%{_mandir}/fr/cat?
|
|
|
|
rm -rf $RPM_BUILD_ROOT/%{_mandir}/cat?
|
2010-03-31 19:57:49 +02:00
|
|
|
# Remove unknown locale directory:
|
2007-10-16 02:39:15 +02:00
|
|
|
rm -rf $RPM_BUILD_ROOT/usr/share/locale/no
|
2010-03-31 19:57:49 +02:00
|
|
|
# Run fdupes:
|
2009-09-21 20:58:48 +02:00
|
|
|
%fdupes $RPM_BUILD_ROOT
|
2007-01-16 00:08:16 +01:00
|
|
|
|
|
|
|
%clean
|
|
|
|
#test -n "$RPM_BUILD_ROOT" && rm -rf $RPM_BUILD_ROOT
|
|
|
|
|
|
|
|
%pre
|
|
|
|
/usr/sbin/groupadd -g 71 -o -r ntadmin 2>/dev/null || :
|
2010-03-31 19:57:49 +02:00
|
|
|
# exit successfully in any case:
|
|
|
|
exit 0
|
2007-01-16 00:08:16 +01:00
|
|
|
|
|
|
|
%post
|
2008-08-24 10:51:03 +02:00
|
|
|
%{fillup_and_insserv -ny cups cups}
|
2010-03-31 19:57:49 +02:00
|
|
|
# exit successfully in any case:
|
|
|
|
exit 0
|
2007-01-16 00:08:16 +01:00
|
|
|
|
|
|
|
%preun
|
|
|
|
%stop_on_removal cups
|
2010-03-31 19:57:49 +02:00
|
|
|
# exit successfully in any case:
|
|
|
|
exit 0
|
2007-01-16 00:08:16 +01:00
|
|
|
|
|
|
|
%postun
|
|
|
|
%restart_on_update cups
|
|
|
|
%{insserv_cleanup}
|
2010-03-31 19:57:49 +02:00
|
|
|
# exit successfully in any case:
|
|
|
|
exit 0
|
|
|
|
|
|
|
|
%post libs
|
|
|
|
/sbin/ldconfig
|
|
|
|
# exit successfully in any case:
|
|
|
|
exit 0
|
2010-03-31 19:57:30 +02:00
|
|
|
|
2010-03-31 19:57:49 +02:00
|
|
|
%postun libs
|
|
|
|
/sbin/ldconfig
|
|
|
|
# exit successfully in any case:
|
|
|
|
exit 0
|
|
|
|
|
|
|
|
# The files sections list all mandatory files explicitely one by one.
|
|
|
|
# In particular all executables are listed explicitely.
|
|
|
|
# This avoids that CUPS' configure magic might silently
|
|
|
|
# not build and install an executable when whatever condition
|
|
|
|
# for configure's automated tests is not fulfilled in the build system.
|
|
|
|
# See https://bugzilla.novell.com/show_bug.cgi?id=526847#c9
|
|
|
|
# (In CUPS 1.3.10 a configure magic did silently skip to build
|
|
|
|
# the pdftops filter when there was no /usr/bin/pdftops
|
|
|
|
# installed in the build system regardless of an explicite
|
|
|
|
# configure setting ' --with-pdftops=/usr/bin/pdftops',
|
|
|
|
# see also http://www.cups.org/str.php?L3278).
|
2010-04-28 22:21:38 +02:00
|
|
|
# When all mandatory files are explicitely listed,
|
2010-03-31 19:57:49 +02:00
|
|
|
# the build fails intentionally if a mandatory file was not built
|
|
|
|
# which ensures that already existing correctly built binary RPMs
|
|
|
|
# are not overwritten by broken RPMs where mandatory files are missing.
|
2010-03-31 19:57:30 +02:00
|
|
|
|
2007-01-16 00:08:16 +01:00
|
|
|
%files
|
|
|
|
%defattr(-,root,root)
|
2010-03-18 23:08:53 +01:00
|
|
|
%config(noreplace) %attr(640,root,lp) %{_sysconfdir}/cups/cupsd.conf
|
2010-05-07 15:35:59 +02:00
|
|
|
%{_sysconfdir}/cups/cupsd.conf.default
|
2010-03-18 23:08:53 +01:00
|
|
|
%config(noreplace) %attr(640,root,lp) %{_sysconfdir}/cups/snmp.conf
|
|
|
|
%config(noreplace) %attr(755,lp,lp) %{_sysconfdir}/cups/interfaces
|
|
|
|
%config(noreplace) %{_sysconfdir}/xinetd.d/cups-lpd
|
2010-03-18 23:08:54 +01:00
|
|
|
%config %attr(0755,root,root) %{_sysconfdir}/init.d/cups
|
|
|
|
%config %{_sysconfdir}/pam.d/cups
|
2010-05-07 15:35:59 +02:00
|
|
|
%config %{_sysconfdir}/dbus-1/system.d/cups.conf
|
2010-03-18 23:08:54 +01:00
|
|
|
%dir %attr(700,root,lp) %{_sysconfdir}/cups/ssl
|
|
|
|
%dir %attr(755,root,lp) %{_sysconfdir}/cups/ppd
|
|
|
|
/var/adm/fillup-templates/sysconfig.cups
|
2007-01-16 00:08:16 +01:00
|
|
|
%{_bindir}/cupstestppd
|
|
|
|
%{_sbindir}/cupsaddsmb
|
2007-10-16 02:39:15 +02:00
|
|
|
%{_sbindir}/cupsctl
|
2007-01-16 00:08:16 +01:00
|
|
|
%{_sbindir}/cupsd
|
2007-10-16 02:39:15 +02:00
|
|
|
%{_sbindir}/cupsfilter
|
2010-03-18 23:08:54 +01:00
|
|
|
%{_sbindir}/rccups
|
|
|
|
%dir /usr/lib/cups
|
|
|
|
%dir /usr/lib/cups/backend
|
|
|
|
/usr/lib/cups/backend/http
|
|
|
|
/usr/lib/cups/backend/ipp
|
|
|
|
/usr/lib/cups/backend/lpd
|
|
|
|
/usr/lib/cups/backend/parallel
|
|
|
|
/usr/lib/cups/backend/scsi
|
|
|
|
/usr/lib/cups/backend/serial
|
|
|
|
/usr/lib/cups/backend/snmp
|
|
|
|
/usr/lib/cups/backend/socket
|
|
|
|
/usr/lib/cups/backend/usb
|
|
|
|
%dir /usr/lib/cups/cgi-bin
|
|
|
|
/usr/lib/cups/cgi-bin/admin.cgi
|
|
|
|
/usr/lib/cups/cgi-bin/classes.cgi
|
|
|
|
/usr/lib/cups/cgi-bin/help.cgi
|
|
|
|
/usr/lib/cups/cgi-bin/jobs.cgi
|
|
|
|
/usr/lib/cups/cgi-bin/printers.cgi
|
|
|
|
%dir /usr/lib/cups/daemon
|
|
|
|
/usr/lib/cups/daemon/cups-deviced
|
|
|
|
/usr/lib/cups/daemon/cups-driverd
|
|
|
|
/usr/lib/cups/daemon/cups-lpd
|
|
|
|
/usr/lib/cups/daemon/cups-polld
|
|
|
|
%dir /usr/lib/cups/driver
|
|
|
|
%dir /usr/lib/cups/filter
|
|
|
|
/usr/lib/cups/filter/bannertops
|
|
|
|
/usr/lib/cups/filter/commandtoescpx
|
|
|
|
/usr/lib/cups/filter/commandtopclx
|
|
|
|
/usr/lib/cups/filter/commandtops
|
|
|
|
/usr/lib/cups/filter/gziptoany
|
|
|
|
/usr/lib/cups/filter/hpgltops
|
|
|
|
/usr/lib/cups/filter/imagetops
|
|
|
|
/usr/lib/cups/filter/imagetoraster
|
|
|
|
/usr/lib/cups/filter/pdftops
|
|
|
|
/usr/lib/cups/filter/pstops
|
|
|
|
/usr/lib/cups/filter/rastertodymo
|
|
|
|
/usr/lib/cups/filter/rastertoepson
|
|
|
|
/usr/lib/cups/filter/rastertoescpx
|
|
|
|
/usr/lib/cups/filter/rastertohp
|
|
|
|
/usr/lib/cups/filter/rastertolabel
|
|
|
|
/usr/lib/cups/filter/rastertopclx
|
|
|
|
/usr/lib/cups/filter/texttops
|
|
|
|
%dir /usr/lib/cups/monitor
|
|
|
|
/usr/lib/cups/monitor/bcp
|
|
|
|
/usr/lib/cups/monitor/tbcp
|
|
|
|
%dir /usr/lib/cups/notifier
|
2010-03-31 19:57:49 +02:00
|
|
|
/usr/lib/cups/notifier/dbus
|
2010-03-18 23:08:54 +01:00
|
|
|
/usr/lib/cups/notifier/mailto
|
|
|
|
/usr/lib/cups/notifier/rss
|
|
|
|
%dir %attr(0775,root,ntadmin) %{_datadir}/cups/drivers
|
|
|
|
%{_datadir}/applications/cups.desktop
|
|
|
|
%{_datadir}/pixmaps/cups.png
|
|
|
|
%doc %{_defaultdocdir}/cups
|
|
|
|
%doc %{_mandir}/man1/cupstestppd.1.gz
|
|
|
|
%doc %{_mandir}/man5/classes.conf.5.gz
|
|
|
|
%doc %{_mandir}/man5/client.conf.5.gz
|
|
|
|
%doc %{_mandir}/man5/cups-snmp.conf.5.gz
|
|
|
|
%doc %{_mandir}/man5/cupsd.conf.5.gz
|
|
|
|
%doc %{_mandir}/man5/mailto.conf.5.gz
|
|
|
|
%doc %{_mandir}/man5/mime.convs.5.gz
|
|
|
|
%doc %{_mandir}/man5/mime.types.5.gz
|
|
|
|
%doc %{_mandir}/man5/printers.conf.5.gz
|
|
|
|
%doc %{_mandir}/man5/subscriptions.conf.5.gz
|
|
|
|
%doc %{_mandir}/man7/backend.7.gz
|
|
|
|
%doc %{_mandir}/man7/drv.7.gz
|
|
|
|
%doc %{_mandir}/man7/filter.7.gz
|
|
|
|
%doc %{_mandir}/man7/notifier.7.gz
|
|
|
|
%doc %{_mandir}/man8/cups-deviced.8.gz
|
|
|
|
%doc %{_mandir}/man8/cups-driverd.8.gz
|
|
|
|
%doc %{_mandir}/man8/cups-lpd.8.gz
|
|
|
|
%doc %{_mandir}/man8/cups-polld.8.gz
|
|
|
|
%doc %{_mandir}/man8/cupsaddsmb.8.gz
|
|
|
|
%doc %{_mandir}/man8/cupsctl.8.gz
|
|
|
|
%doc %{_mandir}/man8/cupsd.8.gz
|
|
|
|
%doc %{_mandir}/man8/cupsfilter.8.gz
|
|
|
|
%{_datadir}/cups/
|
|
|
|
%exclude %{_datadir}/cups/ppdc/
|
2007-01-16 00:08:16 +01:00
|
|
|
|
2010-03-31 19:57:49 +02:00
|
|
|
# Set explicite owner, group, and permissions for lppasswd
|
|
|
|
# to enforce to have the upstream owner, group, and permissions in the RPM
|
|
|
|
# because otherwise our build magic /usr/sbin/Check sets them to lp:lp 2755
|
|
|
|
# according to /etc/permissions.secure in the build system,
|
|
|
|
# see https://bugzilla.novell.com/show_bug.cgi?id=574336#c12
|
|
|
|
# and subsequent comments up to comment #17 therein.
|
|
|
|
# Even if /etc/permissions.secure in the openSUSE:Factory build system might be
|
|
|
|
# already fixed, it must also work for build systems for released products.
|
|
|
|
|
2007-01-16 00:08:16 +01:00
|
|
|
%files client
|
|
|
|
%defattr(-,root,root)
|
2010-03-18 23:08:54 +01:00
|
|
|
%{_bindir}/cancel
|
|
|
|
%{_bindir}/cupstestdsc
|
2007-01-16 00:08:16 +01:00
|
|
|
%{_bindir}/lp
|
|
|
|
%{_bindir}/lpoptions
|
2010-03-31 19:57:49 +02:00
|
|
|
%attr(0555,root,root) %{_bindir}/lppasswd
|
2007-01-16 00:08:16 +01:00
|
|
|
%{_bindir}/lpq
|
|
|
|
%{_bindir}/lpr
|
|
|
|
%{_bindir}/lprm
|
|
|
|
%{_bindir}/lpstat
|
|
|
|
%{_sbindir}/accept
|
2010-03-18 23:08:54 +01:00
|
|
|
%{_sbindir}/cupsaccept
|
|
|
|
%{_sbindir}/cupsdisable
|
|
|
|
%{_sbindir}/cupsenable
|
|
|
|
%{_sbindir}/cupsreject
|
|
|
|
%{_sbindir}/lpadmin
|
|
|
|
%{_sbindir}/lpc
|
|
|
|
%{_sbindir}/lpinfo
|
|
|
|
%{_sbindir}/lpmove
|
2007-01-16 00:08:16 +01:00
|
|
|
%{_sbindir}/reject
|
2010-03-18 23:08:54 +01:00
|
|
|
%doc %{_mandir}/man1/cancel.1.gz
|
|
|
|
%doc %{_mandir}/man1/cupstestdsc.1.gz
|
|
|
|
%doc %{_mandir}/man1/lp.1.gz
|
|
|
|
%doc %{_mandir}/man1/lpoptions.1.gz
|
|
|
|
%doc %{_mandir}/man1/lppasswd.1.gz
|
|
|
|
%doc %{_mandir}/man1/lpq.1.gz
|
|
|
|
%doc %{_mandir}/man1/lpr.1.gz
|
|
|
|
%doc %{_mandir}/man1/lprm.1.gz
|
|
|
|
%doc %{_mandir}/man1/lpstat.1.gz
|
|
|
|
%doc %{_mandir}/man8/accept.8.gz
|
|
|
|
%doc %{_mandir}/man8/cupsaccept.8.gz
|
|
|
|
%doc %{_mandir}/man8/cupsdisable.8.gz
|
|
|
|
%doc %{_mandir}/man8/cupsenable.8.gz
|
|
|
|
%doc %{_mandir}/man8/cupsreject.8.gz
|
|
|
|
%doc %{_mandir}/man8/lpadmin.8.gz
|
|
|
|
%doc %{_mandir}/man8/lpc.8.gz
|
|
|
|
%doc %{_mandir}/man8/lpinfo.8.gz
|
|
|
|
%doc %{_mandir}/man8/lpmove.8.gz
|
|
|
|
%doc %{_mandir}/man8/reject.8.gz
|
2007-01-16 00:08:16 +01:00
|
|
|
|
|
|
|
%files devel
|
|
|
|
%defattr(-,root,root)
|
2010-03-18 23:08:54 +01:00
|
|
|
%{_includedir}/cups/
|
2007-05-25 00:40:10 +02:00
|
|
|
%{_libdir}/libcups.so
|
|
|
|
%{_libdir}/libcupsimage.so
|
2010-03-18 23:08:54 +01:00
|
|
|
%{_libdir}/libcupscgi.so
|
|
|
|
%{_libdir}/libcupsdriver.so
|
|
|
|
%{_libdir}/libcupsmime.so
|
|
|
|
%{_libdir}/libcupsppdc.so
|
|
|
|
%{_datadir}/cups/ppdc/
|
|
|
|
|
|
|
|
%files ddk
|
|
|
|
%defattr(-,root,root)
|
|
|
|
%{_bindir}/ppdc
|
|
|
|
%{_bindir}/ppdhtml
|
|
|
|
%{_bindir}/ppdi
|
|
|
|
%{_bindir}/ppdmerge
|
|
|
|
%{_bindir}/ppdpo
|
|
|
|
%doc %{_mandir}/man1/ppdc.1.gz
|
|
|
|
%doc %{_mandir}/man1/ppdhtml.1.gz
|
|
|
|
%doc %{_mandir}/man1/ppdi.1.gz
|
|
|
|
%doc %{_mandir}/man1/ppdmerge.1.gz
|
|
|
|
%doc %{_mandir}/man1/ppdpo.1.gz
|
|
|
|
%doc %{_mandir}/man5/ppdcfile.5.gz
|
2007-01-16 00:08:16 +01:00
|
|
|
|
|
|
|
%files libs
|
|
|
|
%defattr(-,root,root)
|
2010-03-18 23:08:54 +01:00
|
|
|
%config(noreplace) %{_sysconfdir}/cups/client.conf
|
2008-01-17 22:30:43 +01:00
|
|
|
%dir %attr(0710,root,lp) %{_var}/spool/cups
|
|
|
|
%dir %attr(1770,root,lp) %{_var}/spool/cups/tmp
|
2007-01-16 00:08:16 +01:00
|
|
|
%dir %attr(0755,lp,lp) %{_var}/log/cups/
|
2010-03-18 23:08:54 +01:00
|
|
|
%dir %attr(0775,lp,lp) %{_var}/cache/cups
|
|
|
|
%{_bindir}/cups-config
|
2007-05-25 00:40:10 +02:00
|
|
|
%{_libdir}/libcups.so.*
|
2010-03-18 23:08:54 +01:00
|
|
|
%{_libdir}/libcupscgi.so.*
|
|
|
|
%{_libdir}/libcupsdriver.so.*
|
2007-05-25 00:40:10 +02:00
|
|
|
%{_libdir}/libcupsimage.so.*
|
2010-03-18 23:08:54 +01:00
|
|
|
%{_libdir}/libcupsmime.so.*
|
|
|
|
%{_libdir}/libcupsppdc.so.*
|
2007-01-16 00:08:16 +01:00
|
|
|
%{_datadir}/locale/*/cups_*
|
2010-03-18 23:08:54 +01:00
|
|
|
%doc %{_mandir}/man1/cups-config.1.gz
|
2007-12-18 18:29:38 +01:00
|
|
|
|
2007-02-23 12:29:03 +01:00
|
|
|
%changelog
|