# # spec file for package gcc # # Copyright (c) 2011 SUSE LINUX Products GmbH, Nuernberg, Germany. # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed # upon. The license for this file, and modifications and additions to the # file, is the same license as for the pristine package itself (unless the # license for the pristine package is not an Open Source License, in which # case the license is the MIT License). An "Open Source License" is a # license that conforms to the Open Source Definition (Version 1.9) # published by the Open Source Initiative. # Please submit bugfixes or comments via http://bugs.opensuse.org/ # # norootforbuild Name: gcc %define separate_bi32 0 %define separate_bi64 0 %ifarch ppc %define separate_bi64 1 %endif %ifarch x86_64 s390x ppc64 %define separate_bi32 1 %endif Url: http://gcc.gnu.org/ %define gcc_version 45 %define gcc_suffix 4.5 License: GPLv2+ Version: 4.5 Release: 11 Group: Development/Languages/C and C++ Summary: The system GNU C Compiler Provides: c_compiler Obsoletes: gcc-mudflap Requires: cpp gcc%{gcc_version} BuildRoot: %{_tmppath}/%{name}-%{version}-build Source: cpp Source99: README.packaging %description The system GNU C Compiler. Authors: -------- The GCC team. %package -n gcc-32bit License: GPLv2+ Group: Development/Languages/C and C++ Summary: The system GNU C Compiler Requires: gcc%{gcc_version}-32bit Requires: gcc = %{version} %description -n gcc-32bit The system GNU C Compiler. Authors: -------- The GCC team. %package -n gcc-64bit License: GPLv2+ Group: Development/Languages/C and C++ Summary: The system GNU C Compiler Requires: gcc%{gcc_version}-64bit Requires: gcc = %{version} %description -n gcc-64bit The system GNU C Compiler. Authors: -------- The GCC team. %package -n cpp License: GPLv2+ Group: Development/Languages/C and C++ Summary: The system GNU Preprocessor Requires: cpp%{gcc_version} %description -n cpp The system GNU Preprocessor. Authors: -------- The GCC team. %package -n gcc-locale License: GPLv2+ Group: Development/Languages/C and C++ Summary: The system GNU Compiler locale files Requires: gcc%{gcc_version}-locale %description -n gcc-locale The system GNU Compiler locale files. %package -n gcc-info License: GFDLv1.1 Group: Development/Languages/C and C++ Summary: The system GNU Compiler documentation PreReq: %{install_info_prereq} Requires: gcc%{gcc_version}-info %description -n gcc-info The system GNU Compiler documentation. # There is intentionally no postun with install_info_delete as there # is no way to just remove the aliased entries. The content owners # install_info_delete will also remove the aliases though. # install-info does not pick up descriptions from the content. %post -n gcc-info %install_info --info-dir=%{_infodir} --name=cpp --description=\\"The GNU C preprocessor.\\" %{_infodir}/cpp-%{gcc_suffix}.info.gz %install_info --info-dir=%{_infodir} --name=gcc --description=\\"The GNU Compiler Collection.\\" %{_infodir}/gcc-%{gcc_suffix}.info.gz %install_info --info-dir=%{_infodir} --name=g++ --description=\\"The GNU C++ compiler.\\" %{_infodir}/g++-%{gcc_suffix}.info.gz %install_info --info-dir=%{_infodir} --name=gcj --description=\\"Ahead-of-time compiler for the Java language\\" %{_infodir}/gcj-%{gcc_suffix}.info.gz %install_info --info-dir=%{_infodir} --name=gfortran --description=\\"The GNU Fortran compiler.\\" %{_infodir}/gfortran-%{gcc_suffix}.info.gz %package -n gcc-c++ License: LGPLv2.1+ Group: Development/Languages/C and C++ Summary: The system GNU C++ Compiler Provides: c++_compiler Requires: gcc%{gcc_version}-c++ Requires: gcc = %{version} %description -n gcc-c++ The system GNU C++ Compiler. %package -n gcc-c++-32bit License: LGPLv2.1+ Group: Development/Languages/C and C++ Summary: The system GNU C++ Compiler Requires: gcc-c++ = %{version} Requires: gcc-32bit = %{version} Requires: libstdc++%{gcc_version}-devel-32bit %description -n gcc-c++-32bit The system GNU C++ Compiler 32 bit support. %package -n gcc-c++-64bit License: LGPLv2.1+ Group: Development/Languages/C and C++ Summary: The system GNU C++ Compiler Requires: gcc-c++ = %{version} Requires: gcc-64bit = %{version} Requires: libstdc++%{gcc_version}-devel-64bit %description -n gcc-c++-64bit The system GNU C++ Compiler 64 bit support. %package -n libstdc++-devel License: GPLv2+ Group: System/Libraries Summary: The system GNU C++ development files Requires: libstdc++%{gcc_version}-devel %description -n libstdc++-devel The system GNU C++ development files. %package -n gcc-fortran License: GPLv2+ Group: Development/Languages/Fortran Summary: The system GNU Fortran Compiler Requires: gcc%{gcc_version}-fortran Requires: gcc = %{version} %description -n gcc-fortran The system GNU Fortran Compiler. Authors: -------- The GCC team. %package -n gcc-fortran-32bit License: GPLv2+ Group: Development/Languages/Fortran Summary: The system GNU Fortran Compiler Requires: gcc%{gcc_version}-fortran-32bit Requires: gcc-fortran = %{version} %description -n gcc-fortran-32bit The system GNU Fortran Compiler 32 bit support. Authors: -------- The GCC team. %package -n gcc-fortran-64bit License: GPLv2+ Group: Development/Languages/Fortran Summary: The system GNU Fortran Compiler Requires: gcc%{gcc_version}-fortran-64bit Requires: gcc-fortran = %{version} %description -n gcc-fortran-64bit The system GNU Fortran Compiler 64 bit support. Authors: -------- The GCC team. %package -n gcc-java License: GPLv2+ Group: Development/Languages/Java Summary: The system GNU Java Compiler Requires: gcc%{gcc_version}-java Requires: libgcj-devel = %{version} Recommends: gcc-gij = %{version} Requires: gcc = %{version} %description -n gcc-java The system GNU Java Compiler. %package -n libgcj-devel License: GPLv2+ ; LGPLv2.1+ Group: Development/Libraries/Java Summary: The system GNU Java development files. Requires: libgcj%{gcc_version}-devel %description -n libgcj-devel The system GNU Java development files. %package -n gcc-gij License: GPLv2+ Group: Development/Languages/Java Summary: The system GNU Java bytecode interpreter Requires: gcc%{gcc_version}-gij %description -n gcc-gij The system GNU Java bytecode interpreter. %package -n gcc-gij-32bit License: GPLv2+ Group: Development/Languages/Java Summary: The system GNU Java bytecode interpreter Requires: gcc%{gcc_version}-gij-32bit %description -n gcc-gij-32bit The system GNU Java bytecode interpreter as 32 bit application. %package -n gcc-gij-64bit License: GPLv2+ Group: Development/Languages/Java Summary: The system GNU Java bytecode interpreter Requires: gcc%{gcc_version}-gij-64bit %description -n gcc-gij-64bit The system GNU Java bytecode interpreter as 64 bit application. %package -n gcc-objc License: GPLv2+ Group: Development/Languages/Other Summary: The system GNU Objective C Compiler Requires: gcc%{gcc_version}-objc Requires: gcc = %{version} %ifarch ppc64 Obsoletes: gcc-objc-64bit %endif %description -n gcc-objc The system GNU Objective C Compiler. %package -n gcc-objc-32bit License: GPLv2+ Group: Development/Languages/Other Summary: The system GNU Objective C Compiler Requires: gcc%{gcc_version}-objc-32bit Requires: gcc-objc = %{version} %description -n gcc-objc-32bit The system GNU Objective C Compiler 32 bit support. %package -n gcc-objc-64bit License: GPLv2+ Group: Development/Languages/Other Summary: The system GNU Objective C Compiler Requires: gcc%{gcc_version}-objc-64bit Requires: gcc-objc = %{version} %description -n gcc-objc-64bit The system GNU Objective C Compiler 64 bit support. %package -n gcc-obj-c++ License: GPLv2+ Group: Development/Languages/Other Summary: The system GNU Objective C++ Compiler Requires: gcc%{gcc_version}-obj-c++ Requires: gcc-objc = %{version} %description -n gcc-obj-c++ The system GNU Objective C++ Compiler. %package -n gcc-ada License: GPLv2+ Group: Development/Languages/C and C++ Summary: The system GNU Ada Compiler Requires: gcc%{gcc_version}-ada Requires: gcc = %{version} %description -n gcc-ada The system GNU Ada Compiler. Authors: -------- The GCC team. %package -n gcc-z9 License: GPLv2+ Group: Development/Languages/C and C++ Summary: The system GNU C Compiler Requires: gcc %description -n gcc-z9 The system GNU C Compiler. Authors: -------- The GCC team. %prep %build echo "This is a dummy package to provide a dependency on the system compiler." > README %install mkdir -p $RPM_BUILD_ROOT/lib mkdir -p $RPM_BUILD_ROOT%{_prefix}/bin mkdir -p $RPM_BUILD_ROOT%{_mandir}/man1 mkdir -p $RPM_BUILD_ROOT%{_prefix}/share/doc/packages/gcc-objc/ mkdir -p $RPM_BUILD_ROOT%{_prefix}/share/doc/packages/gcc-obj-c++/ # Link all the binaries for program in \ gcc gcov \ g++ \ cpp \ gcj gcjh gcj-dbtool jcf-dump jv-convert gc-analyze \ gij \ gappletviewer \ gjar gjarsigner gjavah gkeytool gnative2ascii gorbd grmic \ grmid grmiregistry gserialver gtnameserv \ %if %{separate_bi32} grmiregistry32 \ gij32 \ %endif %if %{separate_bi64} grmiregistry64 \ gij64 \ %endif gfortran \ gnat gnatbind gnatbl gnatchop gnatclean gnatfind gnatkr \ gnatlink gnatls gnatmake gnatname gnatprep gnatxref gprmake \ ; do ln -sf $program-%{gcc_suffix} $RPM_BUILD_ROOT%{_prefix}/bin/$program done # Link section 1 manpages for man1 in \ gcc gcov \ g++ \ cpp \ gfortran \ gcj gcjh gcj-dbtool jcf-dump jv-convert gc-analyze \ gij \ gappletviewer gjar gjarsigner gjavah \ gkeytool gnative2ascii gorbd grmic grmid grmiregistry gserialver \ gtnameserv \ ; do ln -sf $man1-%{gcc_suffix}.1.gz $RPM_BUILD_ROOT%{_mandir}/man1/$man1.1.gz done # Provide the traditional /lib/cpp that only handles C cp $RPM_SOURCE_DIR/cpp $RPM_BUILD_ROOT/lib/ chmod 755 $RPM_BUILD_ROOT/lib/cpp # Provide extra symlinks ln -sf g++-%{gcc_suffix} $RPM_BUILD_ROOT%{_prefix}/bin/c++ ln -sf gcc-%{gcc_suffix} $RPM_BUILD_ROOT%{_prefix}/bin/cc ln -sf g++-%{gcc_suffix}.1.gz $RPM_BUILD_ROOT%{_mandir}/man1/c++.1.gz ln -sf gcc-%{gcc_suffix}.1.gz $RPM_BUILD_ROOT%{_mandir}/man1/cc.1.gz %ifarch s390 s390x dir=`gcc -print-prog-name=cc1` dir=${dir%/cc1} mkdir -p $RPM_BUILD_ROOT/$dir cat > $RPM_BUILD_ROOT/$dir/defaults.spec <