%define EGCS_VERSION 1.0.3a #%define SOURCEURL ftp://ftp.cygnus.com/pub/egcs/releases/egcs-1.0/egcs-1.0.tar.gz %define SOURCEURL egcs-1.0.3a.tar.gz #%define PREFIX /usr #%define PREFIX /usr/local/egcs %define PREFIX /opt/egcs # The name of the directory underneath /usr/lib/gcc-lib/[target] that # this builds for. # EGCS-1.0.3 %define FULLVER egcs-2.90.29 %define LIBSTDCPPRELEASE 1 Summary: Experimental GNU Compiler System Name: egcs Version: %{EGCS_VERSION} Release: 1a Copyright: GPL Group: Development/Languages Source: %{SOURCEURL} Patch0: egcs-1.0.2-ppc_config.patch Patch1: egcs-1.0.2-ppc_readme.patch Patch2: egcs-1.0.2-ppc_trampoline.patch Patch3: egcs-1.0.2-ppc_mcount.patch Patch4: egcs-1.0.2-ppc_varargs.patch Patch5: egcs-1.0.2-haifa.patch Patch6: egcs-1.0.2-ppc_noupdate.patch BuildRoot: /tmp/egcs-root URL: http://www.cygnus.com/egcs/ Requires: binutils %description A compiler aimed at integrating all the optimizations and features necessary for a high-performance and stable development environment. %package as-gcc Summary: Wrappers which allow EGCS to replace GCC. Group: Development/Languages #Requires: egcs = %{EGCS_VERSION} Requires: egcs %description as-gcc Wrappers which allow EGCS to replace GCC. EGCS is installed in a benign fashion and can operate along side of GCC. These wrappers allow the EGCS suite to completely replace GCC. In order to use them, you should remove all vestiges of GCC before installing since this package overlaps the GCC packages. ## %package as-gcc-old-libstdc++ ## Summary: Wrappers which allow EGCS to replace GCC using libg++-2.7. ## Group: Development/Languages ## #Requires: egcs = %{EGCS_VERSION} ## Requires: egcs, libg++ = 2.7 ## %description as-gcc-old-libstdc++ ## Wrappers which allow EGCS to replace GCC. EGCS is installed in a benign fashion and can operate along side of GCC. These ## wrappers allow the EGCS suite to completely replace GCC. In order to use them, you should remove all vestiges of GCC ## before installing since this package overlaps the GCC packages. ## ** Use these wrappers if you want to keep the old libg++/libstdc++ %package c++ Summary: C++ support for gcc Group: Development/Languages #Requires: egcs = %{EGCS_VERSION} Requires: egcs %description c++ C++ support for gcc %package objc Summary: Objective C support for gcc Group: Development/Languages #Requires: egcs = %{EGCS_VERSION} Requires: egcs %description objc Objective C support for gcc %package g77 Summary: Fortran 77 support for gcc Group: Development/Languages #Requires: egcs = %{EGCS_VERSION} Requires: egcs %description g77 Fortran 77 support for gcc ## #%package -n libstdc++ ## %package libstdc++ ## Summary: GNU c++ library ## Group: Libraries ## Version: 2.8.0 ## #Release: %{LIBSTDCPPRELEASE} ## #%description -n libstdc++ ## %description libstdc++ ## This is the GNU implementation of the standard C++ libraries, along with ## additional GNU tools. This package includes the shared libraries ## necessary to run C++ applications. ## #%package -n libstdc++-devel ## %package libstdc++-devel ## Summary: Header files and libraries for C++ development ## Group: Development/Libraries ## Version: 2.8.0 ## #Requires: egcs-libstdc++ = 2.8.0-%{LIBSTDCPPRELEASE} ## Requires: egcs-libstdc++ ## #%description -n libstdc++-devel ## %description libstdc++-devel ## This is the GNU implementation of the standard C++ libraries. This ## package includes the header files and libraries needed for C++ ## development. %changelog * Sun Jun 21 1998 Keisuke Fujii - Built from EGCS-1.0.3a * Tue Mar 31 1998 Gary Thomas - Add "no update" as default mode. This avoids generating 'stwu' instructions which are potentially slower on the newer CPUs. * Thu Mar 26 1998 Gary Thomas - Add missing "include" links for C++ * Sun Mar 22 1998 Gary Thomas - Rebuilt to use "/opt/egcs" - Move libstdc++ to separate package * Sat Mar 14 1998 Gary Thomas - Update to CVS repository on 3/12/98 (even if the version says 3/2/98) - Still trying to fix problems with 'varargs' functions. * Tue Mar 3 1998 Gary Thomas - Built from EGCS-1.0.2pre tree %prep # Notes: # the nof %setup -q -n egcs-%{EGCS_VERSION} #%patch0 -p1 %patch1 -p1 %patch2 -p1 %patch3 -p1 %patch4 -p1 # This patch supposedly fixes VM explosion from HAIFA scheduling #%patch5 -p1 %patch6 -p1 rm -fr libstdc++ %build %ifarch i386 %define GCCARCH i386 %define GCCDIR %{GCCARCH}-linux %endif %ifarch axp %define GCCARCH alpha %define GCCDIR %{GCCARCH}-linux %endif %ifarch sparc %define GCCARCH sparc %define GCCDIR %{GCCARCH}-linux %endif %ifarch ppc %define GCCARCH ppc %define GCCDIR powerpc-unknown-linux-gnulibc1 %endif %ifarch ppc # I want some different options CFLAGS="$RPM_OPT_FLAGS" ./configure \ --prefix=%{PREFIX} --with-gxx-include-dir=%{PREFIX}/include/g++ \ --enable-shared --enable-haifa %else CFLAGS="$RPM_OPT_FLAGS" ./configure --enable-threads=posix \ --prefix=%{PREFIX} --with-gxx-include-dir=%{PREFIX}/include/g++ \ --enable-shared \ %{GCCDIR} %endif make #bootstrap %install rm -rf $RPM_BUILD_ROOT mkdir -p $RPM_BUILD_ROOT/usr/bin mkdir -p $RPM_BUILD_ROOT%{PREFIX}/info $RPM_BUILD_ROOT/lib make prefix=$RPM_BUILD_ROOT%{PREFIX} \ gxx_include_dir=$RPM_BUILD_ROOT%{PREFIX}/include/g++ install strip $RPM_BUILD_ROOT%{PREFIX}/bin/* gzip -n -9f $RPM_BUILD_ROOT%{PREFIX}/info/*.info* ln -sf gcc $RPM_BUILD_ROOT%{PREFIX}/bin/cc ln -sf cccp.1 $RPM_BUILD_ROOT%{PREFIX}/man/man1/cpp.1 ln -sf ..%{PREFIX}/lib/gcc-lib/%{GCCDIR}/%{FULLVER}/cpp $RPM_BUILD_ROOT/lib/cpp ln -sf ../..%{PREFIX}/bin/cc $RPM_BUILD_ROOT/usr/bin/cc ln -sf ../..%{PREFIX}/bin/gcc $RPM_BUILD_ROOT/usr/bin/gcc ln -sf ../..%{PREFIX}/bin/c++ $RPM_BUILD_ROOT/usr/bin/c++ ln -sf ../..%{PREFIX}/bin/g++ $RPM_BUILD_ROOT/usr/bin/g++ ln -sf ../..%{PREFIX}/bin/f77 $RPM_BUILD_ROOT/usr/bin/f77 ln -sf ../..%{PREFIX}/bin/g77 $RPM_BUILD_ROOT/usr/bin/g77 rm -fr $RPM_BUILD_ROOT%{PREFIX}/include mkdir -p $RPM_BUILD_ROOT%{PREFIX}/include ln -s /usr/include/g++ $RPM_BUILD_ROOT%{PREFIX}/include strip \ $RPM_BUILD_ROOT%{PREFIX}/lib/gcc-lib/%{GCCDIR}/%{FULLVER}/{cc1,cc1obj,cc1plus,cpp,f771,ld} ln -s g77 $RPM_BUILD_ROOT%{PREFIX}/bin/f77 %clean rm -rf $RPM_BUILD_ROOT ## %post as-gcc-old-libstd++ ## rm -fr %{PREFIX}/include ## mkdir -p %{PREFIX}/include ## ln -s /usr/include/g++ %{PREFIX}/include ## %postun as-gcc-old-libstd++ ## rm -fr %{PREFIX}/include ## %post libstdc++ ## if [ `grep -c %{PREFIX}/lib /etc/ld.so.conf` = 0 ]; then ## echo "%{PREFIX}/lib" >>/etc/ld.so.conf ## fi ## /sbin/ldconfig ## %postun libstdc++ ## if [ `grep -c %{PREFIX}/lib /etc/ld.so.conf` != 0 ]; then ## grep -v "%{PREFIX}/lib" /etc/ld.so.conf >/etc/EGCS_ld.so.conf ## mv /etc/EGCS_ld.so.conf /etc/ld.so.conf ## fi ## /sbin/ldconfig %files %doc README* COPYING COPYING.LIB %dir %{PREFIX}/lib/gcc-lib %dir %{PREFIX}/lib/gcc-lib/%{GCCDIR} %dir %{PREFIX}/lib/gcc-lib/%{GCCDIR}/%{FULLVER} %dir %{PREFIX}/lib/gcc-lib/%{GCCDIR}/%{FULLVER}/include %{PREFIX}/bin/%{GCCDIR}-gcc %{PREFIX}/bin/gcc %{PREFIX}/bin/cc %{PREFIX}/bin/gcov %{PREFIX}/bin/protoize %{PREFIX}/bin/unprotoize %{PREFIX}/man/man1/cpp.1 %{PREFIX}/man/man1/cccp.1 %{PREFIX}/man/man1/gcc.1 %{PREFIX}/info/cpp.info*.gz %{PREFIX}/info/gcc.info*.gz %{PREFIX}/lib/gcc-lib/%{GCCDIR}/%{FULLVER}/SYSCALLS.c.X %{PREFIX}/lib/gcc-lib/%{GCCDIR}/%{FULLVER}/cc1 %{PREFIX}/lib/gcc-lib/%{GCCDIR}/%{FULLVER}/cpp %{PREFIX}/lib/gcc-lib/%{GCCDIR}/%{FULLVER}/libgcc.a %{PREFIX}/lib/gcc-lib/%{GCCDIR}/%{FULLVER}/specs %{PREFIX}/lib/gcc-lib/%{GCCDIR}/%{FULLVER}/crtbegin.o %{PREFIX}/lib/gcc-lib/%{GCCDIR}/%{FULLVER}/crtbeginS.o %{PREFIX}/lib/gcc-lib/%{GCCDIR}/%{FULLVER}/crtend.o %{PREFIX}/lib/gcc-lib/%{GCCDIR}/%{FULLVER}/crtendS.o %{PREFIX}/lib/gcc-lib/%{GCCDIR}/%{FULLVER}/ld %ifarch ppc %{PREFIX}/lib/gcc-lib/%{GCCDIR}/%{FULLVER}/nof %{PREFIX}/lib/gcc-lib/%{GCCDIR}/%{FULLVER}/ecrti.o %{PREFIX}/lib/gcc-lib/%{GCCDIR}/%{FULLVER}/ecrtn.o %{PREFIX}/lib/gcc-lib/%{GCCDIR}/%{FULLVER}/scrt0.o %{PREFIX}/lib/gcc-lib/%{GCCDIR}/%{FULLVER}/scrti.o %{PREFIX}/lib/gcc-lib/%{GCCDIR}/%{FULLVER}/scrtn.o %endif %{PREFIX}/lib/gcc-lib/%{GCCDIR}/%{FULLVER}/include/README %{PREFIX}/lib/gcc-lib/%{GCCDIR}/%{FULLVER}/include/float.h %{PREFIX}/lib/gcc-lib/%{GCCDIR}/%{FULLVER}/include/iso646.h %{PREFIX}/lib/gcc-lib/%{GCCDIR}/%{FULLVER}/include/limits.h %{PREFIX}/lib/gcc-lib/%{GCCDIR}/%{FULLVER}/include/proto.h %{PREFIX}/lib/gcc-lib/%{GCCDIR}/%{FULLVER}/include/stdarg.h %{PREFIX}/lib/gcc-lib/%{GCCDIR}/%{FULLVER}/include/stddef.h %{PREFIX}/lib/gcc-lib/%{GCCDIR}/%{FULLVER}/include/syslimits.h %{PREFIX}/lib/gcc-lib/%{GCCDIR}/%{FULLVER}/include/va-*.h %{PREFIX}/lib/gcc-lib/%{GCCDIR}/%{FULLVER}/include/varargs.h %ifarch ppc %{PREFIX}/lib/gcc-lib/%{GCCDIR}/%{FULLVER}/include/%{GCCARCH}-asm.h %endif %files c++ %{PREFIX}/man/man1/g++.1 %{PREFIX}/bin/g++ %{PREFIX}/bin/c++ %{PREFIX}/lib/gcc-lib/%{GCCDIR}/%{FULLVER}/cc1plus %{PREFIX}/lib/gcc-lib/%{GCCDIR}/%{FULLVER}/include/exception %{PREFIX}/lib/gcc-lib/%{GCCDIR}/%{FULLVER}/include/new %{PREFIX}/lib/gcc-lib/%{GCCDIR}/%{FULLVER}/include/typeinfo %{PREFIX}/lib/gcc-lib/%{GCCDIR}/%{FULLVER}/include/new.h %{PREFIX}/include ##%ifarch ppc ##%{PREFIX}/lib/nof ##%endif %files objc %{PREFIX}/lib/gcc-lib/%{GCCDIR}/%{FULLVER}/cc1obj %{PREFIX}/lib/gcc-lib/%{GCCDIR}/%{FULLVER}/libobjc.a %{PREFIX}/lib/gcc-lib/%{GCCDIR}/%{FULLVER}/include/objc %files g77 %{PREFIX}/bin/g77 %{PREFIX}/bin/f77 %{PREFIX}/info/g77.info*.gz %{PREFIX}/lib/gcc-lib/%{GCCDIR}/%{FULLVER}/f771 %{PREFIX}/lib/gcc-lib/%{GCCDIR}/%{FULLVER}/libf2c.a %{PREFIX}/lib/gcc-lib/%{GCCDIR}/%{FULLVER}/include/f2c.h %{PREFIX}/lib/libf2c.a ## #%files -n libstdc++-devel ## %files libstdc++-devel ## %{PREFIX}/include/g++ ## %{PREFIX}/lib/libstdc++.a ## %{PREFIX}/lib/libstdc++.so ## %ifarch ppc ## %{PREFIX}/lib/nof/libstdc++.a ## %{PREFIX}/lib/nof/libstdc++.so ## %endif ## #%files -n libstdc++ ## %files libstdc++ ## %{PREFIX}/lib/libstdc++.so.2.8.0 ## %ifarch ppc ## %{PREFIX}/lib/nof/libstdc++.so.2.8.0 ## %endif %files as-gcc /lib/cpp /usr/bin/cc /usr/bin/gcc /usr/bin/c++ /usr/bin/g++ /usr/bin/f77 /usr/bin/g77 ## %files as-gcc-old-libstdc++ ## /lib/cpp ## /usr/bin/cc ## /usr/bin/gcc ## /usr/bin/c++ ## /usr/bin/g++ ## /usr/bin/f77 ## /usr/bin/g77