Ignore:
Timestamp:
Feb 26, 2003, 3:52:36 PM (18 years ago)
Author:
Ralf Corsepius <ralf.corsepius@…>
Children:
09969a8
Parents:
d4e67c5d
Message:

2003-02-26 Ralf Corsepius <corsepiu@…>

  • gcc3newlib/gccnewlib.add: Add %gcc_version, %newlib_version. Apply %gcc_version, %newlib_version.
  • gcc3newlib/target-c++.add: Apply %gcc_version, %newlib_version.
  • gcc3newlib/target-g77.add: Apply %gcc_version, %newlib_version.
  • gcc3newlib/target-gcc.add: Apply %gcc_version, %newlib_version.
  • gcc3newlib/target-gcj.add: Apply %gcc_version, %newlib_version.
  • gcc3newlib/target-gnat.add: Apply %gcc_version, %newlib_version.
  • gcc3newlib/target-objc.add: Apply %gcc_version, %newlib_version.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • scripts/gcc3newlib/gccnewlib.add

    rd4e67c5d r8a1d1e0b  
     1
     2%define gcc_version     @gcc_version@
     3%define newlib_version  @newlib_version@
     4
    15Name:         @target_alias@-gcc-newlib
    26Summary:      gcc and newlib C Library for @target_alias@.
     
    812Packager:       corsepiu@faw.uni-ulm.de and joel@OARcorp.com
    913
    10 Version:        gcc@gcc_version@newlib@newlib_version@
     14Version:        gcc%{gcc_version}newlib%{newlib_version}
    1115# gcc 3.x and gcc 2.9
    12 Source0:      ftp://ftp.gnu.org/pub/gnu/gcc/gcc-@gcc_version@.tar.gz
    13 # Source0:      ftp://ftp.gnu.org/pub/gnu/gcc/gcc-@gcc_version@.tar.bz2
     16Source0:      ftp://ftp.gnu.org/pub/gnu/gcc/gcc-%{gcc_version}.tar.gz
     17# Source0:      ftp://ftp.gnu.org/pub/gnu/gcc/gcc-%{gcc_version}.tar.bz2
    1418# gcc 2.95.x
    15 # Source0:      ftp://ftp.gnu.org/pub/gnu/gcc/gcc-@gcc_version@.tar.bz2
    16 Source1:        ftp://sources.redhat.com/pub/newlib/newlib-@newlib_version@.tar.gz
     19# Source0:      ftp://ftp.gnu.org/pub/gnu/gcc/gcc-%{gcc_version}.tar.bz2
     20Source1:        ftp://sources.redhat.com/pub/newlib/newlib-%{newlib_version}.tar.gz
    1721@PATCH1@
    1822@PATCH3@
     
    3640# those targets wanting to support ada.
    3741
    38 %if "@gcc_version@" >= "3.2"
     42%if "%{gcc_version}" >= "3.2"
    3943# default to building gnat
    4044%define _gnat   %{?gnat:%gnat}%{!?gnat:1}
     
    4751# those targets wanting to support gcj.
    4852
    49 %if "@gcc_version@" >= "3.2"
     53%if "%{gcc_version}" >= "3.2"
    5054# default to building gcj
    5155%define _gcj    %{?gcj:%gcj}%{!?gcj:1}
     
    135139@PATCH4@
    136140
    137   cd gcc-@gcc_version@
    138     sed -e 's/\(version_string = \"[^\"]*\)/\1 (OAR Corporation gcc-@gcc_version@-@gcc_patch_version@\/newlib-@newlib_version@-@newlib_patch_version@ @Release@)/' \
     141  cd gcc-%{gcc_version}
     142    sed -e 's/\(version_string = \"[^\"]*\)/\1 (OAR Corporation gcc-%{gcc_version}-@gcc_patch_version@\/newlib-%{newlib_version}-@newlib_patch_version@-@Release@)/' \
    139143    gcc/version.c > gcc/version.c~
    140144    mv gcc/version.c~  gcc/version.c
     
    145149
    146150  # Copy the C library into gcc's source tree
    147   ln -s ../newlib-@newlib_version@/newlib gcc-@gcc_version@
     151  ln -s ../newlib-%{newlib_version}/newlib gcc-%{gcc_version}
    148152  test -d build || mkdir build
    149153
     
    171175  languages="$languages,ada"
    172176%endif
    173   ../gcc-@gcc_version@/configure \
     177  ../gcc-%{gcc_version}/configure \
    174178    --build=%_build --host=%_host \
    175179    --target=@target_alias@ \
     
    184188  # Somehow, gcc doesn't get syslimits.h right for Cdn-Xs
    185189  test -d gcc/include || mkdir -p gcc/include
    186   cp ../gcc-@gcc_version@/gcc/gsyslimits.h gcc/include/syslimits.h
    187 %endif
    188 
    189 %if %build_gnat
    190   cd ../gcc-@gcc_version@/gcc/ada
     190  cp ../gcc-%{gcc_version}/gcc/gsyslimits.h gcc/include/syslimits.h
     191%endif
     192
     193%if %build_gnat
     194  cd ../gcc-%{gcc_version}/gcc/ada
    191195  touch treeprs.ads [es]info.h nmake.ad[bs]
    192196  cd ../../../build
     
    209213# Let gnatlib building find newlib's headers
    210214  GNATLIBCFLAGS="$GNATLIBCFLAGS -isystem `pwd`/@target_alias@/newlib/targ-include"
    211   GNATLIBCFLAGS="$GNATLIBCFLAGS -isystem `pwd`/../newlib-@newlib_version@/newlib/libc/include"
     215  GNATLIBCFLAGS="$GNATLIBCFLAGS -isystem `pwd`/../newlib-%{newlib_version}/newlib/libc/include"
    212216# Without this xgcc doesn't find the target's binutils.
    213217  GNATLIBCFLAGS="$GNATLIBCFLAGS -B%{_prefix}/@target_alias@/bin/"
     
    223227# Bug in gcc-2.95.1: It doesn't build this installation directory
    224228# If it doesn't find it, gcc doesn't install @target_alias@/bin/gcc
    225 %if "@gcc_version@" < "3.0"
    226   ../gcc-@gcc_version@/mkinstalldirs \
     229%if "%{gcc_version}" < "3.0"
     230  ../gcc-%{gcc_version}/mkinstalldirs \
    227231    $RPM_BUILD_ROOT%{_prefix}/@target_alias@/bin
    228232%endif
     
    249253  rm -f  ${RPM_BUILD_ROOT}%{_prefix}/lib/libiberty.a
    250254
    251 %if "@gcc_version@" < "3.0"
     255%if "%{gcc_version}" < "3.0"
    252256  # Bug in gcc-2.95.x: It bogusly tries to share cpp for all targets.
    253257  # Rename it to target_alias-cpp
     
    273277  f=`gcc/xgcc -Bgcc/ --print-multi-lib | sed -e 's,;.*$,,'`
    274278
    275   TGTDIR="%{_prefix}/lib/gcc-lib/@target_alias@/@gcc_version@"
     279  TGTDIR="%{_prefix}/lib/gcc-lib/@target_alias@/%{gcc_version}"
    276280  for i in $f; do
    277281    case $i in
     
    300304  cp dirs files.g++
    301305
    302   TGTDIR="%{_prefix}/lib/gcc-lib/@target_alias@/@gcc_version@"
     306  TGTDIR="%{_prefix}/lib/gcc-lib/@target_alias@/%{gcc_version}"
    303307  f=`find ${RPM_BUILD_ROOT}${TGTDIR} ! -type d -print | sed -e "s,^$RPM_BUILD_ROOT,,g"`;
    304308  for i in $f; do
Note: See TracChangeset for help on using the changeset viewer.