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