]>
Commit | Line | Data |
---|---|---|
1 | # | |
2 | # Conditional build: | |
3 | %bcond_without recode # build without recode support | |
4 | # | |
5 | Summary: Extremely Naive Charset Analyser | |
6 | Summary(pl.UTF-8): Skrajnie naiwny analizator zestawów znaków | |
7 | Name: enca | |
8 | Version: 1.9 | |
9 | Release: 2 | |
10 | License: GPL v2 | |
11 | Group: Libraries | |
12 | Source0: http://trific.ath.cx/Ftp/enca/%{name}-%{version}.tar.bz2 | |
13 | # Source0-md5: b3581e28d68d452286fb0bfe58bed3b3 | |
14 | Patch0: %{name}-libdir.patch | |
15 | URL: http://trific.ath.cx/software/enca/ | |
16 | BuildRequires: autoconf | |
17 | BuildRequires: automake | |
18 | BuildRequires: iconv | |
19 | %{?with_recode:BuildRequires: recode-devel} | |
20 | Requires: /bin/mktemp | |
21 | Requires: %{name}-libs = %{version}-%{release} | |
22 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) | |
23 | ||
24 | %description | |
25 | Enca is an Extremely Naive Charset Analyser. It detects character set | |
26 | and encoding of text files and can also convert them to other | |
27 | encodings using either a built-in converter or external libraries and | |
28 | tools like libiconv, librecode, or cstocs. | |
29 | ||
30 | Currently, it has support for Belarussian, Bulgarian, Croatian, Czech, | |
31 | Estonian, Latvian, Lithuanian, Polish, Russian, Slovak, Slovene, and | |
32 | Ukrainian and some multibyte encodings (mostly variants of Unicode) | |
33 | independently on the language. | |
34 | ||
35 | %description -l pl.UTF-8 | |
36 | Enca to Extremely Naive Charset Analyser (skrajnie naiwny analizator | |
37 | zestawów znaków). Wykrywa zestaw znaków i kodowanie plików tekstowych, | |
38 | może także konwertować do innych kodowań przy użyciu wbudowanego | |
39 | konwertera lub zewnętrznych bibliotek i narzędzi takich jak libiconv, | |
40 | librecode czy cstocs. | |
41 | ||
42 | Aktualnie obsługiwane są znaki białoruskie, bułgarskie, chorwackie, | |
43 | czeskie, estońskie, litewskie, łotewskie, polskie, rosyjskie, | |
44 | słowackie, słoweńskie i ukraińskie oraz niektóre kodowania | |
45 | wielobajtowe (głównie warianty unikodu) niezależnie od języka. | |
46 | ||
47 | %package libs | |
48 | Summary: Shared Enca library | |
49 | Summary(pl.UTF-8): Biblioteka współdzielona Enca | |
50 | Group: Libraries | |
51 | ||
52 | %description libs | |
53 | This package contains shared Enca library other programs can make use | |
54 | of. | |
55 | ||
56 | %description libs -l pl.UTF-8 | |
57 | Ten pakiet zawiera bibliotekę współdzieloną Enca, która może być | |
58 | wykorzystywana przez inne programy. | |
59 | ||
60 | %package devel | |
61 | Summary: Header files for ENCA library | |
62 | Summary(pl.UTF-8): Pliki nagłówkowe biblioteki ENCA | |
63 | Group: Development/Libraries | |
64 | Requires: %{name}-libs = %{version}-%{release} | |
65 | ||
66 | %description devel | |
67 | Header files for ENCA library. | |
68 | ||
69 | %description devel -l pl.UTF-8 | |
70 | Pliki nagłówkowe biblioteki ENCA. | |
71 | ||
72 | %package static | |
73 | Summary: Static ENCA library | |
74 | Summary(pl.UTF-8): Statyczna biblioteka ENCA | |
75 | Group: Development/Libraries | |
76 | Requires: %{name}-devel = %{version}-%{release} | |
77 | ||
78 | %description static | |
79 | Static ENCA library. | |
80 | ||
81 | %description static -l pl.UTF-8 | |
82 | Statyczna biblioteka ENCA. | |
83 | ||
84 | %prep | |
85 | %setup -q | |
86 | %patch0 -p1 | |
87 | ||
88 | %build | |
89 | cp -f /usr/share/automake/config.sub . | |
90 | %{__autoconf} | |
91 | %configure \ | |
92 | MKTEMP_PROG=/bin/mktemp \ | |
93 | --with-html-dir=%{_gtkdocdir} | |
94 | ||
95 | %{__make} | |
96 | ||
97 | %install | |
98 | rm -rf $RPM_BUILD_ROOT | |
99 | ||
100 | %{__make} install \ | |
101 | DESTDIR=$RPM_BUILD_ROOT | |
102 | ||
103 | rm -f $RPM_BUILD_ROOT%{_mandir}/man1/enconv.1 | |
104 | echo '.so enca.1' > $RPM_BUILD_ROOT%{_mandir}/man1/enconv.1 | |
105 | ||
106 | %clean | |
107 | rm -rf $RPM_BUILD_ROOT | |
108 | ||
109 | %post libs -p /sbin/ldconfig | |
110 | %postun libs -p /sbin/ldconfig | |
111 | ||
112 | %files | |
113 | %defattr(644,root,root,755) | |
114 | %doc AUTHORS ChangeLog FAQ NEWS README THANKS TODO | |
115 | %attr(755,root,root) %{_bindir}/* | |
116 | %attr(755,root,root) %{_libexecdir}/enca | |
117 | %{_mandir}/man1/* | |
118 | ||
119 | %files libs | |
120 | %defattr(644,root,root,755) | |
121 | %attr(755,root,root) %{_libdir}/lib*.so.*.*.* | |
122 | ||
123 | %files devel | |
124 | %defattr(644,root,root,755) | |
125 | %doc README.devel | |
126 | %attr(755,root,root) %{_libdir}/lib*.so | |
127 | %{_libdir}/lib*.la | |
128 | %{_includedir}/*.h | |
129 | %{_pkgconfigdir}/*.pc | |
130 | %{_gtkdocdir}/libenca | |
131 | ||
132 | %files static | |
133 | %defattr(644,root,root,755) | |
134 | %{_libdir}/lib*.a |