--- /dev/null
+diff -Nur dictd-1.5.5.orig/configure.in dictd-1.5.5/configure.in
+--- dictd-1.5.5.orig/configure.in Sat Nov 17 20:19:56 2001
++++ dictd-1.5.5/configure.in Sat Nov 17 20:20:57 2001
+@@ -42,21 +42,12 @@
+ echo Configuring for dict
+ echo .
+
+-AC_ARG_WITH(cc,
+-[ --with-cc with cc (instead of gcc)],
+-[
+-if test "x${withval}" = xyes; then
+- CC=cc
+-fi
+-])
+-
+ AC_CANONICAL_HOST
+ AC_PROG_CC
+ AC_ISC_POSIX
+
+ REALCC="$CC"
+ if test "$CC" = gcc; then
+- CFLAGS='-g -O'
+ WCFLAGS='-Wall'
+ case "$host" in
+ dnl did include: -Winline
+@@ -68,18 +59,12 @@
+ esac
+ # Silence flex/bison output
+ SCFLAGS="-Wno-implicit -Wno-unused"
+-else
+- CFLAGS='-g'
+ fi
+
+ local_dmalloc=0
+ local_libmaa=0
+ local_zlib=0
+
+-AC_ARG_WITH(cflags,
+-[ --with-cflags=FLAGS use FLAGS for CFLAGS],
+-CFLAGS="$withval")
+-
+ AC_ARG_WITH(prof,
+ [ --with-prof with prof profiling],
+ [
+diff -Nur dictd-1.5.5.orig/libmaa/configure.in dictd-1.5.5/libmaa/configure.in
+--- dictd-1.5.5.orig/libmaa/configure.in Mon Jul 6 00:14:34 1998
++++ dictd-1.5.5/libmaa/configure.in Sat Nov 17 20:21:30 2001
+@@ -43,24 +43,13 @@
+ echo Configuring for libmaa $MAA_MAJOR.$MAA_MINOR
+ echo .
+
+-AC_ARG_WITH(cc,
+-[ --with-cc with cc (instead of gcc)],
+-[
+-if test "x${withval}" = xyes; then
+- CC=cc
+-fi
+-])
+-
+ AC_CANONICAL_HOST
+ AC_PROG_CC
+ AC_ISC_POSIX
+
+ REALCC="$CC"
+ if test "$CC" = gcc; then
+- CFLAGS='-g -O'
+ WCFLAGS='-Wall -pedantic'
+-else
+- CFLAGS='-g'
+ fi
+
+ needs_xmalloc=1
+@@ -75,14 +64,6 @@
+ WCFLAGS="$WCFLAGS -pipe";;
+ esac
+
+-AC_ARG_WITH(cflags,
+-[ --with-cflags=FLAGS use FLAGS for CFLAGS],
+-[
+-if test "x${withval}" = xyes; then
+- CFLAGS="$withval"
+-fi
+-])
+-
+ AC_ARG_WITH(prof,
+ [ --with-prof with prof profiling],
+ [
--- /dev/null
+--- dictd-1.5.5/configure.in.orig Sat Nov 17 20:06:54 2001
++++ dictd-1.5.5/configure.in Sat Nov 17 20:13:23 2001
+@@ -205,7 +205,6 @@
+ fi
+
+ dnl Always use local libz to avoid problems with header files
+-local_zlib=1
+ if test "$local_zlib" = 0; then
+ AC_CHECK_LIB(z,zlibVersion,REALLIBS="$REALLIBS -lz",local_zlib=1)
+ fi
Summary(pl): Serwer bazy s³owników
Name: dictd
Version: 1.5.5
-Release: 3
+Release: 4
License: GPL
Group: Daemons
Group(de): Server
Source1: %{name}.init
Source2: %{name}.sysconfig
Patch0: %{name}-no_libnsl.patch
+Patch1: %{name}-system-zlib.patch
+Patch2: %{name}-opt.patch
URL: http://www.dict.org/
BuildRequires: autoconf
BuildRequires: automake
BuildRequires: flex
+BuildRequires: bison
+BuildRequires: zlib-devel
Prereq: /sbin/chkconfig
BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
%prep
%setup -q
%patch0 -p1
+%patch1 -p1
+%patch2 -p1
%build
-# --without-local-zlib option gives no effect. Usage of zlib from dictd tarball
-# is hardcoded in configure.
-#
aclocal
autoconf
(cd libmaa; aclocal; autoconf)
-%configure \
- --with-local-zlib=no
+%configure
+
%{__make}
%install
install -d $RPM_BUILD_ROOT{/etc/{rc.d/init.d,sysconfig,%{name}},%{_bindir},%{_sbindir}} \
$RPM_BUILD_ROOT{%{_datadir}/%{name},%{_mandir}/man{1,8}}
-install dict dictzip $RPM_BUILD_ROOT/%{_bindir}
-install {dict,dictzip}.1 $RPM_BUILD_ROOT/%{_mandir}/man1
+install dict dictzip $RPM_BUILD_ROOT%{_bindir}
+install {dict,dictzip}.1 $RPM_BUILD_ROOT%{_mandir}/man1
-install %{name} $RPM_BUILD_ROOT/%{_sbindir}
-install %{name}.8 $RPM_BUILD_ROOT/%{_mandir}/man8
+install %{name} $RPM_BUILD_ROOT%{_sbindir}
+install %{name}.8 $RPM_BUILD_ROOT%{_mandir}/man8
echo "server localhost" > dict.conf
echo -e "access {\n\tallow localhost\n\tdeny *\n}\n" > %{name}-main.conf
install dict.conf $RPM_BUILD_ROOT%{_sysconfdir}
install dictd-main.conf $RPM_BUILD_ROOT%{_sysconfdir}/%{name}
-touch %{buildroot}%{_sysconfdir}/%{name}.conf
+touch $RPM_BUILD_ROOT%{_sysconfdir}/%{name}.conf
install %{SOURCE1} $RPM_BUILD_ROOT/etc/rc.d/init.d/%{name}
install %{SOURCE2} $RPM_BUILD_ROOT/etc/sysconfig/%{name}
%post
/sbin/chkconfig --add %{name}
-if [ -f /var/lock/subsystem/%{name} ]; then
+if [ -f /var/lock/subsys/%{name} ]; then
/etc/rc.d/init.d/%{name} restart >&2
else
echo "Run \"/etc/rc.d/init.d/%{name} start\" to start %{name} daemon."