[b3a8c23b] | 1 | |
---|
[615b6c9] | 2 | %define gcc_pkgvers @GCC_PKGVERS@ |
---|
| 3 | %define gcc_version @GCC_VERS@ |
---|
[027c603] | 4 | %define gcc_rpmvers %{expand:%(echo "@GCC_VERS@" | tr - _ )} |
---|
[b3a8c23b] | 5 | |
---|
| 6 | %if %build_newlib |
---|
[30d0a41] | 7 | %define newlib_pkgvers @NEWLIB_PKGVERS@ |
---|
[403d2176] | 8 | %define newlib_version @NEWLIB_VERS@ |
---|
[fb85f5a] | 9 | %define newlib_release @NEWLIB_RPMREL@ |
---|
[b3a8c23b] | 10 | %define gccnewlib_version gcc%{gcc_version}newlib%{newlib_version} |
---|
| 11 | %endif |
---|
| 12 | |
---|
[f1b2da23] | 13 | %define mpfr_version 2.3.1 |
---|
| 14 | |
---|
[b3a8c23b] | 15 | Name: @rpmprefix@@tool_target@-gcc |
---|
| 16 | Summary: @tool_target@ gcc |
---|
| 17 | |
---|
[4fa25687] | 18 | Group: Development/Tools |
---|
[e94d6430] | 19 | Version: %{gcc_rpmvers} |
---|
[b8a8bfb0] | 20 | Release: @GCC_RPMREL@ |
---|
[b3a8c23b] | 21 | License: GPL |
---|
| 22 | URL: http://gcc.gnu.org |
---|
| 23 | BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) |
---|
| 24 | |
---|
| 25 | %define _use_internal_dependency_generator 0 |
---|
| 26 | |
---|
[ad476d6e] | 27 | BuildRequires: %{_host_rpmprefix}gcc |
---|
| 28 | |
---|
[f1b2da23] | 29 | %if "%{gcc_version}" >= "4.3.0" |
---|
| 30 | BuildRequires: gmp-devel >= 4.1 |
---|
[ad476d6e] | 31 | %if "%{_build}" != "%{_host}" |
---|
| 32 | BuildRequires: %{_host_rpmprefix}gmp-devel |
---|
| 33 | BuildRequires: %{_host_rpmprefix}mpfr-devel |
---|
| 34 | %endif |
---|
[ff1a93b] | 35 | %if 0%{?fedora} >= 8 |
---|
[f1b2da23] | 36 | BuildRequires: mpfr-devel >= 2.3.0 |
---|
| 37 | %endif |
---|
[26c2bea] | 38 | %if "%{?suse}" > "10.3" |
---|
[f1b2da23] | 39 | BuildRequires: mpfr-devel >= 2.3.0 |
---|
| 40 | %endif |
---|
| 41 | # These distros ship an insufficient mpfr |
---|
| 42 | %{?el4:%define _build_mpfr 1} |
---|
[26c2bea] | 43 | %{?suse10_3:%define _build_mpfr 1} |
---|
[f1b2da23] | 44 | %endif |
---|
| 45 | |
---|
[368708b] | 46 | %if "%{_build}" != "%{_host}" |
---|
| 47 | BuildRequires: @rpmprefix@@tool_target@-gcc |
---|
| 48 | %endif |
---|
| 49 | |
---|
[9b039313] | 50 | %if "%{gcc_version}" >= "4.2.0" |
---|
| 51 | BuildRequires: flex bison |
---|
[f8ee67eb] | 52 | %if %build_f95 |
---|
| 53 | BuildRequires: gmp-devel >= 4.1 |
---|
[ff1a93b] | 54 | %if 0%{?fedora} >= 8 |
---|
[f8ee67eb] | 55 | BuildRequires: mpfr-devel >= 2.2.1 |
---|
| 56 | %endif |
---|
[9b039313] | 57 | %endif |
---|
[f8ee67eb] | 58 | %endif |
---|
| 59 | |
---|
[b3a8c23b] | 60 | %if %build_gcj |
---|
| 61 | # Building gcj requires bison and zlib |
---|
| 62 | BuildRequires: bison |
---|
| 63 | %endif |
---|
| 64 | |
---|
| 65 | BuildRequires: texinfo >= 4.2 |
---|
| 66 | BuildRequires: @rpmprefix@@tool_target@-binutils |
---|
| 67 | BuildRequires: @rpmprefix@@tool_target@-sys-root |
---|
[3596fee] | 68 | BuildRequires: @rpmprefix@@tool_target@-w32api-sys-root |
---|
[b3a8c23b] | 69 | |
---|
[4edae5cf] | 70 | %if %build_infos |
---|
[6255333] | 71 | Requires: @rpmprefix@gcc-common |
---|
[4edae5cf] | 72 | %endif |
---|
[b3a8c23b] | 73 | Requires: @rpmprefix@@tool_target@-binutils |
---|
[3596fee] | 74 | Requires: @rpmprefix@@tool_target@-sys-root |
---|
| 75 | Requires: @rpmprefix@@tool_target@-w32api-sys-root |
---|
[e8b0467] | 76 | %if %build_newlib |
---|
[fb85f5a] | 77 | Requires: @rpmprefix@@tool_target@-newlib = %{newlib_version}-%{newlib_release} |
---|
[e8b0467] | 78 | %endif |
---|
[b3a8c23b] | 79 | |
---|
| 80 | %if %build_gcj |
---|
| 81 | BuildRequires: zlib-devel |
---|
| 82 | %endif |
---|
| 83 | %if %build_gnat |
---|
| 84 | # Building gnat requires gnat |
---|
| 85 | # This really isn't available until RedHat 8.0. How to conditionalize this? |
---|
| 86 | BuildRequires: gcc-gnat |
---|
[fb85f5a] | 87 | BuildRequires: @rpmprefix@@tool_target@-newlib < %{newlib_version}-%{newlib_release} |
---|
[b3a8c23b] | 88 | %endif |
---|
| 89 | %if %build_f95 |
---|
| 90 | BuildRequires: gmp-devel |
---|
| 91 | %endif |
---|
| 92 | |
---|
| 93 | %if "%{gcc_version}" >= "3.4" |
---|
| 94 | %define gcclib %{_libdir}/gcc |
---|
| 95 | %define gccexec %{_libexecdir}/gcc |
---|
| 96 | %else |
---|
| 97 | %define gcclib %{_libdir}/gcc-lib |
---|
| 98 | %define gccexec %{_libdir}/gcc-lib |
---|
| 99 | %endif |
---|
| 100 | |
---|
| 101 | @SOURCES@ |
---|
| 102 | |
---|
[f1b2da23] | 103 | %if "%{gcc_version}" >= "4.3.0" |
---|
| 104 | Source60: http://www.mpfr.org/mpfr-current/mpfr-%{mpfr_version}.tar.bz2 |
---|
| 105 | %endif |
---|
| 106 | |
---|
[b3a8c23b] | 107 | %description |
---|
| 108 | Cross gcc for @tool_target@. |
---|
| 109 | |
---|