3 # _without_ada - build without ADA support
4 # _without_java - build without Java support
5 # _without_objc - build without objc support
7 %define DASHED_SNAP %{nil}
8 %define SNAP %(echo %{DASHED_SNAP} | sed -e "s#-##g")
9 %define GCC_VERSION 3.3
10 %define KSI_VERSION 1.1.0.1567
12 Summary: GNU C Compiler
13 Summary(pl): Kompilator C GNU
14 Summary(pt_BR): C Compilador GNU (GCC)
16 Version: %{GCC_VERSION}
20 Group: Development/Languages
21 Source0: ftp://gcc.gnu.org/pub/gcc/releases/gcc-%{GCC_VERSION}/%{name}-%{GCC_VERSION}.tar.bz2
22 Source1: ftp://ftp.pld.org.pl/people/malekith/ksi/ksi-%{KSI_VERSION}.tar.gz
23 Source2: %{name}-non-english-man-pages.tar.bz2
24 Patch0: %{name}-info.patch
25 Patch1: %{name}-paths.patch
26 Patch4: %{name}-nolocalefiles.patch
27 Patch6: %{name}-ada-link-new-libgnat.patch
28 # -- stolen patches from RH --
29 Patch10: gcc32-ada-link.patch
30 Patch16: gcc32-boehm-gc-libs.patch
31 Patch17: gcc32-bogus-inline.patch
32 Patch18: gcc32-c++-nrv-test.patch
33 Patch20: gcc32-c++-tsubst-asm.patch
34 Patch22: gcc32-debug-pr7241.patch
36 Patch24: gcc32-duplicate-decl.patch
37 Patch25: gcc32-dwarf2-pr6381.patch
38 Patch26: gcc32-dwarf2-pr6436-test.patch
39 Patch27: gcc32-fde-merge-compat.patch
41 Patch32: gcc32-i386-memtest-test.patch
42 Patch36: gcc32-inline-label.patch
43 Patch37: gcc32-java-no-rpath.patch
44 Patch40: gcc32-test-rh65771.patch
45 Patch41: gcc32-test-rotate.patch
46 BuildRequires: autoconf
48 BuildRequires: fileutils >= 4.0.41
50 %{!?_without_ada:BuildRequires: gcc-ada}
51 BuildRequires: glibc-devel >= 2.2.5-20
52 BuildRequires: perl-devel
53 BuildRequires: texinfo >= 4.1
54 BuildRequires: zlib-devel
55 BuildRequires: gettext-devel
56 Requires: binutils >= 2.12.90.0.4
57 Requires: cpp = %{GCC_VERSION}
58 Requires: libgcc = %{GCC_VERSION}
59 Conflicts: glibc-devel < 2.2.5-20
60 URL: http://gcc.gnu.org/
61 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
66 A compiler aimed at integrating all the optimizations and features
67 necessary for a high-performance and stable development environment.
70 Kompilator, posiadaj±cy du¿e mo¿liwo¶ci optymalizacyjne niezbêdne do
71 wyprodukowania szybkiego i stablinego kodu wynikowego.
74 Este pacote adiciona infraestrutura básica e suporte a linguagem C
75 ao Gnu Compiler Collection.
78 Summary: Shared gcc library
79 Summary(pl): Biblioteka gcc
80 Summary(pt_BR): Biblioteca runtime para o GCC
82 Version: %{GCC_VERSION}
85 %description -n libgcc
88 %description -n libgcc -l pl
89 Biblioteka dynamiczna gcc.
91 %description -n libgcc -l pt_BR
92 Biblioteca runtime para o GCC.
95 Summary: C++ support for gcc
96 Summary(pl): Obs³uga C++ dla gcc
97 Summary(pt_BR): Suporte C++ para o gcc
98 Group: Development/Languages
101 Requires: gcc = %{GCC_VERSION}
104 This package adds C++ support to the GNU C compiler. It includes
105 support for most of the current C++ specification, including templates
106 and exception handling. It does not include a standard C++ library,
107 which is available separately.
109 %description c++ -l de
110 Dieses Paket enthält die C++-Unterstützung für den GNU-C-Compiler. Es
111 unterstützt die aktuelle C++-Spezifikation, inkl. Templates und
112 Ausnahmeverarbeitung. Eine C++-Standard-Library ist nicht enthalten -
113 sie ist getrennt erhältlich.
115 %description c++ -l fr
116 Ce package ajoute un support C++ au compilateur c GNU. Il comprend un
117 support pour la plupart des spécifications actuelles de C++, dont les
118 modéles et la gestion des exceptions. Il ne comprend pas une
119 bibliothéque C++ standard, qui est disponible séparément.
121 %description c++ -l pl
122 Ten pakiet dodaje obs³ugê C++ do kompilatora gcc. Ma wsparcie dla
123 du¿ej ilo¶ci obecnych specyfikacji C++, nie zawiera natomiast
124 standardowych bibliotek C++, które s± w oddzielnym pakiecie.
126 %description c++ -l pt_BR
127 Este pacote adiciona suporte C++ para o gcc.
129 %description c++ -l tr
130 Bu paket, GNU C derleyicisine C++ desteði ekler. 'Template'ler ve
131 aykýrý durum iþleme gibi çoðu güncel C++ tanýmlarýna uyar. Standart
132 C++ kitaplýðý bu pakette yer almaz.
135 Summary: Objective C support for gcc
136 Summary(de): Objektive C-Unterstützung für gcc
137 Summary(fr): Gestion d'Objective C pour gcc
138 Summary(pl): Obs³uga obiektowego C dla kompilatora gcc
139 Summary(tr): gcc için Objective C desteði
140 Group: Development/Languages
143 Requires: libobjc = %{GCC_VERSION}
144 Requires: gcc = %{GCC_VERSION}
147 This package adds Objective C support to the GNU C compiler. Objective
148 C is a object oriented derivative of the C language, mainly used on
149 systems running NeXTSTEP. This package does not include the standard
150 objective C object library.
152 %description objc -l de
153 Dieses Paket ergänzt den GNU-C-Compiler durch Objective-C-Support.
154 Objective C ist ein objektorientiertes Derivat von C, das zur
155 Hauptsache auf Systemen mit NeXTSTEP zum Einsatz kommt. Die
156 Standard-Objective-C-Objekt-Library ist nicht Teil des Pakets.
158 %description objc -l fr
159 Ce package ajoute un support Objective C au compilateur C GNU.
160 L'Objective C est un langage orienté objetdérivé du langage C,
161 principalement utilisé sur les systèmes NeXTSTEP. Ce package n'inclue
162 pas la bibliothéque Objective C standard.
164 %description objc -l pl
165 Ten pakiet dodaje obs³ugê obiektowego C do kompilatora gcc. Obiektowe
166 C (objc) jest zorientowan± obiektowo pochodn± jêzyka C, u¿ywan±
167 g³ównie w systemach u¿ywaj±cych NeXTSTEP. W pakiecie nie ma
168 standardowej biblioteki objc (która znajduje siê w osobnym pakiecie).
170 %description objc -l tr
171 Bu paket, GNU C derleyicisine Objective C desteði ekler. Objective C,
172 C dilinin nesne yönelik bir türevidir ve NeXTSTEP altýnda çalýþan
173 sistemlerde yaygýn olarak kullanýlýr. Standart Objective C nesne
174 kitaplýðý bu pakette yer almaz.
177 Summary: Objective C Libraries
178 Summary(pl): Biblioteki Obiektowego C
180 Version: %{GCC_VERSION}
183 %description -n libobjc
184 Objective C Libraries.
186 %description -n libobjc -l pl
187 Biblioteki Obiektowego C.
189 %package -n libobjc-static
190 Summary: Static Objective C Libraries
191 Summary(pl): Statyczne Biblioteki Obiektowego C
192 Group: Development/Libraries
193 Version: %{GCC_VERSION}
194 Requires: libobjc = %{GCC_VERSION}
196 %description -n libobjc-static
197 Static Objective C Libraries.
199 %description -n libobjc-static -l pl
200 Statyczne biblioteki Obiektowego C.
203 Summary: Fortran 77 support for gcc
204 Summary(pl): Obs³uga Fortranu 77 dla gcc
205 Summary(pt_BR): Suporte Fortran 77 para o GCC
206 Group: Development/Languages/Fortran
207 Version: %{GCC_VERSION}
209 Requires: libg2c = %{GCC_VERSION}
212 This apckage adds support for compiling Fortran 77 programs with the
215 %description g77 -l pl
216 Ten pakiet dodaje obs³ugê Fortranu 77 do kompilatora gcc. Jest
217 potrzebny do kompilowania programów pisanych w jêzyku Fortran 77.
219 %description g77 -l pt_BR
220 Suporte Fortran 77 para o GCC.
223 Summary: Fortran 77 Libraries
224 Summary(pl): Biblioteki Fortranu 77
226 Version: %{GCC_VERSION}
228 %description -n libg2c
229 Fortran 77 Libraries.
231 %description -n libg2c -l pl
232 Biblioteki Fortranu 77.
234 %package -n libg2c-static
235 Summary: Static Fortran 77 Libraries
236 Summary(pl): Statyczne Biblioteki Fortranu 77
237 Group: Development/Libraries
238 Version: %{GCC_VERSION}
239 Requires: libg2c = %{GCC_VERSION}
241 %description -n libg2c-static
242 Static Fortran 77 Libraries.
244 %description -n libg2c-static -l pl
245 Statyczne biblioteki Fortranu 77.
248 Summary: Java support for gcc
249 Summary(pl): Obs³uga Javy dla gcc
250 Group: Development/Languages/Java
251 Version: %{GCC_VERSION}
252 Requires: %{name} = %{version}
253 Requires: libgcj >= 3.0.0
254 Requires: libgcj-devel >= 3.0.0
255 Requires: java-shared
256 Provides: gcj = %{epoch}:%{GCC_VERSION}-%{release}
259 This package adds experimental support for compiling Java(tm) programs
260 and bytecode into native code. To use this you will also need the
263 %description -l pl java
264 Wsparcie dla kompilowania programów Java(tm) zrówno do bajt-kodu jak i
265 do natywnego kodu. Dodatkowo wymagany jest pakiet libgcj, aby mo¿na
266 by³o przeprowadziæ kompilacjê.
269 Summary: Shared java tools
270 Summary(pl): Wspó³dzielone narzêdzia javy
271 Group: Development/Languages/Java
272 Version: %{GCC_VERSION}
273 Provides: jar = %{epoch}:%{GCC_VERSION}-%{release}
274 Provides: java-shared
276 Obsoletes: java-shared
279 %description java-tools
280 This package contains tools that are common for every Java(tm) implementation,
283 %description java-tools -l pl
284 Pakiet ten zawiera narzêdzia wspólne dla ka¿dej implementacji Javy(tm), takie
288 Summary: Java Class Libraries
289 Summary(pl): Biblioteki Klas Javy
291 Version: %{GCC_VERSION}
295 %description -n libgcj
296 Java Class Libraries.
298 %description -n libgcj -l pl
299 Biblioteki Klas Javy.
301 %package -n libgcj-devel
302 Summary: Development files for Java Class Libraries
303 Summary(pl): Pliki nag³ówkowe dla Bibliotek Klas Javy
304 Group: Development/Libraries
305 Version: %{GCC_VERSION}
306 Requires: libgcj = %{GCC_VERSION}
307 Requires: %{name}-java
308 Obsoletes: libgcj3-devel
310 %description -n libgcj-devel
311 Development files for Java Class Libraries.
313 %description -n libgcj-devel -l pl
314 Pliki nag³ówkowe dla Bibliotek Klas Javy.
316 %package -n libgcj-static
317 Summary: Static Java Class Libraries
318 Summary(pl): Statyczne Biblioteki Klas Javy
319 Group: Development/Libraries
320 Version: %{GCC_VERSION}
321 Requires: libstdc++-devel = %{GCC_VERSION}
322 Requires: libgcj-devel = %{GCC_VERSION}
324 %description -n libgcj-static
325 Static Java Class Libraries.
327 %description -n libgcj-static -l pl
328 Statyczne Biblioteki Klas Javy.
330 %package -n libstdc++
331 Summary: GNU c++ library
332 Summary(pl): Biblioteki GNU C++
333 Summary(pt_BR): Biblioteca C++ GNU
335 Version: %{GCC_VERSION}
337 Obsoletes: libstdc++3
339 %description -n libstdc++
340 This is the GNU implementation of the standard C++ libraries, along
341 with additional GNU tools. This package includes the shared libraries
342 necessary to run C++ applications.
344 %description -n libstdc++ -l de
345 Dies ist die GNU-Implementierung der Standard-C++-Libraries mit
346 weiteren GNU-Tools. Dieses Paket enthält die zum Ausführen von
347 C++-Anwendungen erforderlichen gemeinsam genutzten Libraries.
349 %description -n libstdc++ -l es
350 Este es el soporte de las bibliotecas padrón del C++, junto con
351 herramientas GNU adicionales. El paquete incluye las bibliotecas
352 compartidas necesarias para ejecutar aplicaciones C++.
354 %description -n libstdc++ -l fr
355 Ceci est l'implémentation GNU des librairies C++ standard, ainsi que
356 des outils GNU supplémentaires. Ce package comprend les librairies
357 partagées nécessaires à l'exécution d'application C++.
359 %description -n libstdc++ -l pl
360 Pakiet ten zawiera biblioteki bêd±ce implementacj± standardowych
361 bibliotek C++. Znajduj± siê w nim biblioteki dynamiczne niezbêdne do
362 uruchomienia aplikacji napisanych w C++.
364 %description -n libstdc++ -l pt_BR
365 Este pacote é uma implementação da biblioteca padrão C++ v3, um
366 subconjunto do padrão ISO 14882.
368 %description -n libstdc++ -l tr
369 Bu paket, standart C++ kitaplýklarýnýn GNU gerçeklemesidir ve C++
370 uygulamalarýnýn koþturulmasý için gerekli kitaplýklarý içerir.
372 %package -n libstdc++-devel
373 Summary: Header files and documentatino for C++ development
374 Summary(de): Header-Dateien zur Entwicklung mit C++
375 Summary(fr): Fichiers d'en-tête et biblitothèques pour développer en C++
376 Summary(pl): Pliki nag³ówkowe i dokumentacja do biblioteki standardowej C++
377 Summary(pt_BR): Arquivos de inclusão e bibliotecas para o desenvolvimento em C++
378 Summary(tr): C++ ile program geliþtirmek için gerekli dosyalar
379 Group: Development/Libraries
380 Version: %{GCC_VERSION}
381 Requires: libstdc++ = %{GCC_VERSION}
382 Requires: %{name}-c++ = %{GCC_VERSION}
383 Obsoletes: libg++-devel
384 Obsoletes: libstdc++3-devel
386 %description -n libstdc++-devel
387 This is the GNU implementation of the standard C++ libraries. This
388 package includes the header files needed for C++ development and
389 library documentation.
391 %description -n libstdc++-devel -l es
392 Este es el soporte de las bibliotecas padrón del lenguaje C++. Este paquete
393 incluye los archivos de inclusión y bibliotecas necesarios para desarrollo de
394 programas en lenguaje C++.
396 %description -n libstdc++-devel -l pl
397 Pakiet ten zawiera biblioteki bêd±ce implementacj± standardowych
398 bibliotek C++. Znajduj± siê w nim pliki nag³ówkowe wykorzystywane przy
399 programowaniu w jêzyku C++ oraz dokumentacja biblioteki standardowej.
401 %description -n libstdc++-devel -l pt_BR
402 Este pacote inclui os arquivos de inclusão e bibliotecas necessárias para
403 desenvolvimento de programas C++.
405 %package -n libstdc++-static
406 Summary: Static C++ standard library
407 Summary(pl): Statyczna biblioteka standardowa C++
408 Group: Development/Libraries
409 Version: %{GCC_VERSION}
410 Requires: libstdc++-devel = %{GCC_VERSION}
412 %description -n libstdc++-static
413 Static C++ standard library.
415 %description -n libstdc++-static -l pl
416 Statycza biblioteka standardowa C++.
419 Summary: Foreign Function Interface library
420 Summary(pl): Biblioteka zewnêtrznych wywo³añ funkcji
422 Version: %{GCC_VERSION}
424 %description -n libffi
425 The libffi library provides a portable, high level programming
426 interface to various calling conventions. This allows a programmer to
427 call any function specified by a call interface description at run
430 %description -n libffi -l pl
431 Biblioteka libffi dostarcza przno¶nego, wysokopoziomowego miêdzymordzia
432 do ró¿nych konwencji wywo³añ funkcji. Pozwala to programi¶cie wywo³ywaæ
433 dowolne funkcje podaj±c konwencjê wywo³ania w czasie wykonania.
435 %package -n libffi-devel
436 Summary: Development files for Foreign Function Interface library
437 Summary(pl): Pliki nag³ówkowe dla libffi
438 Group: Development/Libraries
439 Version: %{GCC_VERSION}
440 Requires: libffi = %{GCC_VERSION}
442 %description -n libffi-devel
443 Development files for Foreign Function Interface library.
445 %description -n libffi-devel -l pl
446 Pliki nag³ówkowe dla libffi.
448 %package -n libffi-static
449 Summary: Static Foreign Function Interface library
450 Summary(pl): Statyczna biblioteka libffi
451 Group: Development/Libraries
452 Version: %{GCC_VERSION}
453 Requires: libffi-devel = %{GCC_VERSION}
455 %description -n libffi-static
456 Static Foreign Function Interface library.
458 %description -n libffi-static -l pl
459 Statyczna biblioteka libffi.
462 Summary: Ada support for gcc
463 Summary(pl): Obs³uga Ady do gcc
464 Group: Development/Languages
465 Version: %{GCC_VERSION}
466 Requires: libgnat = %{GCC_VERSION}
467 Requires: gcc = %{GCC_VERSION}
469 Obsoletes: gnat-devel
472 This package adds experimental support for compiling Ada programs.
474 %description -l pl ada
475 Ten pakiet dodaje eksperymentalne wsparcie dla kompilacji programów
479 Summary: Ada standard libraries
480 Summary(pl): Biblioteki standardowe dla Ady
482 Version: %{GCC_VERSION}
486 %description -n libgnat
487 This package contains shared libraries needed to run programs written
490 %description -n libgnat -l pl
491 Ten pakiet zawiera biblioteki potrzebne do uruchamiania programów napisanych
494 %package -n libgnat-static
495 Summary: Static Ada standard libraries
496 Summary(pl): Statyczne biblioteki standardowe dla Ady
498 Version: %{GCC_VERSION}
499 Obsoletes: gnat-static
501 %description -n libgnat-static
502 This package contains static libraries for programs written in Ada.
504 %description -n libgnat-static -l pl
505 Ten pakiet zawiera biblioteki statyczne dla programów napisanych w
509 Summary: Ksi support for gcc
510 Summary(pl): Obs³uga Ksi dla gcc
511 Version: %{GCC_VERSION}.%{KSI_VERSION}
512 Group: Development/Languages
513 Requires: gcc = %{GCC_VERSION}
516 This package adds experimental support for compiling Ksi programs
517 into native code. You proabably don't need it, unless your are going
518 to develop a compiler using Ksi as intermediate representation or
519 you are using such compiler (like Gont).
521 %description ksi -l pl
522 Ten pakiet dodaje eksperymentalne wsparcie dla kompilacji programów
523 w Ksi do kodu maszynowego. Prawdopodobnie nie potrzebujesz go, chyba
524 ¿e zamierzasz pisaæ kompilator u¿ywaj±cy Ksi jako reprezentacji
525 po¶rednicz±cej, lub u¿ywasz takiego kompilatora (jak Gont).
528 Summary: The C Pre Processor
529 Summary(pl): Preprocesor C
530 Summary(pt_BR): Preprocessador para a linguagem C
531 Group: Development/Languages
532 Version: %{GCC_VERSION}
537 The C preprocessor is a "macro processor" that is used automatically
538 by the C compiler to transform your program before actual compilation.
539 It is called a macro processor because it allows you to define
540 "macros", which are brief abbreviations for longer constructs.
542 The C preprocessor provides four separate facilities that you can use
545 - Inclusion of header files. These are files of declarations that can
546 be substituted into your program.
547 - Macro expansion. You can define "macros", which are abbreviations
548 for arbitrary fragments of C code, and then the C preprocessor will
549 replace the macros with their definitions throughout the program.
550 - Conditional compilation. Using special preprocessing directives, you
551 can include or exclude parts of the program according to various
553 - Line control. If you use a program to combine or rearrange source
554 files into an intermediate file which is then compiled, you can use
555 line control to inform the compiler of where each source line
556 originally came from.
558 %description -n cpp -l es
559 Um preprocessador para a linguagem C.
561 %description -n cpp -l pl
562 Przeprocesor C jest "makro procesorem" który jest automatycznie
563 u¿ywany przez kompilator C do obróbki kompilowanego programu przed
564 w³a¶ciw± kompilacj±. Jest on nazywany makroprocesorem, poniewa¿
565 umo¿liwia definiowanie i rozwijanie makr umo¿liwiaj±cych skracanie
566 d³ugich konstrukcji w jêzyku C.
568 Preprocesor C umo¿liwia wykonywanie czterech ró¿nych typów operacji:
570 - Do³±czanie plików (np. nag³ówkowych). Wstawia pliki w miejscu
571 deklaracji polecenia do³±czenia innego pliku.
572 - Rozwijanie makr. Mo¿na definiowaæ "makra" nadaj±c im identyfikatory,
573 których pó¼niejsze u¿ycie powoduje podczas rozwijania podmienienie
574 indentyfikatora deklarowan± wcze¶niej warto¶ci±.
575 - Kompilacja warunkowa. W zale¿no¶ci od obecno¶ci symboli i dyrektyw w
576 ¶rodowisku preprocesora s± w³±czane warunkowo, b±d¼ nie, pewne
577 fragmenty obrabianego strumienia tekstów.
578 - Kontrola linii ¼ród³a. Niezale¿nie od tego jakim przeobra¿eniom
579 podlega wynikowy strumieñ danych w wyniku rozwijania makr i do³±czania
580 s± zapamiêtywane informacje o tym, której linii pliku ¼ród³owego
581 odpowiada fragment pliku wynikowego.
583 %description -n cpp -l pt_BR
584 O preprocessador C é um "processador de macros", que é utilizado pelo
585 compilador C para fazer algumas modificações no seu programa, antes da
586 compilação em si. Ele é chamado de "processador de macros" porque
587 permite a você definir "macros", que são abreviações para construções
590 O preprocessador C fornece quatro funcionalidades básicas: inclusão de
591 arquivos de cabeçalho; expansão de macros; compilação condicional;
592 e controle da numeração das linhas do programa.
595 %setup -q -a1 -n %{name}-%{GCC_VERSION}
596 mv ksi-%{KSI_VERSION} gcc/ksi
620 # because we distribute modified version of gcc...
621 perl -pi -e 's/(version.*)";/$1 (PLD Linux)";/' gcc/version.c
622 perl -pi -e 's@(bug_report_url.*<URL:).*";@$1http://bugs.pld.org.pl/>";@' gcc/version.c
625 # cd gcc && autoconf; cd ..
626 # autoconf is not needed!
627 rm -rf obj-%{_target_platform} && install -d obj-%{_target_platform} && cd obj-%{_target_platform}
629 CFLAGS="%{rpmcflags}" \
630 CXXFLAGS="%{rpmcflags}" \
631 TEXCONFIG=false ../configure \
632 --prefix=%{_prefix} \
633 --infodir=%{_infodir} \
634 --mandir=%{_mandir} \
636 --enable-threads=posix \
637 --enable-__cxa_atexit \
638 --enable-languages="c,c++,f77%{?!_without_objc:,objc}%{!?_without_ada:,ada}%{!?_without_java:,java},ksi" \
646 --with-slibdir=%{_slibdir} \
650 PATH=$PATH:/sbin:%{_sbindir}
652 # this dirty hack is relict of setting, where objdir is subdir of srcdir
653 %if %{!?_without_ada:1}%{?_without_ada:0}
654 sed -e 's/srcdir=\$(fsrcdir)/srcdir=\$(fsrcdir) VPATH=\$(fsrcdir)/' \
655 gcc/ada/Makefile > makefile.tmp
656 mv -f makefile.tmp gcc/ada/Makefile
660 %{__make} -C obj-%{_target_platform} bootstrap-lean \
661 LDFLAGS_FOR_TARGET="%{rpmldflags}" \
665 %if %{!?_without_ada:1}%{?_without_ada:0}
666 %{__make} -C obj-%{_target_platform}/gcc gnatlib gnattools gnatlib-shared \
667 LDFLAGS_FOR_TARGET="%{rpmldflags}" \
673 rm -rf $RPM_BUILD_ROOT
674 install -d $RPM_BUILD_ROOT{/lib,%{_datadir},%{_infodir}}
676 cd obj-%{_target_platform}
677 PATH=$PATH:/sbin:%{_sbindir}
680 DESTDIR=$RPM_BUILD_ROOT
682 ln -sf gcc $RPM_BUILD_ROOT%{_bindir}/cc
683 echo ".so gcc.1" > $RPM_BUILD_ROOT%{_mandir}/man1/cc.1
685 ln -sf g77 $RPM_BUILD_ROOT%{_bindir}/f77
686 echo ".so g77.1" > $RPM_BUILD_ROOT%{_mandir}/man1/f77.1
688 %if %{!?_without_ada:1}%{?_without_ada:0}
689 # move ada shared libraries to proper place...
690 mv $RPM_BUILD_ROOT%{_libdir}/gcc-lib/%{_target_cpu}*/*/adalib/*.so.1 \
691 $RPM_BUILD_ROOT%{_libdir}/
692 # check if symlink to be made is valid
693 test -f $RPM_BUILD_ROOT%{_libdir}/libgnat-3.15.so.1
694 ln -sf libgnat-3.15.so.1 $RPM_BUILD_ROOT%{_libdir}/libgnat-3.15.so
695 ln -sf libgnarl-3.15.so.1 $RPM_BUILD_ROOT%{_libdir}/libgnarl-3.15.so
696 ln -sf libgnat-3.15.so $RPM_BUILD_ROOT%{_libdir}/libgnat.so
697 ln -sf libgnarl-3.15.so $RPM_BUILD_ROOT%{_libdir}/libgnarl.so
700 ln -sf %{_bindir}/cpp $RPM_BUILD_ROOT/lib/cpp
704 %if %{!?_without_java:1}%{?_without_java:0}
706 cp -f libjava/doc/cni.sgml libjava/READ* java-doc
707 cp -f fastjar/README java-doc/README.fastjar
708 cp -f libffi/README java-doc/README.libffi
709 cp -f libffi/LICENSE java-doc/LICENSE.libffi
712 %if %{?!_without_objc:1}0
713 cp -f libobjc/README gcc/objc/README.libobjc
716 # avoid -L poisoning in *.la - there should be only -L%{_libdir}/gcc-lib/*/%{version}
717 for f in libstdc++.la libsupc++.la %{!?_without_java:libgcj.la} ; do
718 perl -pi -e 's@-L[^ ]*[acs.] @@g' $RPM_BUILD_ROOT%{_libdir}/$f
720 # normalize libdir, to avoid propagation of unnecessary RPATHs by libtool
721 for f in libstdc++.la libsupc++.la libg2c.la \
722 %{!?_without_java:libgcj.la lib-org-w3c-dom.la lib-org-xml-sax.la libffi.la} \
723 %{!?_without_objc:libobjc.la}; do
724 perl -pi -e "s@^libdir='.*@libdir='/usr/lib'@" $RPM_BUILD_ROOT%{_libdir}/$f
727 bzip2 -dc %{SOURCE2} | tar xf - -C $RPM_BUILD_ROOT%{_mandir}
728 mv -f $RPM_BUILD_ROOT%{_mandir}/ja/man1/{cccp,cpp}.1
730 # include/ contains install-tools/include/* and headers that were fixed up
731 # by fixincludes, we don't want former
732 gccdir=$(echo $RPM_BUILD_ROOT%{_libdir}/gcc-lib/%{_target_cpu}*/*/)
734 # we have to save these however
735 mv -f $gccdir/include/{%{?!_without_objc:objc,}g2c.h,syslimits.h%{?!_without_java:,gcj}} $gccdir/tmp
736 rm -rf $gccdir/include
737 mv -f $gccdir/tmp $gccdir/include
738 cp $gccdir/install-tools/include/*.h $gccdir/include
739 # but we don't want anything more from install-tools
740 rm -rf $gccdir/install-tools/
743 %find_lang libstdc\+\+
746 rm -rf $RPM_BUILD_ROOT
749 [ ! -x /usr/sbin/fix-info-dir ] || /usr/sbin/fix-info-dir -c %{_infodir} >/dev/null 2>&1
752 [ ! -x /usr/sbin/fix-info-dir ] || /usr/sbin/fix-info-dir -c %{_infodir} >/dev/null 2>&1
755 [ ! -x /usr/sbin/fix-info-dir ] || /usr/sbin/fix-info-dir -c %{_infodir} >/dev/null 2>&1
758 [ ! -x /usr/sbin/fix-info-dir ] || /usr/sbin/fix-info-dir -c %{_infodir} >/dev/null 2>&1
761 [ ! -x /usr/sbin/fix-info-dir ] || /usr/sbin/fix-info-dir -c %{_infodir} >/dev/null 2>&1
764 [ ! -x /usr/sbin/fix-info-dir ] || /usr/sbin/fix-info-dir -c %{_infodir} >/dev/null 2>&1
767 [ ! -x /usr/sbin/fix-info-dir ] || /usr/sbin/fix-info-dir -c %{_infodir} >/dev/null 2>&1
770 [ ! -x /usr/sbin/fix-info-dir ] || /usr/sbin/fix-info-dir -c %{_infodir} >/dev/null 2>&1
773 [ ! -x /usr/sbin/fix-info-dir ] || /usr/sbin/fix-info-dir -c %{_infodir} >/dev/null 2>&1
776 [ ! -x /usr/sbin/fix-info-dir ] || /usr/sbin/fix-info-dir -c %{_infodir} >/dev/null 2>&1
778 %post -p /sbin/ldconfig -n libgcc
779 %postun -p /sbin/ldconfig -n libgcc
780 %post -p /sbin/ldconfig -n libstdc++
781 %postun -p /sbin/ldconfig -n libstdc++
782 %post -p /sbin/ldconfig -n libobjc
783 %postun -p /sbin/ldconfig -n libobjc
784 %post -p /sbin/ldconfig -n libg2c
785 %postun -p /sbin/ldconfig -n libg2c
786 %post -p /sbin/ldconfig -n libgcj
787 %postun -p /sbin/ldconfig -n libgcj
788 %post -p /sbin/ldconfig -n libgnat
789 %postun -p /sbin/ldconfig -n libgnat
790 %post -p /sbin/ldconfig -n libffi
791 %postun -p /sbin/ldconfig -n libffi
793 %files -f %{name}.lang
794 %defattr(644,root,root,755)
796 %dir %{_libdir}/gcc-lib
797 %dir %{_libdir}/gcc-lib/%{_target_cpu}*
798 %dir %{_libdir}/gcc-lib/%{_target_cpu}*/*
799 %dir %{_libdir}/gcc-lib/%{_target_cpu}*/*/include
800 %attr(755,root,root) %{_bindir}/%{_target_cpu}*-gcc
801 %attr(755,root,root) %{_bindir}/gcc
802 %attr(755,root,root) %{_bindir}/gccbug
803 %attr(755,root,root) %{_bindir}/gcov
804 %attr(755,root,root) %{_bindir}/cc
806 %{_mandir}/man1/gcc.1*
807 %{_mandir}/man1/cc.1*
808 %{_mandir}/man1/gcov.1*
809 %lang(fr) %{_mandir}/fr/man1/gcc.1*
810 %lang(ja) %{_mandir}/ja/man1/gcc.1*
813 %{_libdir}/gcc-lib/%{_target_cpu}*/*/libgcc.a
814 %{_libdir}/gcc-lib/%{_target_cpu}*/*/libgcc_eh.a
815 %{_libdir}/gcc-lib/%{_target_cpu}*/*/specs
816 %attr(644,root,root) %{_libdir}/gcc-lib/%{_target_cpu}*/*/crt*.o
818 %attr(644,root,root) %{_libdir}/gcc-lib/%{_target_cpu}*/*/ecrt*.o
819 %attr(644,root,root) %{_libdir}/gcc-lib/%{_target_cpu}*/*/ncrt*.o
820 %{_libdir}/gcc-lib/%{_target_cpu}*/*/nof
823 %attr(755,root,root) %{_libdir}/gcc-lib/%{_target_cpu}*/*/cc1
824 %attr(755,root,root) %{_libdir}/gcc-lib/%{_target_cpu}*/*/collect2
826 %{_libdir}/gcc-lib/%{_target_cpu}*/*/include/*.h
827 %exclude %{_libdir}/gcc-lib/%{_target_cpu}*/*/include/g2c.h
830 %defattr(644,root,root,755)
831 %attr(755,root,root) %{_slibdir}/lib*.so*
834 %defattr(644,root,root,755)
835 %attr(755,root,root) %{_bindir}/g++
836 %attr(755,root,root) %{_bindir}/%{_target_cpu}*-g++
837 %attr(755,root,root) %{_bindir}/c++
838 %attr(755,root,root) %{_bindir}/%{_target_cpu}*-c++
839 %attr(755,root,root) %{_libdir}/gcc-lib/%{_target_cpu}*/*/cc1plus
840 %{_libdir}/libsupc++.la
842 %{_libdir}/nof/libsupc++.la
843 %{_libdir}/nof/libsupc++.a
845 %{_libdir}/libsupc++.a
846 %{_mandir}/man1/g++.1*
847 %lang(ja) %{_mandir}/ja/man1/g++.1*
849 %files -n libstdc++ -f libstdc++.lang
850 %defattr(644,root,root,755)
851 %attr(755,root,root) %{_libdir}/libstdc++.so.*.*.*
853 %attr(755,root,root) %{_libdir}/nof/libstdc++.so.*.*.*
856 %files -n libstdc++-devel
857 %defattr(644,root,root,755)
858 %doc libstdc++-v3/docs/html
859 %dir %{_includedir}/c++
860 %{_includedir}/c++/%{GCC_VERSION}
861 %attr(755,root,root) %{_libdir}/libstdc++.so
862 %{_libdir}/libstdc++.la
864 %attr(755,root,root) %{_libdir}/nof/libstdc++.so
865 %{_libdir}/nof/libstdc++.la
868 %files -n libstdc++-static
869 %defattr(644,root,root,755)
870 %{_libdir}/libstdc++.a
872 %{_libdir}/nof/libstdc++.a
875 %if %{?!_without_objc:1}0
877 %defattr(644,root,root,755)
879 %attr(755,root,root) %{_libdir}/gcc-lib/%{_target_cpu}*/*/cc1obj
880 %attr(755,root,root) %{_libdir}/libobjc.so
881 %{_libdir}/libobjc.la
883 %attr(755,root,root) %{_libdir}/nof/libobjc.so
884 %{_libdir}/nof/libobjc.la
886 %{_libdir}/gcc-lib/%{_target_cpu}*/*/include/objc
889 %defattr(644,root,root,755)
890 %attr(755,root,root) %{_libdir}/libobjc.so.*.*.*
892 %attr(755,root,root) %{_libdir}/nof/libobjc.so.*.*.*
895 %files -n libobjc-static
896 %defattr(644,root,root,755)
899 %{_libdir}/nof/libobjc.a
904 %defattr(644,root,root,755)
905 %attr(755,root,root) %{_bindir}/g77
906 %attr(755,root,root) %{_bindir}/f77
908 %attr(755,root,root) %{_libdir}/gcc-lib/%{_target_cpu}*/*/f771
909 %{_libdir}/libfrtbegin.a
911 %attr(755,root,root) %{_libdir}/libg2c.so
913 %{_libdir}/nof/libfrtbegin.a
914 %{_libdir}/nof/libg2c.la
915 %attr(755,root,root) %{_libdir}/nof/libg2c.so
917 %{_libdir}/gcc-lib/%{_target_cpu}*/*/include/g2c.h
918 %{_mandir}/man1/g77.1*
919 %{_mandir}/man1/f77.1*
920 %lang(ja) %{_mandir}/ja/man1/g77.1*
921 %lang(ja) %{_mandir}/ja/man1/f77.1*
924 %defattr(644,root,root,755)
925 %attr(755,root,root) %{_libdir}/libg2c.so.*.*.*
927 %attr(755,root,root) %{_libdir}/nof/libg2c.so.*.*.*
930 %files -n libg2c-static
931 %defattr(644,root,root,755)
934 %{_libdir}/nof/libg2c.a
937 %if %{!?_without_java:1}%{?_without_java:0}
939 %defattr(644,root,root,755)
941 %attr(755,root,root) %{_bindir}/gcj*
942 %attr(755,root,root) %{_bindir}/gij
943 %attr(755,root,root) %{_bindir}/jcf-dump
944 %attr(755,root,root) %{_bindir}/jv-*
945 %attr(755,root,root) %{_bindir}/grepjar
946 %attr(755,root,root) %{_bindir}/%{_target_cpu}*-gcj
947 %attr(755,root,root) %{_libdir}/gcc-lib/%{_target_cpu}*/*/jc1
948 %attr(755,root,root) %{_libdir}/gcc-lib/%{_target_cpu}*/*/jvgenmain
950 %{_mandir}/man1/jcf-*
954 %{_mandir}/man1/grepjar*
957 %defattr(644,root,root,755)
958 %attr(755,root,root) %{_bindir}/rmi*
959 %attr(755,root,root) %{_bindir}/jar
965 %defattr(644,root,root,755)
966 %attr(755,root,root) %{_bindir}/addr2name.awk
967 %attr(755,root,root) %{_libdir}/lib*cj*.so.*
968 %attr(755,root,root) %{_libdir}/lib-org*.so.*
970 %attr(755,root,root) %{_libdir}/nof/lib*cj*.so.*
973 %files -n libgcj-devel
974 %defattr(644,root,root,755)
981 %{_libdir}/gcc-lib/%{_target_cpu}*/*/include/gcj
982 %dir %{_libdir}/security
983 %{_libdir}/security/*
984 %dir %{_datadir}/java
985 %{_datadir}/java/libgcj*.jar
986 %{_libdir}/lib*cj.spec
987 %{_libdir}/lib*cj*.la
988 %attr(755,root,root) %{_libdir}/lib*cj*.so
989 %attr(755,root,root) %{_libdir}/lib-org-*.so
990 %{_libdir}/lib-org-*.la
992 %{_libdir}/nof/lib*cj*.la
993 %attr(755,root,root) %{_libdir}/nof/lib*cj*.so
996 %files -n libgcj-static
997 %defattr(644,root,root,755)
999 %{_libdir}/lib-org-*.a
1001 %{_libdir}/nof/lib*cj*.a
1005 %defattr(644,root,root,755)
1006 %attr(755,root,root) %{_libdir}/libffi-*.so
1008 %files -n libffi-devel
1009 %defattr(644,root,root,755)
1010 %attr(755,root,root) %{_libdir}/libffi.so
1011 %{_libdir}/libffi.la
1014 %files -n libffi-static
1015 %defattr(644,root,root,755)
1019 %if %{!?_without_ada:1}%{?_without_ada:0}
1021 %defattr(644,root,root,755)
1022 %attr(755,root,root) %{_libdir}/gcc-lib/%{_target_cpu}*/*/gnat1
1023 %{_libdir}/gcc-lib/%{_target_cpu}*/*/adainclude
1024 %dir %{_libdir}/gcc-lib/%{_target_cpu}*/*/adalib
1025 %{_libdir}/gcc-lib/%{_target_cpu}*/*/adalib/*.ali
1027 %{_libdir}/gcc-lib/%{_target_cpu}*/*/adalib/libgmem.a
1029 %{_libdir}/gcc-lib/%{_target_cpu}*/*/adalib/Makefile.adalib
1030 %attr(755,root,root) %{_bindir}/gnat*
1032 %attr(755,root,root) %{_libdir}/libgnat*.so
1033 %attr(755,root,root) %{_libdir}/libgnarl*.so
1036 %defattr(644,root,root,755)
1037 %attr(755,root,root) %{_libdir}/libgna*.so.1
1039 %files -n libgnat-static
1040 %defattr(644,root,root,755)
1041 %{_libdir}/gcc-lib/%{_target_cpu}*/*/adalib/libgna*.a
1045 %defattr(644,root,root,755)
1046 %doc gcc/ksi/README gcc/ksi/NEWS gcc/ksi/t/*.{ksi,c,foo}
1048 %attr(755,root,root) %{_libdir}/gcc-lib/%{_target_cpu}*/*/ksi1
1051 %defattr(644,root,root,755)
1052 %attr(755,root,root) %{_slibdir}/cpp
1053 %attr(755,root,root) %{_bindir}/cpp
1054 #%%attr(755,root,root) %{_libdir}/gcc-lib/%{_target_cpu}*/*/cpp0
1055 #%%attr(755,root,root) %{_libdir}/gcc-lib/%{_target_cpu}*/*/tradcpp0
1056 %{_mandir}/man1/cpp.1*
1057 %lang(ja) %{_mandir}/ja/man1/cpp.1*