Summary(uk): óÐÕÌÅÒ ÄÒÕËÕ LPRng
Summary(zh_CN): LPRng--´òÓ¡³ÌÐò
Name: LPRng
-Version: 3.8.22
-Release: 1
+Version: 3.8.28
+Release: 2
License: GPL or Artistic
Group: Applications/System
Source0: ftp://ftp.lprng.com/pub/LPRng/LPRng/%{name}-%{version}.tgz
-# Source0-md5: ac7742d87433ea6908517ddb3b8a648a
+# Source0-md5: 1b3a0abd291b260eab6087ac0e61ed84
Source1: %{name}.init
Source2: %{name}.conf
Source3: %{name}.printcap
Patch3: %{name}-missing-nls.patch
Patch4: %{name}-pl.po.patch
Patch5: %{name}-types.patch
+Patch6: %{name}-shell.patch
URL: http://www.lprng.com/
BuildRequires: autoconf
BuildRequires: automake
BuildRequires: gettext-devel
BuildRequires: libtool
-BuildRequires: openssl-devel
-PreReq: rc-scripts >= 0.2.0
+BuildRequires: openssl-devel >= 0.9.7d
+BuildRequires: rpmbuild(macros) >= 1.268
Requires(post): /sbin/ldconfig
Requires(post,preun): /sbin/chkconfig
-Obsoletes: lpr
+Requires: rc-scripts >= 0.2.0
Obsoletes: cups
Obsoletes: cups-clients
+Obsoletes: lpr
BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
+%define filterout_ld -Wl,--as-needed
+
%description
The LPRng software is an enhanced, extended, and portable
implementation of the Berkeley LPR print spooler functionality. While
%patch3 -p1
%patch4 -p1
%patch5 -p1
+%patch6 -p1
+
+rm -rf autom4te.cache
+mv PrintingCookbook/{HTML,PrintingCookbook}
%build
%{__gettextize}
%{__aclocal}
%{__autoconf}
cp -f /usr/share/automake/{config.*,missing} .
-#PSHOWALL="-ax"; export PSHOWALL
# now it wants to use /etc/lpd/lpd.{conf,perms} - stick to old values?
%configure \
OPENSSL=/usr/bin/openssl \
--with-lpd_perms_path=%{_sysconfdir}/lpd.perms \
--with-done_jobs=0
-%{__make}
+%{__make} -j1
%{__make} -C man
%install
install %{SOURCE1} $RPM_BUILD_ROOT/etc/rc.d/init.d/lpd
# yes, overwrite distribution lpd.conf
install %{SOURCE2} $RPM_BUILD_ROOT%{_sysconfdir}/lpd.conf
-echo "default_printer = lp" >>$RPM_BUILD_ROOT%{_sysconfdir}/lpd.conf
+echo "default_printer = lp" >> $RPM_BUILD_ROOT%{_sysconfdir}/lpd.conf
install %{SOURCE3} $RPM_BUILD_ROOT%{_sysconfdir}/printcap
install lpd.perms $RPM_BUILD_ROOT%{_sysconfdir}
-# default spool
bzip2 -dc %{SOURCE4} | tar xf - -C $RPM_BUILD_ROOT%{_mandir}
-mv -f PrintingCookbook/{HTML,PrintingCookbook}
+rm -f $RPM_BUILD_ROOT%{_libdir}/liblpr.{la,a}
%find_lang %{name}
%post
/sbin/ldconfig
/sbin/chkconfig --add lpd
-if [ -f /var/lock/subsys/lpd ]; then
- /etc/rc.d/init.d/lpd restart 1>&2
-else
- echo "Run \"/etc/rc.d/init.d/lpd start\" to start LPRng lpd daemon."
-fi
+%service lpd restart "LPRng lpd daemon"
%preun
if [ "$1" = "0" ]; then
- if [ -f /var/lock/subsys/lpd ]; then
- /etc/rc.d/init.d/lpd stop 1>&2
- fi
/sbin/chkconfig --del lpd
+ %service lpd stop
fi
%postun -p /sbin/ldconfig
%defattr(644,root,root,755)
%doc CHANGES CONTRIBUTORS COPYRIGHT README README.SSL* TODO
%doc DOCS/LPRng-Reference-Multipart PrintingCookbook/PrintingCookbook
-%config(noreplace) %verify(not size mtime md5) %{_sysconfdir}/lpd.conf
-%config(noreplace) %verify(not size mtime md5) %{_sysconfdir}/lpd.perms
-%config(noreplace) %verify(not size mtime md5) %{_sysconfdir}/printcap
+%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/lpd.conf
+%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/lpd.perms
+%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/printcap
%dir %{_sysconfdir}/lpd
# what perms?
%attr(750,root,lp) %dir %{_sysconfdir}/lpd/ssl.ca