hplip/hpijs-standalone.spec

174 lines
8.2 KiB
RPMSpec

#
# spec file for package hpijs-standalone (Version 1.7.4a)
#
# Copyright (c) 2007 SUSE LINUX Products GmbH, Nuernberg, Germany.
# This file and all modifications and additions to the pristine
# package are under the same license as the package itself.
#
# Please submit bugfixes or comments via http://bugs.opensuse.org/
#
# norootforbuild
Name: hpijs-standalone
BuildRequires: gcc-c++ libjpeg-devel
Summary: HPIJS stand-alone
# HPLIP has reached 1.0 status. With this release a date encoded revision number is used:
# x.y.m : x = major release number, y = year (eg: 6 = 2006), m = month (eg: 6a = second release in June)
# Official releases have a 3 digit number and release candidates have a 4 digit number: x.y.m.rc
Version: 1.7.4a
Release: 1
Group: Hardware/Printing
License: BSD License and BSD-like
URL: http://hpinkjet.sourceforge.net/
# Source0...Source9 is for sources from HP:
# URL for Source0: http://switch.dl.sourceforge.net/sourceforge/hplip/hplip-1.7.4a.tar.gz
Source0: hplip-%{version}.tar.bz2
# Patch0...Patch9 is for patches from HP:
# Patch10...Patch99 is for Suse patches for the sources from HP:
# The patch numbers are the same as in hplip.spec.
# Source100... is for special Suse sources:
# The source numbers are the same as in hplip.spec.
# Source102 is a small man page for /usr/bin/hpijs:
Source102: hpijs.1.gz
# Install into this non-root directory (required when norootforbuild is used):
BuildRoot: %{_tmppath}/%{name}-%{version}-build
# Mutual RPM package requirements are meanwhile considered to be bad because
# such cyclic dependencies which makes it harder to automatically solve dependencies.
# Actually the hpijs driver requires Ghostscript (i.e ghostscript_any, e.g. ghostscript-library).
# But ghostscript-library must also require the hpijs driver which is the more imortant requirement
# because when a user (or a printer setup tool) wants to set up a HP printer with the hpijs driver
# it must be 100% sure that all what the hpijs driver needs to run is also installed.
# Therefore the requirement is weakened for this package:
Supplements: ghostscript_any
# hplip-hpijs, hplip17-hpijs, and hplip-hpijs-standalone contain /usr/bin/hpijs:
Conflicts: hplip-hpijs hplip17-hpijs
# Skip testing devel dependencies required by libtool .la files by the following comment:
# skip-check-libtool-deps
%description
HPIJS is a Ghostscript printer driver for HP printers.
This package includes a special version of the hpijs binary which
neither needs a HPLIP library nor a CUPS library to run it. Therefore
it conflicts with the hpijs binary in the hplip-hpijs package. For
special cases (e.g. for LPRng/lpdfilter or for a minimal printing
system or for printing without any printing system) it is possible to
use only this hpijs binary and Ghostscript.
For full documentation and license see the package hplip.
Authors:
--------
David Suffield <david.suffield@hp.com>
Cory Meisch <cory.meisch@hp.com>
Yie Shiyun <shiyun.yie@hp.com>
Donald J. Welch <donald.welch@hp.com>
Cauligi Raghothama S. <raghothama.cauligi@hp.com>
%prep
# Be quiet when unpacking:
%setup -q -n hplip-%{version}
%build
# If AUTOMAKE='automake --foreign' is not set, autoreconf (in fact automake)
# complains about missing files like NEWS, README, AUTHORS, ChangeLog
# in each directory where a Makefile.am exists:
AUTOMAKE='automake --foreign' autoreconf --force --install
# Set our preferred architecture-specific flags for the compiler and linker:
export CFLAGS="$RPM_OPT_FLAGS"
export CXXFLAGS="$RPM_OPT_FLAGS -fno-strict-aliasing"
# We build a special hpijs which does not require the CUPS library.
# One of the HPLIP authors David Suffield told me in a mail:
# > To: Johannes Meixner <jsmeix@suse.de>, <hplip-devel@lists.sourceforge.net>
# > Subject: RE: [HPLIP-Devel] /usr/bin/hpijs requires libcups.so
# > If you want to build hpijs with-out the libcups.so dependency, build
# > hpijs with-out hplip support.
# > For example if you want to build hpijs for use with other spoolers,
# > don't use the top-level hplip makefile, use configure/make in the hpijs
# > directory. There is a hpijs configure time "hplip-build" flag that
# > defaults to false if you don't use the top-level make file.
# To avoid that too much is built (e.g. the full documentation from higher directories)
# the specific make target "make hpijs" is called.
# Regarding the configure options see tech_docs/tarball_install.html (not very explanatory):
# --disable-rpm-install disables sane, icon, /etc/hp and /etc/init.d install (default=disabled)
# --disable-foomatic-install disables foomatic install (HPIJS option, default=enabled)
# --disable-cups-install disables cups install (HPIJS option, default=enabled)
# CUPS install would do:
# (1) remove any old HP HPIJS PPD files from the CUPS PPD directory
# (2) symlink the HP HPIJS PPD files to the CUPS PPD directory
# (3) symlink foomatic-rip to the CUPS filter directory.
# --disable-network-build disables network support, will not link with libsnmp (default=enabled)
# --disable-pp-build disables parallel port support (default=enabled)
# --enable-scan-build enable scanner build (default=yes)
# --enable-gui-build enable gui build (default=yes)
# --enable-fax-build enable fax build (default=yes)
# --disable-cups11-build disable CUPS 1.1 hp/hpfax device discovery message (default=disabled)
# --enable-cups11-build results a "no_device_found" message
# --disable-cups11-build results depend on the following conditions:
# Condition 1 (no HPLIP daemons):
# output nothing on stdout, exit 1
# Condition 2 (no HP device found):
# direct hp "Unknown" "HP Printer (HPLIP)", exit 0
# Condition 3 (HP device found):
# direct hp:/... "HP model" "HP model (HPLIP)" "DeviceID", exit 0
# rpm-install is no longer needed because "make install DESTDIR=/tmp/myhplip" works correctly now.
# disable-cups-install avoids useless stuff when building a RPM.
pushd prnt/hpijs
./configure --prefix=/usr --libdir=%_libdir --disable-hplip-build --disable-cups-install --disable-foomatic-install
make hpijs
popd
%install
# Install only the hpijs binary ("make install" would install full HPLIP documentation):
install -d %{buildroot}%{_bindir}
install -m 755 prnt/hpijs/hpijs %{buildroot}%{_bindir}
# Install the man page for /usr/bin/hpijs:
install -d %{buildroot}%{_mandir}/man1
install -m 644 %{SOURCE102} %{buildroot}%{_mandir}/man1/
%post
/sbin/ldconfig
exit 0
%files
%defattr(-, root, root)
%doc doc/tech_docs/hpijs.html doc/tech_docs/device_classes.html
%doc %{_mandir}/man1/hpijs.1.gz
%{_bindir}/hpijs
%changelog
* Fri Apr 27 2007 - jsmeix@suse.de
- Updated to version 1.7.4a:
Resolved a build issue that caused a couple missing files
in the 1.7.4 release (no Suse bug).
* Mon Apr 23 2007 - jsmeix@suse.de
- Updated to version 1.7.4:
Many bug fixes (no Suse bugs).
Some more supported DeskJet printers.
* Mon Mar 26 2007 - jsmeix@suse.de
- Updated to version 1.7.3:
Many bug fixes (no Suse bugs).
No new supported models but enhancements for some models.
* Thu Mar 01 2007 - jsmeix@suse.de
- Updated to version 1.7.2:
Several more supported Officejet Pro devices.
New OJProKx50 device class (derived from DJGenericVIP).
Many bug fixes (no Suse bugs).
fix-buffer-overflow.patch and hplip-1.7.1-1.patch are no longer
needed because the bugs are now fixed in the sources.
* Fri Feb 16 2007 - jsmeix@suse.de
- Re-enabled "Supplements: ghostscript_any" because
bug #243595 is fixed now.
* Mon Feb 12 2007 - aj@suse.de
- Do not add supplements to temporary workaround bug #243595.
* Mon Feb 05 2007 - jsmeix@suse.de
- fix-buffer-overflow.patch fixes a too small string buffer
which overflows in line 310 in ljcolor.cpp.
* Thu Feb 01 2007 - jsmeix@suse.de
- Created new package hpijs-standalone and hpijs-standalone.spec
for a special version of /usr/bin/hpijs which neither needs
a HPLIP library nor a CUPS library to run it.