]> git.pld-linux.org Git - packages/gettext.git/blob - gettext.spec
- release 4
[packages/gettext.git] / gettext.spec
1 # TODO
2 # - unpackaged:
3 #   /usr/share/emacs/site-lisp/po-compat.el
4 #   /usr/share/emacs/site-lisp/po-compat.elc
5 #   /usr/share/emacs/site-lisp/po-mode.el
6 #   /usr/share/emacs/site-lisp/po-mode.elc
7 #   /usr/share/emacs/site-lisp/start-po.el
8 #   /usr/share/emacs/site-lisp/start-po.elc
9 #
10 # Conditional build:
11 %bcond_without  asprintf        # without libasprintf C++ library
12 %bcond_with             xemacs          # without po-mode for xemacs
13 %bcond_without  gcj             # with Java support by gcj (preferred over javac)
14 %bcond_with             javac           # with Java support by some javac
15 %bcond_without  dotnet          # without .NET support
16 %bcond_with     bootstrap       # use system GLib and libcroco
17
18 %ifnarch %{ix86} %{x8664} arm hppa ppc s390 s390x
19 %undefine with_dotnet
20 %endif
21 %ifarch i386
22 # plain i386 is not supported; mono uses cmpxchg/xadd which require i486
23 %undefine with_dotnet
24 %endif
25
26 %{?with_dotnet:%include /usr/lib/rpm/macros.mono}
27
28 %define build_java      %{?with_gcj:1}%{!?with_gcj:%{?with_javac:1}%{!?with_javac:0}}
29 Summary:        Utilties for program national language support
30 Summary(de.UTF-8):      Utilities zum Programmieren von nationaler Sprachunterstützung
31 Summary(es.UTF-8):      Utilitarios para el programa de soporte a lenguas locales
32 Summary(fr.UTF-8):      Utilitaires pour le support de la langue nationnalepar les programmes
33 Summary(ja.UTF-8):      マルチリンガルメッセージを生成するためのGNU ライブラリ/ユーティリティ
34 Summary(pl.UTF-8):      Narzędzia dla programów ze wsparciem dla języków narodowych
35 Summary(pt_BR.UTF-8):   Utilitários para o programa de suporte de línguas locais
36 Summary(ru.UTF-8):      Библиотеки и утилиты для поддержки национальных языков
37 Summary(tr.UTF-8):      Desteği için kitaplık ve araçlar
38 Summary(uk.UTF-8):      Бібліотеки та утиліти для підтримки національних мов
39 Name:           gettext
40 Version:        0.17
41 Release:        4
42 License:        LGPL v2+ (libintl), GPL v3+ (tools)
43 Group:          Development/Tools
44 Source0:        http://ftp.gnu.org/gnu/gettext/%{name}-%{version}.tar.gz
45 # Source0-md5:  58a2bc6d39c0ba57823034d55d65d606
46 Patch0:         %{name}-info.patch
47 Patch1:         %{name}-killkillkill.patch
48 Patch2:         %{name}-pl.po-update.patch
49 Patch3:         %{name}-no_docs.patch
50 Patch4:         %{name}-libintl_by_gcj.patch
51 Patch5:         %{name}-removed_macros.patch
52 URL:            http://www.gnu.org/software/gettext/
53 BuildRequires:  autoconf >= 2.60
54 BuildRequires:  automake >= 1:1.10
55 %{?with_gcj:BuildRequires:      gcj >= 3.0}
56 %{!?with_bootstrap:BuildRequires:       glib2-devel >= 2.0}
57 %{?with_javac:BuildRequires:    jdk >= 1.1}
58 %{!?with_bootstrap:BuildRequires:       libcroco-devel >= 0.6.1}
59 %if "%(echo %{cc_version} | grep -q '^4.[2-9]'; echo $?)" == "0"
60 BuildRequires:  libgomp-devel
61 %endif
62 %{?with_asprintf:BuildRequires: libstdc++-devel}
63 BuildRequires:  libtool >= 1:1.4.2-9
64 %{?with_dotnet:BuildRequires:   mono-csharp}
65 BuildRequires:  rpmbuild(macros) >= 1.453
66 BuildRequires:  texinfo
67 %{?with_xemacs:BuildRequires:   xemacs}
68 Obsoletes:      gettext-base
69 Conflicts:      intltool < 0.28
70 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
71
72 %description
73 The GNU gettext package provides a set of tools and documentation for
74 producing multi-lingual messages in programs. Tools include a set of
75 conventions about how programs should be written to support message
76 catalogs, a directory and file naming organization for the message
77 catalogs, a runtime library which supports the retrieval of translated
78 messages, and stand-alone programs for handling the translatable and
79 the already translated strings. Gettext provides an easy to use
80 library and tools for creating, using, and modifying natural language
81 catalogs and is a powerful and simple method for internationalizing
82 programs.
83
84 %description -l de.UTF-8
85 Die gettext-Library enthält eine einfach anzuwendende Library und
86 Tools zum Erstellen, Verwenden und Ändern von
87 natürlichsprachigen-Kataloge. Es ist ein einfaches und
88 leistungsfähiges Verfahren zum Lokalisieren von Programmen.
89
90 %description -l es.UTF-8
91 La biblioteca gettext nos ofrece una biblioteca fácil de usar y
92 herramientas para creación, uso y modificación de catálogos de
93 lenguaje natural. Es un potente y sencillo método de
94 internacionalización de programas.
95
96 %description -l fr.UTF-8
97 La librarie gettext fournit des outils et une librairie simple à
98 utiliser pour manipuler, créer, et modifier des catalogues de langage
99 naturel. C'est une méthode simple et puissante pour internationnaliser
100 les programmes.
101
102 %description -l ja.UTF-8
103 GNU gettext
104 パッケージはプログラム中でマルチリンガルメッセージを生成する
105 ためのツールと文書を供給する。ツールはメッセージカタログをサポートするために
106 プログラムがどのように書かれるべきかの申し合わせと、メッセージカタログのための
107 ディレクトリとファイル名の組織化と、翻訳されたメッセージの埋め合わせを
108 サポートするためのランタイムライブラリと、翻訳可能でかつすでに翻訳された文字列
109 を取り扱う独立したプログラムを含んでいる。gettext
110 は簡単に使えるライブラリ
111 と自然言語のカタログを生成、使用、修正するツールと、国際化プログラム
112 のための強力かつシンプルな方法を供給する。
113
114 %description -l pl.UTF-8
115 Pakiet gettext dostarcza narzędzi do tworzenia, używania i modyfikacji
116 katalogów języków narodowych. To jest prosta i wydajna metoda
117 lokalizacji (internacjonalizacji) programów.
118
119 %description -l pt_BR.UTF-8
120 A biblioteca gettext oferece uma biblioteca fácil de usar e
121 ferramentas para criação, uso e modificação de catálogos de linguagem
122 natural. Ele é um poderoso e simples método de internacionalização de
123 programas.
124
125 %description -l ru.UTF-8
126 Пакет gettext содержит библиотеку и простые в использовании
127 инструменты для создания, использования и модификации каталогов
128 национальных языков. Это простой и мощный метод для
129 интернационализации программ.
130
131 %description -l tr.UTF-8
132 gettext, yerel dil desteğinde kullanılan katalogları değiştirebilmek
133 için, kolayca kullanılabilen kitaplık ve araçları sağlar. Bu,
134 programları uluslararasılaştırmak için sıkça başvurulan, kuvvetli bir
135 yöntemdir.
136
137 %description -l uk.UTF-8
138 Пакет gettext містить бібліотеку та прості у використанні інструменти
139 для створення, використання та модифікації каталогів національних мов.
140 Це простий та потужний метод для інтернаціоналізації програм.
141
142 %package devel
143 Summary:        Utilties for program national language support
144 Summary(de.UTF-8):      Utilities zum Programmieren von nationaler Sprachunterstützung
145 Summary(fr.UTF-8):      Utilitaires pour le support de la langue nationnalepar les programmes
146 Summary(pl.UTF-8):      Narzędzia dla programów ze wsparciem dla języków narodowych
147 Summary(tr.UTF-8):      Desteği için kitaplık ve araçlar
148 License:        GPL v3+
149 Group:          Development/Tools
150 Requires(post,postun):  /sbin/ldconfig
151 Requires:       %{name} = %{version}-%{release}
152 Requires:       iconv
153 Conflicts:      autoconf < 2.52
154
155 %description devel
156 The gettext library provides an easy to use library and tools for
157 creating, using, and modifying natural language catalogs. It is a
158 powerfull and simple method for internationalizing programs.
159
160 %description devel -l pl.UTF-8
161 Pakiet gettext dostarcza narzędzi do tworzenia, używania i modyfikacji
162 katalogów języków narodowych. To jest prosta i wydajna metoda
163 lokalizacji (internacjonalizacji) programów.
164
165 %package static
166 Summary:        Static gettext utility libraries
167 Summary(pl.UTF-8):      Statyczne biblioteki narzędziowe gettext
168 License:        GPL v3+
169 Group:          Development/Libraries
170 Requires:       %{name}-devel = %{version}-%{release}
171
172 %description static
173 This package contains static versions of gettext utility libraries
174 (libgettextlib, libgettextsrc and libgettextpo).
175
176 %description static -l pl.UTF-8
177 Ten pakiet zawiera statyczne wersje bibliotek narzędziowych gettext
178 (libgettextlib, libgettextsrc i libgettextpo).
179
180 %package -n libasprintf
181 Summary:        GNU libasprintf - automatic formatted output to strings in C++
182 Summary(pl.UTF-8):      GNU libasprintf - automatyczne formatowanie wyjścia do łańcuchów w C++
183 License:        LGPL v2+
184 Group:          Libraries
185
186 %description -n libasprintf
187 This package makes the C formatted output routines (`fprintf' et al.)
188 usable in C++ programs, for use with the `<string>' strings and the
189 `<iostream>' streams.
190
191 %description -n libasprintf -l pl.UTF-8
192 Ten pakiet czyni funkcje C formatujące wyjście (fprintf i inne)
193 używalnymi w programach w C++, z łańcuchami <string> i strumieniami
194 <iostream>.
195
196 %package -n libasprintf-devel
197 Summary:        Header file and documentation for libasprintf
198 Summary(pl.UTF-8):      Plik nagłówkowy i dokumentacja dla libasprintf
199 License:        LGPL v2+
200 Group:          Development/Libraries
201 Requires:       libasprintf = %{version}-%{release}
202
203 %description -n libasprintf-devel
204 Header file and documentation for libasprintf.
205
206 %description -n libasprintf-devel -l pl.UTF-8
207 Plik nagłówkowy i dokumentacja dla libasprintf.
208
209 %package -n libasprintf-static
210 Summary:        Static libasprintf library
211 Summary(pl.UTF-8):      Statyczna biblioteka libasprintf
212 License:        LGPL v2+
213 Group:          Development/Libraries
214 Requires:       libasprintf-devel = %{version}-%{release}
215
216 %description -n libasprintf-static
217 Static libasprintf library.
218
219 %description -n libasprintf-static -l pl.UTF-8
220 Statyczna biblioteka libasprintf.
221
222 %package java
223 Summary:        Runtime classes for Java programs internationalization
224 Summary(pl.UTF-8):      Klasy do uruchamiania umiędzynarodowionych programów w Javie
225 License:        LGPL v2+
226 Group:          Development/Languages/Java
227 Requires:       %{name} = %{version}-%{release}
228
229 %description java
230 Runtime classes for Java programs internationalization.
231
232 %description java -l pl.UTF-8
233 Klasy do uruchamiania umiędzynarodowionych programów w Javie.
234
235 %package java-devel
236 Summary:        Development classes for Java programs internationalization
237 Summary(pl.UTF-8):      Klasy do umiędzynarodowiania programów w Javie dla programistów
238 License:        GPL v3+
239 Group:          Development/Tools
240 Requires:       %{name}-devel = %{version}-%{release}
241
242 %description java-devel
243 Development classes for Java programs internationalization.
244
245 %description java-devel -l pl.UTF-8
246 Klasy do umiędzynarodowiania programów w Javie dla programistów.
247
248 %package -n xemacs-po-mode-pkg
249 Summary:        Xemacs PO-mode
250 Summary(es.UTF-8):      Facilita la edición de archivos PO (internacionalización) con emacs
251 Summary(pl.UTF-8):      Tryb PO dla Xemacsa
252 Summary(pt_BR.UTF-8):   Facilita a edição de arquivos PO (internacionalização) com o emacs
253 License:        GPL v2+
254 Group:          Applications/Editors/Emacs
255 Requires:       xemacs
256
257 %description -n xemacs-po-mode-pkg
258 Emacs PO-mode.
259
260 %description -n xemacs-po-mode-pkg -l es.UTF-8
261 Este paquete suministra las herramientas para ayudar en la edición de
262 archivos PO, como documentado en el manual del usuario del GNU
263 gettext. Mira este manual para la documentación de uso, que no se
264 incluye aquí.
265
266 %description -n xemacs-po-mode-pkg -l pl.UTF-8
267 Tryb edycji PO dla emacsa.
268
269 %description -n xemacs-po-mode-pkg -l pt_BR.UTF-8
270 Este pacote provê as ferramentas para ajudar na edição de arquivos PO,
271 como documentado no manual do usuário do GNU gettext. Veja este manual
272 para a documentação de uso, a qual não é incluída aqui.
273
274 %package autopoint
275 Summary:        gettextize replacement
276 Summary(pl.UTF-8):      Zamiennik gettextize
277 License:        GPL v3+
278 Group:          Development/Tools
279 Requires:       %{name}-devel >= 0.10.35
280 Requires:       cvs-client
281
282 %description autopoint
283 The `autopoint' program copies standard gettext infrastructure files
284 into a source package. It extracts from a macro call of the form
285 `AM_GNU_GETTEXT_VERSION(VERSION)', found in the package's
286 `configure.in' or `configure.ac' file, the gettext version used by the
287 package, and copies the infrastructure files belonging to this version
288 into the package.
289
290 %description autopoint -l pl.UTF-8
291 Program autopoint kopiuje standardowe pliki infrastruktury gettexta do
292 pakietu źródłowego. Wyciąga użytą wersję gettexta z wywołania makra w
293 postaci AM_GNU_GETTEXT_VERSION(VERSION) w pliku configure.in lub
294 configure.ac i kopiuje do pakietu pliki infrastruktury należące do tej
295 wersji.
296
297 %package -n dotnet-gettext
298 Summary:        GNU gettext for C#
299 Summary(pl.UTF-8):      GNU gettext dla C#
300 License:        LGPL v2+ (GNU.Gettext library), GPL v3+ (tools)
301 Group:          Development/Tools
302
303 %description -n dotnet-gettext
304 GNU gettext for C#.
305
306 %description -n dotnet-gettext -l pl.UTF-8
307 GNU gettext dla C#.
308
309 %prep
310 %setup -q
311 %patch0 -p1
312 %patch1 -p1
313 %patch2 -p1
314 # patch not finished yet
315 #%patch3 -p1
316 %patch4 -p1
317 %patch5 -p1
318
319 %build
320 %{__libtoolize}
321 cd autoconf-lib-link
322 %{__aclocal} -I m4 -I ../m4
323 %{__autoconf}
324 %{__automake}
325 cd ../gettext-runtime
326 %{__libtoolize}
327 %{__aclocal} -I m4 -I gnulib-m4 -I ../autoconf-lib-link/m4 -I ../m4
328 %{__autoconf}
329 %{__autoheader}
330 %{__automake}
331 cd libasprintf
332 %{__aclocal} -I ../m4 -I ../../m4
333 %{__autoconf}
334 %{__autoheader}
335 %{__automake}
336 cd ../../gettext-tools
337 %{__aclocal} -I m4 -I gnulib-m4 -I libgettextpo/gnulib-m4 -I ../autoconf-lib-link/m4 -I ../gettext-runtime/m4 -I ../m4
338 %{__autoconf}
339 %{__autoheader}
340 %{__automake}
341 cd ..
342 %{__aclocal}
343 %{__autoconf}
344 %{__automake}
345 %configure \
346         %{?with_xemacs:--with-lispdir=%{_datadir}/xemacs-packages/lisp/po-mode} \
347         --enable-nls \
348         %{!?with_dotnet:--disable-csharp} \
349         %{?with_dotnet:--enable-csharp=mono} \
350         --without-included-gettext \
351         %{?with_bootstrap:--with-included-glib} \
352         %{?with_bootstrap:--with-included-libcroco}
353 %{__make} \
354         GMSGFMT=`pwd`/gettext-tools/src/msgfmt
355
356 # msgfmt has been built, so now we can update pl.gmos
357 %{__make} pl.gmo -C gettext-runtime/po \
358         GMSGFMT=`pwd`/gettext-tools/src/msgfmt
359 %{__make} pl.gmo -C gettext-tools/po \
360         GMSGFMT=`pwd`/gettext-tools/src/msgfmt
361
362 %if %{with xemacs}
363 cd gettext-tools/misc
364 EMACS=%{_bindir}/xemacs ./elisp-comp ./po-mode.el
365 %endif
366
367 %install
368 rm -rf $RPM_BUILD_ROOT
369 install -d $RPM_BUILD_ROOT/bin
370
371 %{__make} install \
372         DESTDIR=$RPM_BUILD_ROOT
373
374 mv -f $RPM_BUILD_ROOT%{_bindir}/{,n}gettext $RPM_BUILD_ROOT/bin
375
376 # these static libs are removed in install-exec-clean
377 install gettext-tools/gnulib-lib/.libs/libgettextlib.a \
378         gettext-tools/src/.libs/libgettextsrc.a $RPM_BUILD_ROOT%{_libdir}
379
380 rm -r $RPM_BUILD_ROOT%{_docdir}/gettext
381 rm -r $RPM_BUILD_ROOT%{_docdir}/libasprintf
382 rm -f $RPM_BUILD_ROOT%{_infodir}/dir
383
384 %find_lang %{name}-runtime
385 %find_lang %{name}-tools
386
387 %clean
388 rm -rf $RPM_BUILD_ROOT
389
390 %post devel
391 /sbin/ldconfig
392 [ ! -x /usr/sbin/fix-info-dir ] || /usr/sbin/fix-info-dir -c %{_infodir} >/dev/null 2>&1
393
394 %postun devel
395 /sbin/ldconfig
396 [ ! -x /usr/sbin/fix-info-dir ] || /usr/sbin/fix-info-dir -c %{_infodir} >/dev/null 2>&1
397
398 %post   -n libasprintf -p /sbin/ldconfig
399 %postun -n libasprintf -p /sbin/ldconfig
400
401 %post -n libasprintf-devel      -p      /sbin/postshell
402 -/usr/sbin/fix-info-dir -c %{_infodir}
403
404 %postun -n libasprintf-devel    -p      /sbin/postshell
405 -/usr/sbin/fix-info-dir -c %{_infodir}
406
407 %files -f %{name}-runtime.lang
408 %defattr(644,root,root,755)
409 %attr(755,root,root) /bin/*
410 %attr(755,root,root) %{_bindir}/envsubst
411 %{_mandir}/man1/envsubst.1*
412 %{_mandir}/man1/gettext.1*
413 %{_mandir}/man1/ngettext.1*
414 %dir %{_libdir}/gettext
415 %dir %{_datadir}/gettext
416
417 %files devel -f %{name}-tools.lang
418 %defattr(644,root,root,755)
419 %doc AUTHORS ChangeLog NEWS README THANKS
420 %attr(755,root,root) %{_bindir}/*
421 %exclude %{_bindir}/autopoint
422 %exclude %{_bindir}/envsubst
423 %attr(755,root,root) %{_libdir}/libgettext*.so
424 %{_libdir}/libgettext*.la
425 # libgettextpo is for other programs, not used by gettext tools themselves
426 %attr(755,root,root) %{_libdir}/libgettextpo.so.*.*.*
427 %attr(755,root,root) %ghost %{_libdir}/libgettextpo.so.0
428 %attr(755,root,root) %{_libdir}/preloadable_libintl.so
429 %attr(755,root,root) %{_libdir}/gettext/hostname
430 %attr(755,root,root) %{_libdir}/gettext/project-id
431 %attr(755,root,root) %{_libdir}/gettext/urlget
432 %attr(755,root,root) %{_libdir}/gettext/user-email
433 %{_includedir}/gettext-po.h
434 %{_aclocaldir}/*
435 %{_infodir}/gettext*.info*
436 %{_mandir}/man1/gettextize.1*
437 %{_mandir}/man1/msg*.1*
438 %{_mandir}/man1/recode-sr-latin.1*
439 %{_mandir}/man1/xgettext.1*
440 %{_mandir}/man3/*
441
442 %{_datadir}/gettext/ABOUT-NLS
443 %attr(755,root,root) %{_datadir}/gettext/config.rpath
444 %{_datadir}/gettext/gettext.h
445 %dir %{_datadir}/gettext/intl
446 %{_datadir}/gettext/intl/[!c]*
447 %attr(755,root,root) %{_datadir}/gettext/intl/config.charset
448 %{_datadir}/gettext/msgunfmt.tcl
449 %{_datadir}/gettext/po
450 %dir %{_datadir}/gettext/projects
451 %{_datadir}/gettext/projects/index
452 %attr(755,root,root) %{_datadir}/gettext/projects/team-address
453 %dir %{_datadir}/gettext/projects/GNOME
454 %{_datadir}/gettext/projects/GNOME/teams.*
455 %attr(755,root,root) %{_datadir}/gettext/projects/GNOME/team-address
456 %attr(755,root,root) %{_datadir}/gettext/projects/GNOME/trigger
457 %dir %{_datadir}/gettext/projects/KDE
458 %{_datadir}/gettext/projects/KDE/teams.*
459 %attr(755,root,root) %{_datadir}/gettext/projects/KDE/team-address
460 %attr(755,root,root) %{_datadir}/gettext/projects/KDE/trigger
461 %dir %{_datadir}/gettext/projects/TP
462 %{_datadir}/gettext/projects/TP/teams.*
463 %attr(755,root,root) %{_datadir}/gettext/projects/TP/team-address
464 %attr(755,root,root) %{_datadir}/gettext/projects/TP/trigger
465 %{_datadir}/gettext/styles
466
467 %files static
468 %defattr(644,root,root,755)
469 %{_libdir}/libgettext*.a
470
471 %if %{with asprintf}
472 %files -n libasprintf
473 %defattr(644,root,root,755)
474 %doc gettext-runtime/libasprintf/{AUTHORS,ChangeLog,README}
475 %attr(755,root,root) %{_libdir}/libasprintf.so.*.*.*
476 %attr(755,root,root) %ghost %{_libdir}/libasprintf.so.0
477
478 %files -n libasprintf-devel
479 %defattr(644,root,root,755)
480 %attr(755,root,root) %{_libdir}/libasprintf.so
481 %{_libdir}/libasprintf.la
482 %{_includedir}/autosprintf.h
483 %{_infodir}/autosprintf.info*
484
485 %files -n libasprintf-static
486 %defattr(644,root,root,755)
487 %{_libdir}/libasprintf.a
488 %endif
489
490 %if %{build_java}
491 %files java
492 %defattr(644,root,root,755)
493 %{_datadir}/gettext/libintl.jar
494
495 %files java-devel
496 %defattr(644,root,root,755)
497 %doc gettext-runtime/intl-java/javadoc2
498 %attr(755,root,root) %{_libdir}/gettext/gnu.gettext.DumpResource
499 %attr(755,root,root) %{_libdir}/gettext/gnu.gettext.GetURL
500 %{_datadir}/gettext/javaversion.class
501 %endif
502
503 %if %{with xemacs}
504 %files -n xemacs-po-mode-pkg
505 %defattr(644,root,root,755)
506 %dir %{_datadir}/xemacs-packages/lisp/po-mode
507 %{_datadir}/xemacs-packages/lisp/po-mode/*.elc
508 %endif
509
510 %files autopoint
511 %defattr(644,root,root,755)
512 %attr(755,root,root) %{_bindir}/autopoint
513 %{_datadir}/gettext/archive.tar.gz
514 %{_mandir}/man1/autopoint.1*
515
516 %if %{with dotnet}
517 %files -n dotnet-gettext
518 %defattr(644,root,root,755)
519 %{_libdir}/GNU.Gettext.dll
520 %{_libdir}/gettext/msgfmt.net.exe
521 %{_libdir}/gettext/msgunfmt.net.exe
522 %endif
This page took 0.108534 seconds and 4 git commands to generate.