]> git.pld-linux.org Git - packages/dict-freedict.git/blob - dict-freedict.spec
89e55e77e8153f0a27cc5fab3cab7d127e9da6fb
[packages/dict-freedict.git] / dict-freedict.spec
1 %define     dictname    freedict
2 %define      dict1    afr-deu
3 %define      dict2    cze-eng
4 %define      dict3    dan-eng
5 %define      dict4    deu-eng
6 %define      dict5    deu-fra
7 %define      dict6    deu-ita
8 #%define      dict7    deu-nld
9 %define      dict8    deu-por
10 %define      dict9    eng-deu
11 %define      dict10    eng-fra
12 %define      dict11    eng-hun
13 %define      dict12    eng-iri
14 %define      dict13    eng-ita
15 %define      dict14    eng-lat
16 %define      dict15    eng-nld
17 %define      dict16    eng-por
18 %define      dict17    eng-rus
19 %define      dict18    eng-scr
20 %define      dict19    eng-spa
21 %define      dict20    eng-swe
22 %define      dict21    eng-wel
23 %define      dict22    fra-deu
24 %define      dict23    fra-eng
25 %define      dict24    fra-nld
26 %define      dict25    gre-deu
27 %define      dict26    hun-eng
28 %define      dict27    iri-eng
29 %define      dict28    ita-deu
30 %define      dict29    ita-eng
31 %define      dict30    jpn-deu
32 %define      dict31    lat-deu
33 %define      dict32    lat-eng
34 %define      dict33    nld-deu
35 %define      dict34    nld-eng
36 %define      dict35    nld-fra
37 %define      dict36    por-deu
38 %define      dict37    por-eng
39 %define      dict38    sco-deu
40 %define      dict39    scr-eng
41 %define      dict40    slo-eng
42 %define      dict41    spa-eng
43 %define      dict42    swa-eng
44 %define      dict43    swe-eng
45 %define      dict44    tur-deu
46 %define      dict45    tur-eng
47 %define      dict46    wel-eng
48 %define      dictionaries %{dict1} %{dict2} %{dict3} %{dict4} %{dict5} %{dict6} %{dict7} %{dict8} %{dict9} %{dict10} %{dict11} %{dict12} %{dict13} %{dict14} %{dict15} %{dict16} %{dict17} %{dict18} %{dict19} %{dict20} %{dict21} %{dict22} %{dict23} %{dict24} %{dict25} %{dict26} %{dict27} %{dict28} %{dict29} %{dict30} %{dict31} %{dict32} %{dict33} %{dict34} %{dict35} %{dict36} %{dict37} %{dict38} %{dict39} %{dict40} %{dict41} %{dict42} %{dict43} %{dict44} %{dict45} %{dict46}
49
50
51 Summary:        The Free bilingual dictionaries for dictd
52 Summary(pl):    Darmowe dwujêzykowe S³owniki dla dictd
53 Name:           %{dictname}
54 Version:        20020622
55 Release:        1
56 License:        GPL
57 Group:          Applications/Dictionaries
58 Source0:        http://www.freedict.de/pub/dict/dictmisc.tar.gz
59 Source1:    http://freedict.sourceforge.net/download/linux/%{dict1}.tar.gz
60 Source2:    http://freedict.sourceforge.net/download/linux/%{dict2}.tar.gz
61 Source3:    http://freedict.sourceforge.net/download/linux/%{dict3}.tar.gz
62 Source4:    http://freedict.sourceforge.net/download/linux/%{dict4}.tar.gz
63 Source5:    http://freedict.sourceforge.net/download/linux/%{dict5}.tar.gz
64 Source6:    http://freedict.sourceforge.net/download/linux/%{dict6}.tar.gz
65 #Source7:    http://freedict.sourceforge.net/download/linux/%{dict7}.tar.gz
66 Source8:    http://freedict.sourceforge.net/download/linux/%{dict8}.tar.gz
67 Source9:    http://freedict.sourceforge.net/download/linux/%{dict9}.tar.gz
68 Source10:    http://freedict.sourceforge.net/download/linux/%{dict10}.tar.gz
69 Source11:    http://freedict.sourceforge.net/download/linux/%{dict11}.tar.gz
70 Source12:    http://freedict.sourceforge.net/download/linux/%{dict12}.tar.gz
71 Source13:    http://freedict.sourceforge.net/download/linux/%{dict13}.tar.gz
72 Source14:    http://freedict.sourceforge.net/download/linux/%{dict14}.tar.gz
73 Source15:    http://freedict.sourceforge.net/download/linux/%{dict15}.tar.gz
74 Source16:    http://freedict.sourceforge.net/download/linux/%{dict16}.tar.gz
75 Source17:    http://freedict.sourceforge.net/download/linux/%{dict17}.tar.gz
76 Source18:    http://freedict.sourceforge.net/download/linux/%{dict18}.tar.gz
77 Source19:    http://freedict.sourceforge.net/download/linux/%{dict19}.tar.gz
78 Source20:    http://freedict.sourceforge.net/download/linux/%{dict20}.tar.gz
79 Source21:    http://freedict.sourceforge.net/download/linux/%{dict21}.tar.gz
80 Source22:    http://freedict.sourceforge.net/download/linux/%{dict22}.tar.gz
81 Source23:    http://freedict.sourceforge.net/download/linux/%{dict23}.tar.gz
82 Source24:    http://freedict.sourceforge.net/download/linux/%{dict24}.tar.gz
83 Source25:    http://freedict.sourceforge.net/download/linux/%{dict25}.tar.gz
84 Source26:    http://freedict.sourceforge.net/download/linux/%{dict26}.tar.gz
85 Source27:    http://freedict.sourceforge.net/download/linux/%{dict27}.tar.gz
86 Source28:    http://freedict.sourceforge.net/download/linux/%{dict28}.tar.gz
87 Source29:    http://freedict.sourceforge.net/download/linux/%{dict29}.tar.gz
88 Source30:    http://freedict.sourceforge.net/download/linux/%{dict30}.tar.gz
89 Source31:    http://freedict.sourceforge.net/download/linux/%{dict31}.tar.gz
90 Source32:    http://freedict.sourceforge.net/download/linux/%{dict32}.tar.gz
91 Source33:    http://freedict.sourceforge.net/download/linux/%{dict33}.tar.gz
92 Source34:    http://freedict.sourceforge.net/download/linux/%{dict34}.tar.gz
93 Source35:    http://freedict.sourceforge.net/download/linux/%{dict35}.tar.gz
94 Source36:    http://freedict.sourceforge.net/download/linux/%{dict36}.tar.gz
95 Source37:    http://freedict.sourceforge.net/download/linux/%{dict37}.tar.gz
96 Source38:    http://freedict.sourceforge.net/download/linux/%{dict38}.tar.gz
97 Source39:    http://freedict.sourceforge.net/download/linux/%{dict39}.tar.gz
98 Source40:    http://freedict.sourceforge.net/download/linux/%{dict40}.tar.gz
99 Source41:    http://freedict.sourceforge.net/download/linux/%{dict41}.tar.gz
100 Source42:    http://freedict.sourceforge.net/download/linux/%{dict42}.tar.gz
101 Source43:    http://freedict.sourceforge.net/download/linux/%{dict43}.tar.gz
102 Source44:    http://freedict.sourceforge.net/download/linux/%{dict44}.tar.gz
103 Source45:    http://freedict.sourceforge.net/download/linux/%{dict45}.tar.gz
104 Source46:    http://freedict.sourceforge.net/download/linux/%{dict46}.tar.gz
105 URL:            http://www.freedict.de
106 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
107 BuildRequires:  dictzip
108 BuildRequires:  autoconf
109 Requires:       dictd
110 Requires:       %{_sysconfdir}/dictd
111
112 %description 
113 This package contains The The Free bilingual dictionaries, version %version
114 formatted for use by the dictionary server in the dictd package.
115
116 %description -l pl
117 Ten pakiet zawiera darmowe dwujêzyczne s³owniki w wersji %version
118 sformatowane do u¿ytku z serwerem s³ownika dictd.
119
120
121 %package -n %{dictname}-%{dict1}
122 Summary:    The %{dict1} Dictionary for dictd
123 Summary(pl):    S³ownik %{dict1} dla dictd
124 Group:      Applications/Dictionaries
125 Requires:   dictd 
126 Requires:   %{_sysconfdir}/dictd
127
128 %description -n  %{dictname}-%{dict1}
129 This package contains %{dict1} dictionaries for use by the dicitonary
130 server in the dictd package.
131
132 %description -n  %{dictname}-%{dict1}  -l pl
133 Ten pakiet zawiera s³ownik %{dict1} do u¿ywania z serwerem s³ownika
134 dictd. 
135
136
137 %prep
138 %setup -q -c
139 %setup -q -c -T -D -a 1
140 %setup -q -c -T -D -a 2
141 %setup -q -c -T -D -a 3
142 %setup -q -c -T -D -a 4
143 %setup -q -c -T -D -a 5
144 %setup -q -c -T -D -a 6
145 #%setup -q -c -T -D -a 7
146 %setup -q -c -T -D -a 8
147 %setup -q -c -T -D -a 9
148 %setup -q -c -T -D -a 10
149 %setup -q -c -T -D -a 11
150 %setup -q -c -T -D -a 12
151 %setup -q -c -T -D -a 13
152 %setup -q -c -T -D -a 14
153 %setup -q -c -T -D -a 15
154 %setup -q -c -T -D -a 16
155 %setup -q -c -T -D -a 17
156 %setup -q -c -T -D -a 18
157 %setup -q -c -T -D -a 19
158 %setup -q -c -T -D -a 20
159 %setup -q -c -T -D -a 21
160 %setup -q -c -T -D -a 22
161 %setup -q -c -T -D -a 23
162 %setup -q -c -T -D -a 24
163 %setup -q -c -T -D -a 25
164 %setup -q -c -T -D -a 26
165 %setup -q -c -T -D -a 27
166 %setup -q -c -T -D -a 28
167 %setup -q -c -T -D -a 29
168 %setup -q -c -T -D -a 30
169 %setup -q -c -T -D -a 31
170 %setup -q -c -T -D -a 32
171 %setup -q -c -T -D -a 33
172 %setup -q -c -T -D -a 34
173 %setup -q -c -T -D -a 35
174 %setup -q -c -T -D -a 36
175 %setup -q -c -T -D -a 37
176 %setup -q -c -T -D -a 38
177 %setup -q -c -T -D -a 39
178 %setup -q -c -T -D -a 40
179 %setup -q -c -T -D -a 41
180 %setup -q -c -T -D -a 42
181 %setup -q -c -T -D -a 43
182 %setup -q -c -T -D -a 44
183 %setup -q -c -T -D -a 45
184 %setup -q -c -T -D -a 46
185
186 %build
187 cd dictmisc
188 autoconf
189 %configure 
190 %{__make}
191 cd ..
192 for i in %{dictionaries}; do
193     mv $i.dict.dz $i.gz
194     gunzip $i.gz
195     dictfiles=%{_datadir}/dictd/%{dictname}-$i
196     ./dictmisc/dictfmt -f -u "%{URL}" -s "$i Freedict dictionary" %{dictname}_$i < $i
197     dictzip %{dictname}_$i.dict
198 done
199
200
201 %install
202 install -d $RPM_BUILD_ROOT{%{_datadir}/dictd/,%{_sysconfdir}/dictd,aqq}
203
204 for i in %{dictionaries}; do
205     dictprefix=%{_datadir}/dictd/%{dictname}_$i
206     echo "# The Bilingual dictionaries
207     database $i {
208         data  \"$dictprefix.dict.dz\"
209         index \"$dictprefix.index\" 
210     }
211     " > $RPM_BUILD_ROOT%{_sysconfdir}/dictd/%{dictname}-$i.dictconf
212     mv %{dictname}_%{dict1}*  $RPM_BUILD_ROOT%{_datadir}/dictd/
213 done
214
215 %clean
216 rm -rf $RPM_BUILD_ROOT
217
218 %postun 
219 if [ -f /var/lock/subsys/dictd ]; then
220         /etc/rc.d/init.d/dictd restart 1>&2
221 fi
222
223 %post
224 if [ -f /var/lock/subsys/dictd ]; then
225         /etc/rc.d/init.d/dictd restart 1>&2
226 fi
227
228
229 %postun -n  %{dictname}-%{dict1}
230 if [ -f /var/lock/subsys/dictd ]; then
231    /etc/rc.d/init.d/dictd restart 1>&2 || true
232 fi
233
234 %post -n  %{dictname}-%{dict1}
235 if [ -f /var/lock/subsys/dictd ]; then
236    /etc/rc.d/init.d/dictd restart 1>&2
237 fi
238
239 %files
240 %defattr(644,root,root,755)
241
242 %files -n  %{dictname}-%{dict1}
243 %defattr(644,root,root,755)
244 %attr(640,root,root) %config(noreplace) %verify(not size mtime md5) %{_sysconfdir}/dictd/%{dictname}-%{dict1}.dictconf
245 %{_datadir}/dictd/%{dictname}_%{dict1}*
This page took 0.093139 seconds and 2 git commands to generate.