]> git.pld-linux.org Git - packages/dictd.git/blob - dictd.spec
- added no_libnsl patch.
[packages/dictd.git] / dictd.spec
1 Summary:        Dictionary database server
2 Summary(pl):    Serwer bazy s³owników
3 Name:           dictd
4 Version:        1.5.5
5 Release:        3
6 License:        GPL
7 Group:          Daemons
8 Group(de):      Server
9 Group(pl):      Serwery
10 Source0:        ftp://ftp.dict.org/pub/dict/%{name}-%{version}.tar.gz
11 Source1:        %{name}.init
12 Source2:        %{name}.sysconfig
13 Patch0:         %{name}-no_libnsl.patch
14 URL:            http://www.dict.org/
15 BuildRequires:  autoconf
16 BuildRequires:  automake
17 BuildRequires:  flex
18 Prereq:         /sbin/chkconfig
19 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
20
21 %description 
22 Server for the Dictionary Server Protocol (DICT), a TCP transaction
23 based query/response protocol that allows a client to access
24 dictionary definitions from a set of natural language dictionary
25 databases.
26
27 %description -l pl
28 Serwer dla Dictionary Server Protocol(DICT), bazuj±cego na TCP
29 protoko³u zapytañ i odpowiedzi umo¿liwiaj±cego klientom na dostêp do
30 definicji s³ownikowych z zestawu baz danych.
31
32 %package -n dict
33 Summary:        DICT Protocol Client
34 Summary(pl):    Klient protoko³u DICT
35 Group:          Applications/Networking
36 Group(de):      Applikationen/Netzwerkwesen
37 Group(pl):      Aplikacje/Sieciowe
38
39 %description -n dict
40 Client for the Dictionary Server Protocol (DICT), a TCP transaction
41 based query/response protocol that provides access to dictionary
42 definitions from a set of natural language dictionary databases.
43
44 %description -n dict -l pl
45 Klient dla Dictionary Server Protocol(DICT), bazuj±cego na TCP
46 protoko³u zapytañ i odpowiedzi umo¿liwiaj±cego klientom na dostêp do
47 definicji s³ownikowych z zestawu baz danych.
48
49 %package -n dictzip
50 Summary:        Compress (or expand) files, allowing random access
51 Summary(pl):    Kompresja (i dekompresja) plików pozwalaj±ca na swobodny dostêp
52 Group:          Applications/Archiving
53 Group(de):      Applikationen/Archivierung
54 Group(pl):      Aplikacje/Archiwizacja
55
56 %description -n dictzip
57 dictzip compresses files using the gzip(1) algorithm (LZ77) in a
58 manner which is completely compatible with the gzip file format. An
59 extension to the gzip file format (Extra Field, described in 2.3.1.1
60 of RFC 1952) allows extra data to be stored in the header of a
61 compressed file. Dictd, the DICT protocol dictionary server will make
62 use of this data to perform pseudo-random access on the file.
63
64 %description -n dictzip -l pl
65 dictzip kompresuje pliki korzystaj±c z zawartego w gzip(1) algorytmu
66 (LZ77) który jest ca³kowicie kompatybilny z formatem plików gzip.
67 Rozszerzenie do formatu plików gzip (pole dodatkowe, opisane w 2.3.1.1
68 RFC 1952) pozwalaj±cego na dodatkowe dane zapisane w nag³ówku
69 skompresowanego pliku. Dictd, serwer protoko³u DICT wykorzystuje te
70 dane do pseudo-swobodnego dostêpu do pliku.
71
72 %prep
73 %setup -q
74 %patch0 -p1
75
76 %build
77 # --without-local-zlib option gives no effect. Usage of zlib from dictd tarball 
78 # is hardcoded in configure. 
79
80 aclocal
81 autoconf
82 (cd libmaa; aclocal; autoconf)
83 %configure \
84         --with-local-zlib=no
85 %{__make}
86
87 %install
88 rm -rf $RPM_BUILD_ROOT
89 install -d $RPM_BUILD_ROOT{/etc/{rc.d/init.d,sysconfig,%{name}},%{_bindir},%{_sbindir}} \
90            $RPM_BUILD_ROOT{%{_datadir}/%{name},%{_mandir}/man{1,8}}
91
92 install dict dictzip $RPM_BUILD_ROOT/%{_bindir}
93 install {dict,dictzip}.1 $RPM_BUILD_ROOT/%{_mandir}/man1
94
95 install %{name} $RPM_BUILD_ROOT/%{_sbindir}
96 install %{name}.8 $RPM_BUILD_ROOT/%{_mandir}/man8
97
98 echo "server localhost" > dict.conf
99 echo -e "access {\n\tallow localhost\n\tdeny *\n}\n" > %{name}-main.conf 
100
101 install dict.conf $RPM_BUILD_ROOT%{_sysconfdir}
102 install dictd-main.conf $RPM_BUILD_ROOT%{_sysconfdir}/%{name}
103 touch %{buildroot}%{_sysconfdir}/%{name}.conf
104 install %{SOURCE1} $RPM_BUILD_ROOT/etc/rc.d/init.d/%{name}
105 install %{SOURCE2} $RPM_BUILD_ROOT/etc/sysconfig/%{name}
106
107 mv -f doc/security.doc security.txt
108 gzip -9nf {ANNOUNCE,ChangeLog,README,TODO,%{name}.conf,example*.conf,example.site,security.txt}
109
110 %clean
111 rm -rf $RPM_BUILD_ROOT
112
113 %post
114 /sbin/chkconfig --add %{name}
115 if [ -f /var/lock/subsystem/%{name} ]; then
116         /etc/rc.d/init.d/%{name} restart >&2
117 else
118         echo "Run \"/etc/rc.d/init.d/%{name} start\" to start %{name} daemon."
119 fi
120     
121 %preun
122 if [ "$1" = "0" ]; then
123         if [ -f /var/lock/subsys/%{name} ]; then
124                 /etc/rc.d/init.d/%{name} stop >&2
125         fi
126         /sbin/chkconfig --del %{name}
127 fi
128
129 %files
130 %defattr(644,root,root,755)
131 %doc *.gz
132 %ghost %{_sysconfdir}/%{name}.conf
133 %attr(755,root,root) %{_sbindir}/%{name}
134 %attr(754,root,root) /etc/rc.d/init.d/%{name}
135 %config(noreplace) %verify(not size mtime md5) %{_sysconfdir}/sysconfig/%{name}
136 %dir %{_datadir}/%{name}
137 %dir %{_sysconfdir}/%{name}
138 %{_sysconfdir}/%{name}/%{name}-main.conf
139 %{_mandir}/man8/%{name}*
140
141 %files -n dict
142 %defattr(644,root,root,755)
143 %config(noreplace) %verify(not size mtime md5) %{_sysconfdir}/dict.conf
144 %attr(755,root,root) %{_bindir}/dict
145 %{_mandir}/man1/dict.1*
146
147 %files -n dictzip
148 %defattr(644,root,root,755)
149 %attr(755,root,root) %{_bindir}/dictzip
150 %{_mandir}/man1/dictzip.1*
This page took 0.060445 seconds and 4 git commands to generate.