]>
Commit | Line | Data |
---|---|---|
84b38548 ER |
1 | # |
2 | # Conditional build: | |
3 | %bcond_without static_libs # don't build static libraries | |
4 | ||
2be58cbe | 5 | %define ver %(echo %{version} | tr . _) |
9c80e862 | 6 | %define basever %(echo %{version} | cut -d. -f1) |
6a26a678 | 7 | Summary: International Components for Unicode |
a9679d76 | 8 | Summary(pl.UTF-8): Międzynarodowe komponenty dla unikodu |
6a26a678 | 9 | Name: icu |
d4cc09ca | 10 | Version: 65.1 |
9c80e862 | 11 | Release: 1 |
ff4ffa8b | 12 | License: MIT-like |
6a26a678 | 13 | Group: Libraries |
d4cc09ca AG |
14 | Source0: https://github.com/unicode-org/icu/releases/download/release-65-1/icu4c-%{ver}-src.tgz |
15 | # Source0-md5: d1ff436e26cabcb28e6cb383d32d1339 | |
0e2868a5 | 16 | Patch0: %{name}-cxx-pre11.patch |
29be82ba | 17 | URL: http://www.icu-project.org/ |
c888482a | 18 | BuildRequires: autoconf >= 2.69 |
073720db | 19 | BuildRequires: libstdc++-devel |
f99b930f | 20 | Requires: libicu = %{version}-%{release} |
6a26a678 | 21 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
22 | ||
23 | %description | |
24 | ICU is a set of C and C++ libraries that provides robust and | |
25 | full-featured Unicode and locale support. The library provides | |
26 | calendar support, conversions for many character sets, language | |
27 | sensitive collation, date and time formatting, support for many | |
28 | locales, message catalogs and resources, message formatting, | |
29 | normalization, number and currency formatting, time zones support, | |
30 | transliteration, word, line and sentence breaking, etc. | |
31 | ||
32 | This package contains the Unicode character database and derived | |
33 | properties, along with converters and time zones data. | |
34 | ||
eb45a078 JR |
35 | %description -l pl.UTF-8 |
36 | ICU jest grupą bibliotek C i C++, które dostarczają kompletną i pełną | |
37 | obsługę Unikodu i lokalizacji. Biblioteka dostarcza obsługę | |
38 | kalendarza, konwersje dla wielu zestawów znaków, sortowanie zależne od | |
39 | języka, formatowanie daty i czasu, wsparcie dla wielu lokalizacji, | |
40 | katalogów komunikatów i zasobów, formatowanie komunikatów, | |
41 | normalizację, formatowanie liczb i walut, obsługę stref czasowych, | |
42 | transliterację, łamanie słów, linii i zdań itp. | |
f99b930f | 43 | |
eb45a078 | 44 | Ten pakiet zawiera bazę znaków unikodowych i pochodne własności wraz z |
25330473 | 45 | konwerterami i danymi stref czasowych. |
f99b930f JB |
46 | |
47 | %package -n libicu | |
6a26a678 | 48 | Summary: International Components for Unicode (libraries) |
a9679d76 | 49 | Summary(pl.UTF-8): Międzynarodowe Komponenty dla Unikodu (biblioteki) |
5b19d04b | 50 | Group: Libraries |
f99b930f | 51 | Obsoletes: libicu30 |
6a26a678 | 52 | |
f99b930f | 53 | %description -n libicu |
6a26a678 | 54 | ICU is a set of C and C++ libraries that provides robust and |
55 | full-featured Unicode support. This package contains the runtime | |
56 | libraries for ICU. It does not contain any of the data files needed at | |
5e7cb58a | 57 | runtime and present in the `icu' package. |
6a26a678 | 58 | |
eb45a078 JR |
59 | %description -n libicu -l pl.UTF-8 |
60 | ICU jest grupą bibliotek C i C++, które dostarczają kompletną i pełną | |
61 | obsługę Unikodu i lokalizacji. Ten pakiet zawiera biblioteki | |
62 | uruchomieniowe ICU. Nie zawiera żadnych plików z danymi potrzebnymi w | |
5e7cb58a | 63 | czasie działania i obecnymi w pakietach "icu". |
f99b930f | 64 | |
6a26a678 | 65 | %package -n libicu-devel |
66 | Summary: International Components for Unicode (development files) | |
a9679d76 | 67 | Summary(pl.UTF-8): Międzynarodowe komponenty dla Unikodu (pliki dla programistów) |
6a26a678 | 68 | Group: Development/Libraries |
f99b930f | 69 | Requires: libicu = %{version}-%{release} |
6a26a678 | 70 | |
71 | %description -n libicu-devel | |
72 | ICU is a set of C and C++ libraries that provides robust and | |
73 | full-featured Unicode support. This package contains the development | |
74 | files for ICU. | |
75 | ||
eb45a078 JR |
76 | %description -n libicu-devel -l pl.UTF-8 |
77 | ICU jest grupą bibliotek C i C++, które dostarczają kompletną i pełną | |
78 | obsługę Unikodu i lokalizacji. Ten pakiet zawiera pliki | |
f99b930f JB |
79 | programistyczne ICU. |
80 | ||
a59b4117 MM |
81 | %package -n libicu-static |
82 | Summary: International Components for Unicode (static libraries) | |
83 | Summary(pl.UTF-8): Międzynarodowe komponenty dla Unikodu (biblioteki statyczne) | |
84 | Group: Development/Libraries | |
85 | Requires: libicu-devel = %{version}-%{release} | |
86 | ||
87 | %description -n libicu-static | |
88 | ICU is a set of C and C++ libraries that provides robust and | |
89 | full-featured Unicode support. This package contains the static | |
90 | libraries for ICU. | |
91 | ||
92 | %description -n libicu-static -l pl.UTF-8 | |
93 | ICU jest grupą bibliotek C i C++, które dostarczają kompletną i pełną | |
94 | obsługę Unikodu i lokalizacji. Ten pakiet zawiera statyczne | |
95 | biblioteki programistyczne ICU. | |
96 | ||
6a26a678 | 97 | %prep |
7d3a284b | 98 | %setup -q -n %{name} |
0e2868a5 | 99 | %patch0 -p1 |
6a26a678 | 100 | |
101 | %build | |
7d3a284b | 102 | cd source |
2be58cbe | 103 | %{__autoconf} |
ff4ffa8b | 104 | %configure \ |
60ef1664 | 105 | --sbindir=%{_bindir} \ |
6c6806e6 | 106 | --with-data-packaging=library \ |
84b38548 | 107 | %{?with_static_libs:--enable-static} \ |
073720db | 108 | --disable-samples |
7d3a284b | 109 | |
fc0ad54a JB |
110 | %{__make} \ |
111 | VERBOSE=1 | |
6a26a678 | 112 | |
113 | %install | |
114 | rm -rf $RPM_BUILD_ROOT | |
6a26a678 | 115 | |
073720db | 116 | %{__make} -C source install \ |
6a26a678 | 117 | DESTDIR=$RPM_BUILD_ROOT |
118 | ||
f95fea90 | 119 | for f in icu-i18n icu-io icu-uc ; do |
5735de1c JB |
120 | sed -i \ |
121 | -e 's/\$(THREADSCXXFLAGS)//' \ | |
122 | -e 's/\$(THREADSCFLAGS)//' \ | |
123 | -e 's/\$(THREADSCPPFLAGS)/-D_REENTRANT/' $RPM_BUILD_ROOT%{_pkgconfigdir}/${f}.pc | |
124 | done | |
2be58cbe | 125 | |
0f4824f4 JB |
126 | # help rpm to generate deps |
127 | chmod +x $RPM_BUILD_ROOT%{_libdir}/lib*.so.*.* | |
128 | ||
7f0f98e4 JB |
129 | # rpm is too stupid sometimes and fails on symlinks to symlinked resources |
130 | # (reporting unresolved dependency at install time) | |
5735de1c JB |
131 | for f in Makefile.inc pkgdata.inc ; do |
132 | ln -sf %{version}/${f} $RPM_BUILD_ROOT%{_libdir}/%{name}/${f} | |
133 | done | |
7f0f98e4 | 134 | |
4271d828 | 135 | %{__rm} $RPM_BUILD_ROOT%{_datadir}/icu/%{version}/LICENSE |
1f4b227d | 136 | |
6a26a678 | 137 | %clean |
138 | rm -rf $RPM_BUILD_ROOT | |
139 | ||
073720db JB |
140 | %post -n libicu -p /sbin/ldconfig |
141 | %postun -n libicu -p /sbin/ldconfig | |
142 | ||
6a26a678 | 143 | %files |
144 | %defattr(644,root,root,755) | |
7d3a284b | 145 | %doc license.html readme.html |
53e9cdd2 | 146 | %attr(755,root,root) %{_bindir}/derb |
5eb75bd7 | 147 | %attr(755,root,root) %{_bindir}/escapesrc |
53e9cdd2 JB |
148 | %attr(755,root,root) %{_bindir}/gen* |
149 | %attr(755,root,root) %{_bindir}/icuinfo | |
150 | %attr(755,root,root) %{_bindir}/icupkg | |
151 | %attr(755,root,root) %{_bindir}/makeconv | |
152 | %attr(755,root,root) %{_bindir}/pkgdata | |
153 | %attr(755,root,root) %{_bindir}/uconv | |
154 | %{_mandir}/man1/derb.1* | |
155 | %{_mandir}/man1/gen*.1* | |
156 | %{_mandir}/man1/makeconv.1* | |
157 | %{_mandir}/man1/pkgdata.1* | |
158 | %{_mandir}/man1/uconv.1* | |
159 | %{_mandir}/man8/gen*.8* | |
160 | %{_mandir}/man8/icupkg.8* | |
6a26a678 | 161 | |
7d3a284b | 162 | %files -n libicu |
48b42393 | 163 | %defattr(644,root,root,755) |
ff4ffa8b | 164 | %attr(755,root,root) %{_libdir}/libicu*.so.*.* |
9c80e862 | 165 | %attr(755,root,root) %ghost %{_libdir}/libicu*.so.%{basever} |
7d3a284b | 166 | |
7d3a284b | 167 | %files -n libicu-devel |
48b42393 | 168 | %defattr(644,root,root,755) |
af4104d1 | 169 | %attr(755,root,root) %{_bindir}/icu-config |
ff4ffa8b | 170 | %attr(755,root,root) %{_libdir}/libicu*.so |
5735de1c JB |
171 | %{_pkgconfigdir}/icu-i18n.pc |
172 | %{_pkgconfigdir}/icu-io.pc | |
5735de1c | 173 | %{_pkgconfigdir}/icu-uc.pc |
ff4ffa8b | 174 | %{_includedir}/unicode |
a325d3da | 175 | %dir %{_libdir}/%{name} |
430c90c8 | 176 | %{_libdir}/%{name}/*.inc |
a325d3da JB |
177 | %dir %{_libdir}/%{name}/current |
178 | %dir %{_libdir}/%{name}/%{version} | |
430c90c8 | 179 | %{_libdir}/%{name}/%{version}/*.inc |
a325d3da JB |
180 | %dir %{_datadir}/%{name} |
181 | %dir %{_datadir}/%{name}/%{version} | |
7d3a284b | 182 | %{_datadir}/%{name}/%{version}/config |
8de4b80e | 183 | %attr(755,root,root) %{_datadir}/%{name}/%{version}/install-sh |
a325d3da | 184 | %attr(755,root,root) %{_datadir}/%{name}/%{version}/mkinstalldirs |
af4104d1 | 185 | %{_mandir}/man1/icu-config.1* |
a59b4117 | 186 | |
84b38548 | 187 | %if %{with static_libs} |
a59b4117 MM |
188 | %files -n libicu-static |
189 | %defattr(644,root,root,755) | |
190 | %{_libdir}/libicu*.a | |
84b38548 | 191 | %endif |