%prep %setup -c -T -n %{name}-%{version} %setup -q -T -D -n %{name}-%{version} -a0 cd gcc-%{gcc_pkgvers} %{?PATCH0:%patch0 -p1} cd .. %if %build_cxx %setup -q -T -D -n %{name}-%{version} -a1 cd gcc-%{gcc_pkgvers} %{?PATCH1:%patch1 -p1} cd .. %endif %if %build_fortran %setup -q -T -D -n %{name}-%{version} -a2 %{?PATCH2:%patch2 -p0} %endif %if %build_gcj %setup -q -T -D -n %{name}-%{version} -a3 %{?PATCH3:%patch3 -p0} %endif %if %build_gnat %setup -q -T -D -n %{name}-%{version} -a4 %{?PATCH4:%patch4 -p0} %endif %if %build_objc %setup -q -T -D -n %{name}-%{version} -a5 %{?PATCH5:%patch5 -p0} %endif %if %build_go %setup -q -T -D -n %{name}-%{version} -a6 %{?PATCH6:%patch6 -p0} %endif %if %{with gcc_stdint} sed -i -e '/thread_file=.*rtems/,/use_gcc_stdint=wrap/ { s/use_gcc_stdint=wrap/use_gcc_stdint=provide/}' gcc-%{gcc_pkgvers}/gcc/config.gcc %endif %if %build_newlib %setup -q -T -D -n %{name}-%{version} -a50 cd newlib-%{newlib_version} %{?PATCH50:%patch50 -p1} cd .. # Copy the C library into gcc's source tree ln -s ../newlib-%{newlib_version}/newlib gcc-%{gcc_pkgvers} %if %{with gcc_stdint} rm gcc-%{gcc_pkgvers}/newlib/libc/include/stdint.h %endif # Make sure not to be using GPL'ed sources rm -rf gcc-%{gcc_pkgvers}/newlib/libc/sys/linux rm -rf gcc-%{gcc_pkgvers}/newlib/libc/sys/rdos %endif %if 0%{?_build_mpfr} %setup -q -T -D -n %{name}-%{version} -a60 %{?PATCH60:%patch60 -p1} # Build mpfr one-tree style ln -s ../mpfr-%{mpfr_version} gcc-%{gcc_pkgvers}/mpfr %endif %if 0%{?_build_mpc} %setup -q -T -D -n %{name}-%{version} -a61 %{?PATCH61:%patch61 -p1} # Build mpc one-tree style ln -s ../mpc-%{mpc_version} gcc-%{gcc_pkgvers}/mpc %endif %if 0%{?_build_gmp} %setup -q -T -D -n %{name}-%{version} -a62 %{?PATCH62:%patch62 -p1} # Build gmp one-tree style ln -s ../gmp-%{gmp_version} gcc-%{gcc_pkgvers}/gmp %endif %if 0%{?_build_libelf} %setup -q -T -D -n %{name}-%{version} -a63 %{?PATCH63:%patch63 -p1} # Build libelf one-tree style ln -s ../libelf-%{libelf_version} gcc-%{gcc_pkgvers}/libelf %endif @PREP@ # Fix timestamps cd gcc-%{gcc_pkgvers} contrib/gcc_update --touch cd ..