source: rtems/contrib/crossrpms/rtems4.11/arm/rtems-4.11-arm-rtems4.11-gcc.spec @ 57e060b5

4.104.115
Last change on this file since 57e060b5 was 57e060b5, checked in by Ralf Corsepius <ralf.corsepius@…>, on May 22, 2010 at 3:32:34 AM

Regenerate.

  • Property mode set to 100644
File size: 23.9 KB
Line 
1#
2# Please send bugfixes or comments to
3#       http://www.rtems.org/bugzilla
4#
5
6%define _prefix                 /opt/rtems-4.11
7%define _exec_prefix            %{_prefix}
8%define _bindir                 %{_exec_prefix}/bin
9%define _sbindir                %{_exec_prefix}/sbin
10%define _libexecdir             %{_exec_prefix}/libexec
11%define _datarootdir            %{_prefix}/share
12%define _datadir                %{_datarootdir}
13%define _sysconfdir             %{_prefix}/etc
14%define _sharedstatedir         %{_prefix}/com
15%define _localstatedir          %{_prefix}/var
16%define _includedir             %{_prefix}/include
17%define _libdir                 %{_exec_prefix}/%{_lib}
18%define _mandir                 %{_datarootdir}/man
19%define _infodir                %{_datarootdir}/info
20%define _localedir              %{_datarootdir}/locale
21
22%ifos cygwin cygwin32 mingw mingw32
23%define _exeext .exe
24%define debug_package           %{nil}
25%define _libdir                 %{_exec_prefix}/lib
26%else
27%define _exeext %{nil}
28%endif
29
30%ifos cygwin cygwin32
31%define optflags -O3 -pipe -march=i486 -funroll-loops
32%endif
33
34%ifos mingw mingw32
35%if %{defined _mingw32_cflags}
36%define optflags %{_mingw32_cflags}
37%else
38%define optflags -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions --param=ssp-buffer-size=4 -mms-bitfields
39%endif
40%endif
41
42%if "%{_build}" != "%{_host}"
43%define _host_rpmprefix %{_host}-
44%else
45%define _host_rpmprefix %{nil}
46%endif
47
48
49%define gcc_pkgvers 4.5.0
50%define gcc_version 4.5.0
51%define gcc_rpmvers %{expand:%(echo "4.5.0" | tr - _ )}
52
53%define newlib_pkgvers          1.18.0
54%define newlib_version          1.18.0
55
56Name:           rtems-4.11-arm-rtems4.11-gcc
57Summary:        arm-rtems4.11 gcc
58
59Group:          Development/Tools
60Version:        %{gcc_rpmvers}
61Release:        12%{?dist}
62License:        GPL
63URL:            http://gcc.gnu.org
64BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
65
66%define _use_internal_dependency_generator 0
67
68BuildRequires:  %{_host_rpmprefix}gcc
69
70# FIXME: Disable lto for now, to avoid dependencies on libelf
71%bcond_with lto
72
73# FIXME: Disable python gdb scripts
74# ATM, no idea how to package them
75%bcond_with pygdb
76
77# FIXME: Disable GCC-plugin
78# Bug in gcc-4.5-20100318, doesn't build them on x86_84 hosts.
79%bcond_with plugin
80
81# versions of libraries, we conditionally bundle if necessary
82%global mpc_version     0.8.1
83%global mpfr_version    2.4.2
84%global gmp_version     4.3.2
85%global libelf_version  0.8.13
86
87# versions of libraries these distros are known to ship
88%if 0%{?fc13}
89%global mpc_provided 0.8.1
90%global mpfr_provided 2.4.2
91%global gmp_provided 4.3.1
92%endif
93
94%if 0%{?fc12}
95%global mpc_provided 0.8
96%global mpfr_provided 2.4.1
97%global gmp_provided 4.3.1
98%endif
99
100%if 0%{?fc11}
101%global mpc_provided %{nil}
102%global mpfr_provided 2.4.1
103%global gmp_provided 4.2.4
104%endif
105
106%if 0%{?el6}
107%global mpc_provided %{nil}
108%global mpfr_provided 2.4.1
109%global gmp_provided 4.3.1
110%endif
111
112%if 0%{?el5}
113%global mpc_provided %{nil}
114%global mpfr_provided %{nil}
115%global gmp_provided 4.1.4
116%endif
117
118%if 0%{?suse11_0}
119%global mpc_provided %{nil}
120%global mpfr_provided 2.3.1
121%global gmp_provided 4.2.2
122%endif
123
124%if 0%{?suse11_1}
125%global mpc_provided %{nil}
126%global mpfr_provided 2.3.2
127%global gmp_provided 4.2.3
128%endif
129
130%if 0%{?suse11_2}
131%global mpc_provided 0.7
132%global mpfr_provided 2.4.1
133%global gmp_provided 4.3.1
134%endif
135
136%if 0%{?cygwin}
137%global mpc_provided 0.8
138%global mpfr_provided 2.4.1
139%global gmp_provided 4.3.1
140%endif
141
142%if 0%{?mingw32}
143%global mpc_provided 0.8.1
144%global mpfr_provided 2.4.1
145%global gmp_provided 4.3.2
146%endif
147
148%if "%{gcc_version}" >= "4.2.0"
149%endif
150
151%if "%{gcc_version}" >= "4.3.0"
152%define gmp_required            4.1
153%define mpfr_required           2.3.1
154%endif
155
156%if "%{gcc_version}" >= "4.3.3"
157%define cloog_required          0.15
158%endif
159
160%if "%{gcc_version}" >= "4.4.0"
161%define mpfr_required           2.3.2
162%endif
163
164%if "%{gcc_version}" >= "4.5.0"
165%define mpc_required            0.8
166%if %{with lto}
167%define libelf_required         0.8.12
168%endif
169%endif
170
171%if %{defined mpc_required}
172%if "%{mpc_provided}" >= "%{mpc_required}"
173%{?fedora:BuildRequires: libmpc-devel >= %{mpc_required}}
174%{?suse:BuildRequires: mpc-devel >= %{mpc_required}}
175%if "%{_build}" != "%{_host}"
176BuildRequires:  %{_host_rpmprefix}mpc-devel >= %{mpc_required}
177%endif
178%else
179%define _build_mpc 1
180%define gmp_required            4.2
181%endif
182%endif
183
184%if %{defined gmp_required}
185%if "%{gmp_provided}" >= "%{gmp_required}"
186BuildRequires: gmp-devel >= %{gmp_required}
187%if "%{_build}" != "%{_host}"
188BuildRequires:  %{_host_rpmprefix}gmp-devel >= %{gmp_required}
189%endif
190%else
191%define _build_gmp 1
192%endif
193%endif
194
195%if %{defined libelf_required}
196%if "%{libelf_provided}" >= "%{libelf_required}"
197BuildRequires: libelf-devel >= %{libelf_required}
198%if "%{_build}" != "%{_host}"
199BuildRequires:  %{_host_rpmprefix}libelf-devel >= %{libelf_required}
200%endif
201%else
202%define _build_libelf 1
203%endif
204%endif
205
206
207%if %{defined cloog_required}
208%{?fc11:BuildRequires: cloog-ppl-devel >= %cloog_required}
209%{?fc12:BuildRequires: cloog-ppl-devel >= %cloog_required}
210%{?fc13:BuildRequires: cloog-ppl-devel >= %cloog_required}
211%{?el6:BuildRequires: cloog-ppl-devel >= %cloog_required}
212%{?suse11_2:BuildRequires: cloog-devel >= %cloog_required, ppl-devel}
213%{?suse11_1:BuildRequires: cloog-devel >= %cloog_required, ppl-devel}
214%endif
215
216
217%if %{defined mpfr_required}
218%if "%{mpfr_provided}" >= "%{mpfr_required}"
219BuildRequires: mpfr-devel >= %{mpfr_required}
220%if "%{_build}" != "%{_host}"
221BuildRequires:  %{_host_rpmprefix}mpfr-devel >= %{mpfr_required}
222%endif
223%else
224%define _build_mpfr 1
225%endif
226%endif
227
228%if "%{_build}" != "%{_host}"
229BuildRequires:  rtems-4.11-arm-rtems4.11-gcc = %{gcc_rpmvers}
230%endif
231
232%if "%{gcc_version}" >= "4.2.0"
233BuildRequires:  flex bison
234%endif
235
236
237BuildRequires:  texinfo >= 4.2
238BuildRequires:  rtems-4.11-arm-rtems4.11-binutils
239
240Requires:       rtems-4.11-gcc-common
241Requires:       rtems-4.11-arm-rtems4.11-binutils
242Requires:       rtems-4.11-arm-rtems4.11-gcc-libgcc = %{gcc_rpmvers}-%{release}
243Requires:       rtems-4.11-arm-rtems4.11-newlib = %{newlib_version}-12%{?dist}
244
245%if "%{gcc_version}" >= "4.5.0"
246BuildRequires:  zlib-devel
247%if "%{_build}" != "%{_host}"
248BuildRequires:  %{_host_rpmprefix}zlib-devel
249%endif
250%else
251%endif
252
253%global _gcclibdir %{_prefix}/lib
254
255%if "%{gcc_version}" == "4.5.0"
256Source0:        ftp://ftp.gnu.org/gnu/gcc/gcc-%{gcc_pkgvers}/gcc-core-%{gcc_pkgvers}.tar.bz2
257Patch0:         ftp://ftp.rtems.org/pub/rtems/SOURCES/4.11/gcc-core-4.5.0-rtems4.11-20100522.diff
258%endif
259%{?_without_sources:NoSource:   0}
260
261%if "%{gcc_version}" == "4.5.0"
262Source1:        ftp://ftp.gnu.org/gnu/gcc/gcc-%{gcc_pkgvers}/gcc-g++-%{gcc_pkgvers}.tar.bz2
263%endif
264%{?_without_sources:NoSource:   1}
265
266%if "%{newlib_version}" == "1.18.0"
267Source50:       ftp://sources.redhat.com/pub/newlib/newlib-%{newlib_pkgvers}.tar.gz
268Patch50:        ftp://ftp.rtems.org/pub/rtems/SOURCES/4.10/newlib-1.18.0-rtems4.11-20100423.diff
269%endif
270%{?_without_sources:NoSource:   50}
271
272%if 0%{?_build_mpfr}
273Source60:    http://www.mpfr.org/mpfr-current/mpfr-%{mpfr_version}.tar.bz2
274%endif
275
276%if 0%{?_build_mpc}
277Source61:    http://www.multiprecision.org/mpc/download/mpc-%{mpc_version}.tar.gz
278%endif
279
280%if 0%{?_build_gmp}
281Source62:    ftp://ftp.gnu.org/gnu/gmp/gmp-%{gmp_version}.tar.bz2
282%endif
283
284%if 0%{?_build_libelf}
285Source63:    http://www.mr511.de/software/libelf-%{libelf_version}.tar.gz
286%endif
287
288%description
289Cross gcc for arm-rtems4.11.
290
291%prep
292%setup -c -T -n %{name}-%{version}
293
294%setup -q -T -D -n %{name}-%{version} -a0
295cd gcc-%{gcc_pkgvers}
296%{?PATCH0:%patch0 -p1}
297cd ..
298
299%setup -q -T -D -n %{name}-%{version} -a1
300cd gcc-%{gcc_pkgvers}
301%{?PATCH1:%patch1 -p1}
302cd ..
303
304
305
306
307
308%setup -q -T -D -n %{name}-%{version} -a50
309cd newlib-%{newlib_version}
310%{?PATCH50:%patch50 -p1}
311cd ..
312  # Copy the C library into gcc's source tree
313  ln -s ../newlib-%{newlib_version}/newlib gcc-%{gcc_pkgvers}
314
315%if 0%{?_build_mpfr}
316%setup -q -T -D -n %{name}-%{version} -a60
317%{?PATCH60:%patch60 -p1}
318  # Build mpfr one-tree style
319  ln -s ../mpfr-%{mpfr_version} gcc-%{gcc_pkgvers}/mpfr
320%endif
321
322%if 0%{?_build_mpc}
323%setup -q -T -D -n %{name}-%{version} -a61
324%{?PATCH61:%patch61 -p1}
325  # Build mpc one-tree style
326  ln -s ../mpc-%{mpc_version} gcc-%{gcc_pkgvers}/mpc
327%endif
328
329%if 0%{?_build_gmp}
330%setup -q -T -D -n %{name}-%{version} -a62
331%{?PATCH62:%patch62 -p1}
332  # Build gmp one-tree style
333  ln -s ../gmp-%{gmp_version} gcc-%{gcc_pkgvers}/gmp
334%endif
335
336%if 0%{?_build_libelf}
337%setup -q -T -D -n %{name}-%{version} -a63
338%{?PATCH63:%patch63 -p1}
339  # Build libelf one-tree style
340  ln -s ../libelf-%{libelf_version} gcc-%{gcc_pkgvers}/libelf
341%endif
342
343echo "RTEMS gcc-%{gcc_version}-12%{?dist}/newlib-%{newlib_version}-12%{?dist}" > gcc-%{gcc_pkgvers}/gcc/DEV-PHASE
344
345
346  # Fix timestamps
347  cd gcc-%{gcc_pkgvers}
348  contrib/gcc_update --touch
349  cd ..
350%build
351  mkdir -p build
352
353  cd build
354
355  languages="c"
356  languages="$languages,c++"
357  export PATH="%{_bindir}:${PATH}"
358%if "%{_build}" != "%{_host}"
359  CFLAGS_FOR_BUILD="-g -O2 -Wall" \
360  CC="%{_host}-gcc ${RPM_OPT_FLAGS}" \
361%else
362# gcc is not ready to be compiled with -std=gnu99
363  CC=$(echo "%{__cc} ${RPM_OPT_FLAGS}" | sed -e 's,-std=gnu99 ,,') \
364%endif
365  ../gcc-%{gcc_pkgvers}/configure \
366    --prefix=%{_prefix} \
367    --bindir=%{_bindir} \
368    --exec_prefix=%{_exec_prefix} \
369    --includedir=%{_includedir} \
370    --libdir=%{_gcclibdir} \
371    --libexecdir=%{_libexecdir} \
372    --mandir=%{_mandir} \
373    --infodir=%{_infodir} \
374    --datadir=%{_datadir} \
375    --build=%_build --host=%_host \
376    --target=arm-rtems4.11 \
377    --disable-libstdcxx-pch \
378    --with-gnu-as --with-gnu-ld --verbose \
379    --with-newlib \
380    --with-system-zlib \
381    --disable-nls --without-included-gettext \
382    --disable-win32-registry \
383    --enable-version-specific-runtime-libs \
384    --enable-threads \
385    %{?with_lto:--enable-lto}%{!?with_lto:--disable-lto} \
386    %{?with_plugin:--enable-plugin}%{!?with_plugin:--disable-plugin} \
387    --enable-newlib-io-c99-formats \
388    --enable-languages="$languages" $optargs
389
390%if "%_host" != "%_build"
391  # Bug in gcc-3.2.1:
392  # Somehow, gcc doesn't get syslimits.h right for Cdn-Xs
393  mkdir -p gcc/include
394  cp ../gcc-%{gcc_pkgvers}/gcc/gsyslimits.h gcc/include/syslimits.h
395%endif
396
397  make %{?_smp_mflags} all
398  make info
399  cd ..
400
401%install
402  export PATH="%{_bindir}:${PATH}"
403  rm -rf $RPM_BUILD_ROOT
404
405  cd build
406
407  make DESTDIR=$RPM_BUILD_ROOT install
408  cd ..
409
410  cd build/arm-rtems4.11/newlib
411  make DESTDIR=$RPM_BUILD_ROOT install-info
412  cd ../../..
413
414%if "%{gcc_version}" <= "4.1.2"
415# Misplaced header file
416  if test -f $RPM_BUILD_ROOT%{_includedir}/mf-runtime.h; then
417    mv $RPM_BUILD_ROOT%{_includedir}/mf-runtime.h \
418      $RPM_BUILD_ROOT%{_gcclibdir}/gcc/arm-rtems4.11/%{gcc_version}/include/
419  fi
420%endif
421
422  # host library
423%if "%{gcc_version}" >= "4.2.0"
424  # libiberty doesn't honor --libdir, but always installs to a
425  # magically guessed _libdir
426  rm -f  ${RPM_BUILD_ROOT}%{_libdir}/libiberty.a
427%else
428  # libiberty installs to --libdir=...
429  rm -f ${RPM_BUILD_ROOT}%{_gcclibdir}/libiberty.a
430%endif
431
432  # We use the version from binutils
433  rm -f $RPM_BUILD_ROOT%{_bindir}/arm-rtems4.11-c++filt%{_exeext}
434
435
436  # We don't ship info/dir
437  rm -f $RPM_BUILD_ROOT%{_infodir}/dir
438  touch $RPM_BUILD_ROOT%{_infodir}/dir
439
440  # Bug in gcc-3.4.0pre
441  rm -f $RPM_BUILD_ROOT%{_bindir}/arm-rtems4.11-arm-rtems4.11-gcjh%{_exeext}
442
443  # Bug in gcc-3.3.x/gcc-3.4.x: Despite we don't need fixincludes, it installs
444  # the fixinclude-install-tools
445  rm -rf ${RPM_BUILD_ROOT}%{_gcclibdir}/gcc/arm-rtems4.11/%{gcc_version}/install-tools
446  rm -rf ${RPM_BUILD_ROOT}%{_libexecdir}/gcc/arm-rtems4.11/%{gcc_version}/install-tools
447
448  # Bug in gcc > 4.1.0: Installs an unused, empty directory
449  if test -d ${RPM_BUILD_ROOT}%{_prefix}/arm-rtems4.11/include/bits; then
450    rmdir ${RPM_BUILD_ROOT}%{_prefix}/arm-rtems4.11/include/bits
451  fi
452
453  # gcc >= 4.5.0: installs weird libstdc++ python bindings.
454%if ! %{with pygdb}
455  if test -d ${RPM_BUILD_ROOT}%{_datadir}/gcc-%{gcc_version}/python; then
456    rm -rf ${RPM_BUILD_ROOT}%{_datadir}/gcc-%{gcc_version}/python/libstdcxx
457  fi
458%endif
459
460  # Collect multilib subdirectories
461  multilibs=`build/gcc/xgcc -Bbuild/gcc/ --print-multi-lib | sed -e 's,;.*$,,'`
462
463  echo "%defattr(-,root,root,-)" > build/files.newlib
464  TGTDIR="%{_exec_prefix}/arm-rtems4.11/lib"
465  for i in $multilibs; do
466    case $i in
467    \.) echo "%dir ${TGTDIR}" >> build/files.newlib
468      ;;
469    *)  echo "%dir ${TGTDIR}/$i" >> build/files.newlib
470      ;;
471    esac
472  done
473
474  rm -f dirs ;
475  echo "%defattr(-,root,root,-)" >> dirs
476  TGTDIR="%{_gcclibdir}/gcc/arm-rtems4.11/%{gcc_version}"
477  for i in $multilibs; do
478    case $i in
479    \.) ;; # ignore, handled elsewhere
480    *)  echo "%dir ${TGTDIR}/$i" >> dirs
481      ;;
482    esac
483  done
484
485  # Collect files to go into different packages
486  cp dirs build/files.gcc
487  cp dirs build/files.gfortran
488  cp dirs build/files.objc
489  cp dirs build/files.gcj
490  cp dirs build/files.g++
491
492  TGTDIR="%{_gcclibdir}/gcc/arm-rtems4.11/%{gcc_version}"
493  f=`find ${RPM_BUILD_ROOT}${TGTDIR} ! -type d -print | sed -e "s,^$RPM_BUILD_ROOT,,g"`;
494  for i in $f; do
495    case $i in
496    *lib*.la) rm ${RPM_BUILD_ROOT}/$i ;; # ignore: gcc produces bogus libtool libs
497    *f771) ;;
498    *f951) ;;
499    *cc1) ;;
500    *cc1obj) ;;
501    *cc1plus) ;; # ignore: explicitly put into rpm elsewhere
502    *collect2) ;;
503    *libobjc*) echo "$i" >> build/files.objc ;;
504    *include/objc*) ;;
505    *include/g++*);;
506    *include/c++*);;
507    *include-fixed/*);;
508    *finclude/*);;
509    *adainclude*);;
510    *adalib*);;
511    *gnat1);;
512    *jc1) ;;
513    *jvgenmain) ;;
514    */libgfortran*.*) echo "$i" >> build/files.gfortran ;;
515    %{!?with_pygdb:*/libstdc++*gdb.py*) rm ${RPM_BUILD_ROOT}/$i ;;} # ignore for now
516    %{?with_pygdb:*/libstdc++*gdb.py*) >> build/files.g++ ;;}
517    */libstdc++.*) echo "$i" >> build/files.g++ ;;
518    */libsupc++.*) echo "$i" >> build/files.g++ ;;
519    *) echo "$i" >> build/files.gcc ;;
520    esac
521  done
522
523  TGTDIR="%{_exec_prefix}/arm-rtems4.11/lib"
524  f=`find ${RPM_BUILD_ROOT}${TGTDIR} ! -type d -print | sed -e "s,^$RPM_BUILD_ROOT,,g"`;
525  for i in $f; do
526    case $i in
527    *lib*.la) rm ${RPM_BUILD_ROOT}/$i;; # ignore - gcc produces bogus libtool libs
528    *libiberty.a) rm ${RPM_BUILD_ROOT}/$i ;; # ignore - GPL'ed
529# all other files belong to newlib
530    *) echo "$i" >> build/files.newlib ;;
531    esac
532  done
533# Extract %%__os_install_post into os_install_post~
534cat << \EOF > os_install_post~
535%__os_install_post
536EOF
537
538# Generate customized brp-*scripts
539cat os_install_post~ | while read a x y; do
540case $a in
541# Prevent brp-strip* from trying to handle foreign binaries
542*/brp-strip*)
543  b=$(basename $a)
544  sed -e 's,find $RPM_BUILD_ROOT,find $RPM_BUILD_ROOT%_bindir $RPM_BUILD_ROOT%_libexecdir,' $a > $b
545  chmod a+x $b
546  ;;
547# Fix up brp-compress to handle %%_prefix != /usr
548*/brp-compress*)
549  b=$(basename $a)
550  sed -e 's,\./usr/,.%{_prefix}/,g' < $a > $b
551  chmod a+x $b
552  ;;
553esac
554done
555
556sed -e 's,^[ ]*/usr/lib/rpm.*/brp-strip,./brp-strip,' \
557  -e 's,^[ ]*/usr/lib/rpm.*/brp-compress,./brp-compress,' \
558< os_install_post~ > os_install_post
559%define __os_install_post . ./os_install_post
560
561
562cat << EOF > %{_builddir}/%{name}-%{gcc_rpmvers}/find-provides
563#!/bin/sh
564grep -E -v '^${RPM_BUILD_ROOT}%{_exec_prefix}/arm-rtems4.11/(lib|include|sys-root)' \
565  %{?_gcclibdir:| grep -v '^${RPM_BUILD_ROOT}%{_gcclibdir}/gcc/arm-rtems4.11/'} | %__find_provides
566EOF
567chmod +x %{_builddir}/%{name}-%{gcc_rpmvers}/find-provides
568%define __find_provides %{_builddir}/%{name}-%{gcc_rpmvers}/find-provides
569
570cat << EOF > %{_builddir}/%{name}-%{gcc_rpmvers}/find-requires
571#!/bin/sh
572grep -E -v '^${RPM_BUILD_ROOT}%{_exec_prefix}/arm-rtems4.11/(lib|include|sys-root)' \
573  %{?_gcclibdir:| grep -v '^${RPM_BUILD_ROOT}%{_gcclibdir}/gcc/arm-rtems4.11/'} | %__find_requires
574EOF
575chmod +x %{_builddir}/%{name}-%{gcc_rpmvers}/find-requires
576%define __find_requires %{_builddir}/%{name}-%{gcc_rpmvers}/find-requires
577
578%ifnarch noarch
579# Extract %%__debug_install_post into debug_install_post~
580cat << \EOF > debug_install_post~
581%__debug_install_post
582EOF
583
584# Generate customized debug_install_post script
585cat debug_install_post~ | while read a x y; do
586case $a in
587# Prevent find-debuginfo.sh* from trying to handle foreign binaries
588*/find-debuginfo.sh)
589  b=$(basename $a)
590  sed -e 's,find "$RPM_BUILD_ROOT" !,find "$RPM_BUILD_ROOT"%_bindir "$RPM_BUILD_ROOT"%_libexecdir !,' $a > $b
591  chmod a+x $b
592  ;;
593esac
594done
595
596sed -e 's,^[ ]*/usr/lib/rpm/find-debuginfo.sh,./find-debuginfo.sh,' \
597< debug_install_post~ > debug_install_post
598%define __debug_install_post . ./debug_install_post
599
600%endif
601
602%clean
603  rm -rf $RPM_BUILD_ROOT
604
605# ==============================================================
606# rtems-4.11-arm-rtems4.11-gcc
607# ==============================================================
608# %package -n rtems-4.11-arm-rtems4.11-gcc
609# Summary:        GNU cc compiler for arm-rtems4.11
610# Group:          Development/Tools
611# Version:        %{gcc_rpmvers}
612# Requires:       rtems-4.11-arm-rtems4.11-binutils
613# Requires:       rtems-4.11-arm-rtems4.11-newlib = %{newlib_version}-12%{?dist}
614# License:      GPL
615
616# %if %build_infos
617# Requires:      rtems-4.11-gcc-common
618# %endif
619
620%description -n rtems-4.11-arm-rtems4.11-gcc
621GNU cc compiler for arm-rtems4.11.
622
623# ==============================================================
624# rtems-4.11-arm-rtems4.11-gcc-libgcc
625# ==============================================================
626%package -n rtems-4.11-arm-rtems4.11-gcc-libgcc
627Summary:        libgcc for arm-rtems4.11-gcc
628Group:          Development/Tools
629Version:        %{gcc_rpmvers}
630%{?_with_noarch_subpackages:BuildArch: noarch}
631Requires:       rtems-4.11-arm-rtems4.11-newlib = %{newlib_version}-12%{?dist}
632License:        GPL
633
634%description -n rtems-4.11-arm-rtems4.11-gcc-libgcc
635libgcc arm-rtems4.11-gcc.
636
637
638%files -n rtems-4.11-arm-rtems4.11-gcc
639%defattr(-,root,root)
640%dir %{_prefix}
641
642%dir %{_mandir}
643%dir %{_mandir}/man1
644%{_mandir}/man1/arm-rtems4.11-gcc.1*
645%{_mandir}/man1/arm-rtems4.11-cpp.1*
646%{_mandir}/man1/arm-rtems4.11-gcov.1*
647
648%dir %{_bindir}
649%{_bindir}/arm-rtems4.11-cpp%{_exeext}
650%{_bindir}/arm-rtems4.11-gcc%{_exeext}
651%{_bindir}/arm-rtems4.11-gcc-%{gcc_version}%{_exeext}
652%{_bindir}/arm-rtems4.11-gcov%{_exeext}
653%{_bindir}/arm-rtems4.11-gccbug
654
655%dir %{_libexecdir}
656%dir %{_libexecdir}/gcc
657%dir %{_libexecdir}/gcc/arm-rtems4.11
658%dir %{_libexecdir}/gcc/arm-rtems4.11/%{gcc_version}
659%{_libexecdir}/gcc/arm-rtems4.11/%{gcc_version}/cc1%{_exeext}
660%{_libexecdir}/gcc/arm-rtems4.11/%{gcc_version}/collect2%{_exeext}
661%if "%{gcc_version}" >= "4.5.0"
662%{?with_lto:%{_libexecdir}/gcc/arm-rtems4.11/%{gcc_version}/lto%{_exeext}}
663%{_libexecdir}/gcc/arm-rtems4.11/%{gcc_version}/lto-wrapper%{_exeext}
664%endif
665
666%files -n rtems-4.11-arm-rtems4.11-gcc-libgcc -f build/files.gcc
667%defattr(-,root,root)
668%dir %{_prefix}
669%dir %{_gcclibdir}
670%dir %{_gcclibdir}/gcc
671%dir %{_gcclibdir}/gcc/arm-rtems4.11
672%dir %{_gcclibdir}/gcc/arm-rtems4.11/%{gcc_version}
673%dir %{_gcclibdir}/gcc/arm-rtems4.11/%{gcc_version}/include
674
675%if "%{gcc_version}" > "4.0.3"
676%dir %{_gcclibdir}/gcc/arm-rtems4.11/%{gcc_version}/include/ssp
677%endif
678
679%if "%{gcc_version}" >= "4.3.0"
680%{_gcclibdir}/gcc/arm-rtems4.11/%{gcc_version}/include-fixed
681%endif
682
683# ==============================================================
684# rtems-4.11-gcc-common
685# ==============================================================
686%package -n rtems-4.11-gcc-common
687Summary:        Base package for rtems gcc and newlib C Library
688Group:          Development/Tools
689Version:        %{gcc_rpmvers}
690%{?_with_noarch_subpackages:BuildArch: noarch}
691License:        GPL
692
693Requires(post):         /sbin/install-info
694Requires(preun):        /sbin/install-info
695
696%description -n rtems-4.11-gcc-common
697GCC files that are shared by all targets.
698
699%files -n rtems-4.11-gcc-common
700%defattr(-,root,root)
701%dir %{_prefix}
702%dir %{_prefix}/share
703
704%dir %{_infodir}
705%ghost %{_infodir}/dir
706%{_infodir}/cpp.info*
707%{_infodir}/cppinternals.info*
708%{_infodir}/gcc.info*
709%{_infodir}/gccint.info*
710%{_infodir}/gccinstall.info*
711
712%dir %{_mandir}
713%dir %{_mandir}/man7
714%{_mandir}/man7/fsf-funding.7*
715%{_mandir}/man7/gfdl.7*
716%{_mandir}/man7/gpl.7*
717
718%post -n rtems-4.11-gcc-common
719  /sbin/install-info --info-dir=%{_infodir} %{_infodir}/cpp.info.gz || :
720  /sbin/install-info --info-dir=%{_infodir} %{_infodir}/cppinternals.info.gz || :
721  /sbin/install-info --info-dir=%{_infodir} %{_infodir}/gcc.info.gz || :
722  /sbin/install-info --info-dir=%{_infodir} %{_infodir}/gccint.info.gz || :
723  /sbin/install-info --info-dir=%{_infodir} %{_infodir}/gccinstall.info.gz || :
724
725%preun -n rtems-4.11-gcc-common
726if [ $1 -eq 0 ]; then
727  /sbin/install-info --delete --info-dir=%{_infodir} %{_infodir}/cpp.info.gz || :
728  /sbin/install-info --delete --info-dir=%{_infodir} %{_infodir}/cppinternals.info.gz || :
729  /sbin/install-info --delete --info-dir=%{_infodir} %{_infodir}/gcc.info.gz || :
730  /sbin/install-info --delete --info-dir=%{_infodir} %{_infodir}/gccint.info.gz || :
731  /sbin/install-info --delete --info-dir=%{_infodir} %{_infodir}/gccinstall.info.gz || :
732fi
733
734# ==============================================================
735# rtems-4.11-arm-rtems4.11-gcc-c++
736# ==============================================================
737%package -n rtems-4.11-arm-rtems4.11-gcc-c++
738Summary:        GCC c++ compiler for arm-rtems4.11
739Group:          Development/Tools
740Version:        %{gcc_rpmvers}
741License:        GPL
742Requires:       rtems-4.11-arm-rtems4.11-gcc-libstdc++ = %{gcc_rpmvers}-%{release}
743
744%if "%{_build}" != "%{_host}"
745BuildRequires:  rtems-4.11-arm-rtems4.11-gcc-c++ = %{gcc_rpmvers}
746%endif
747
748Requires:       rtems-4.11-gcc-common
749Requires:       rtems-4.11-arm-rtems4.11-gcc = %{gcc_rpmvers}-%{release}
750
751%description -n rtems-4.11-arm-rtems4.11-gcc-c++
752GCC c++ compiler for arm-rtems4.11.
753
754
755%package -n rtems-4.11-arm-rtems4.11-gcc-libstdc++
756Summary:        libstdc++ for arm-rtems4.11
757Group:          Development/Tools
758Version:        %{gcc_rpmvers}
759%{?_with_noarch_subpackages:BuildArch: noarch}
760License:        GPL
761
762%description -n rtems-4.11-arm-rtems4.11-gcc-libstdc++
763%{summary}
764
765
766%files -n rtems-4.11-arm-rtems4.11-gcc-c++
767%defattr(-,root,root)
768%dir %{_prefix}
769
770%dir %{_mandir}
771%dir %{_mandir}/man1
772%{_mandir}/man1/arm-rtems4.11-g++.1*
773
774%dir %{_bindir}
775%{_bindir}/arm-rtems4.11-c++%{_exeext}
776%{_bindir}/arm-rtems4.11-g++%{_exeext}
777
778%dir %{_libexecdir}
779%dir %{_libexecdir}/gcc
780%dir %{_libexecdir}/gcc/arm-rtems4.11
781%dir %{_libexecdir}/gcc/arm-rtems4.11/%{gcc_version}
782%{_libexecdir}/gcc/arm-rtems4.11/%{gcc_version}/cc1plus%{_exeext}
783
784
785%files -n rtems-4.11-arm-rtems4.11-gcc-libstdc++ -f build/files.g++
786%defattr(-,root,root)
787%dir %{_prefix}
788%dir %{_gcclibdir}
789%dir %{_gcclibdir}/gcc
790%dir %{_gcclibdir}/gcc/arm-rtems4.11
791%dir %{_gcclibdir}/gcc/arm-rtems4.11/%{gcc_version}
792%dir %{_gcclibdir}/gcc/arm-rtems4.11/%{gcc_version}/include
793%{_gcclibdir}/gcc/arm-rtems4.11/%{gcc_version}/include/c++
794
795
796
797# ==============================================================
798# rtems-4.11-arm-rtems4.11-newlib
799# ==============================================================
800%package -n rtems-4.11-arm-rtems4.11-newlib
801Summary:        C Library (newlib) for arm-rtems4.11
802Group:          Development/Tools
803License:        Distributable
804Version:        %{newlib_version}
805Release:        12%{?dist}
806%{?_with_noarch_subpackages:BuildArch: noarch}
807
808Requires:       rtems-4.11-newlib-common
809
810%description -n rtems-4.11-arm-rtems4.11-newlib
811Newlib C Library for arm-rtems4.11.
812
813%files -n rtems-4.11-arm-rtems4.11-newlib -f build/files.newlib
814%defattr(-,root,root)
815%dir %{_exec_prefix}
816%dir %{_exec_prefix}/arm-rtems4.11
817%{_exec_prefix}/arm-rtems4.11/include
818
819# ==============================================================
820# rtems-4.11-newlib-common
821# ==============================================================
822%package -n rtems-4.11-newlib-common
823Summary:        Base package for RTEMS newlib C Library
824Group:          Development/Tools
825Version:        %{newlib_version}
826Release:        12%{?dist}
827%{?_with_noarch_subpackages:BuildArch: noarch}
828License:        Distributable
829
830Requires(post):         /sbin/install-info
831Requires(preun):        /sbin/install-info
832
833%description -n rtems-4.11-newlib-common
834newlib files that are shared by all targets.
835
836%files -n rtems-4.11-newlib-common
837%defattr(-,root,root)
838%dir %{_prefix}
839%dir %{_prefix}/share
840
841%dir %{_infodir}
842%ghost %{_infodir}/dir
843%{_infodir}/libc.info*
844%{_infodir}/libm.info*
845
846%post -n rtems-4.11-newlib-common
847  /sbin/install-info --info-dir=%{_infodir} %{_infodir}/libc.info.gz || :
848  /sbin/install-info --info-dir=%{_infodir} %{_infodir}/libm.info.gz || :
849
850%preun -n rtems-4.11-newlib-common
851if [ $1 -eq 0 ]; then
852  /sbin/install-info --delete --info-dir=%{_infodir} %{_infodir}/libc.info.gz || :
853  /sbin/install-info --delete --info-dir=%{_infodir} %{_infodir}/libm.info.gz || :
854fi
855
Note: See TracBrowser for help on using the repository browser.