]>
Commit | Line | Data |
---|---|---|
ab02002f TP |
1 | %define dictname gcide |
2 | Summary: Collaborative International Dictionary of English for dictd | |
f11ff928 | 3 | Summary(pl.UTF-8): Słownik Collaborative International Dictionary of English dla dictd |
ab02002f TP |
4 | Name: dict-%{dictname} |
5 | Version: 0.44 | |
7a92fc5f | 6 | Release: 4 |
ab02002f TP |
7 | License: GPL |
8 | Group: Applications/Dictionaries | |
9 | Source0: ftp://ftp.dict.org/pub/dict/pre/%{name}-%{version}.tar.gz | |
0d907148 | 10 | # Source0-md5: 641502e6fedca32cbf9777b1f4f76afe |
12d6251f | 11 | # based on ftp://ftp.gnu.org/gnu/gcide/gcide-0.46/README.DIC |
12 | Source1: %{name}-README.DIC | |
ab02002f | 13 | URL: http://www.dict.org/ |
7a92fc5f | 14 | BuildRequires: rpmbuild(macros) >= 1.268 |
ab02002f | 15 | Requires: %{_sysconfdir}/dictd |
9467b764 | 16 | Requires: dictd |
ab02002f TP |
17 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
18 | ||
19 | %description | |
20 | This package contains GCIDE (Collaborative International Dictionary of | |
71839b1c | 21 | English) %{version} formatted for use by the dictionary server in the |
ab02002f TP |
22 | dictd package. |
23 | ||
3b72e708 JR |
24 | %description -l pl.UTF-8 |
25 | Ten pakiet zawiera słownik GCIDE (Collaborative International | |
26 | Dictionary of English) %{version} sformatowany do używania z serwerem | |
27 | słownika dictd. | |
ab02002f TP |
28 | |
29 | %prep | |
30 | %setup -c -q | |
12d6251f | 31 | install %{SOURCE1} README.DIC |
ab02002f TP |
32 | |
33 | %install | |
34 | rm -rf $RPM_BUILD_ROOT | |
35 | install -d $RPM_BUILD_ROOT{%{_datadir}/dictd,%{_sysconfdir}/dictd} | |
36 | ||
37 | dictprefix=%{_datadir}/dictd/%{dictname} | |
71839b1c | 38 | echo "# Collaborative International Dictionary of English (%{version}) |
ab02002f TP |
39 | database %{dictname} { |
40 | data \"$dictprefix.dict.dz\" | |
41 | index \"$dictprefix.index\" | |
42 | }" > $RPM_BUILD_ROOT%{_sysconfdir}/dictd/%{dictname}.dictconf | |
7a92fc5f | 43 | cp -a %{dictname}.* $RPM_BUILD_ROOT%{_datadir}/dictd |
ab02002f TP |
44 | |
45 | %clean | |
46 | rm -rf $RPM_BUILD_ROOT | |
47 | ||
48 | %post | |
7a92fc5f | 49 | %service -q dictd restart |
ab02002f TP |
50 | |
51 | %postun | |
7a92fc5f ER |
52 | if [ "$1" = 0 ]; then |
53 | %service -q dictd restart | |
ab02002f TP |
54 | fi |
55 | ||
56 | %files | |
57 | %defattr(644,root,root,755) | |
58 | %doc README.DIC | |
9467b764 | 59 | %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/dictd/%{dictname}.dictconf |
ab02002f | 60 | %{_datadir}/dictd/%{dictname}.* |