This repo contains software to build linux from scratch and package it into rpm files.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 

71 lines
2.8 KiB

  1. #TARBALL: http://ftp.gnu.org/gnu/gcc/gcc-9.2.0/gcc-9.2.0.tar.xz
  2. #MD5SUM: 3818ad8600447f05349098232c2ddc78;SOURCES/gcc-9.2.0.tar.xz
  3. #-----------------------------------------------------------------------------
  4. Summary: The GCC package contains the GNU compiler collection
  5. Name: gcc
  6. Version: 9.2.0
  7. Release: 1
  8. License: GPLv2
  9. URL: Any
  10. Group: LFS/Base
  11. Source0: http://ftp.gnu.org/gnu/%{name}/%{name}-%{version}/%{name}-%{version}.tar.xz
  12. Provides: libgcc_s.so.1()(64bit) = %{version}
  13. Provides: libgcc_s.so.1(GCC_3.0)(64bit) = %{version}
  14. Provides: libgcc_s.so.1(GCC_3.3)(64bit) = %{version}
  15. Provides: libgcc_s.so.1(GCC_3.4)(64bit) = %{version}
  16. Provides: libgcc_s.so.1(GCC_4.2.0)(64bit) = %{version}
  17. Requires: filesystem
  18. %description
  19. The GCC package contains the GNU compiler collection, which includes the C and C++ compilers.
  20. #-----------------------------------------------------------------------------
  21. %prep
  22. %setup -q -n %{NAME}-%{VERSION}
  23. sed -e '/m64=/s/lib64/lib/' -i.orig gcc/config/i386/t-linux64
  24. sed -e '1161 s|^|//|' -i libsanitizer/sanitizer_common/sanitizer_platform_limits_posix.cc
  25. mkdir build
  26. %build
  27. cd build
  28. SED=sed \
  29. ../configure \
  30. --prefix=%{_prefix} \
  31. --enable-languages=c,c++ \
  32. --disable-multilib \
  33. --disable-bootstrap \
  34. --with-system-zlib
  35. make %{?_smp_mflags}
  36. %install
  37. cd build
  38. make DESTDIR=%{buildroot} install
  39. install -vdm 755 %{buildroot}/lib
  40. ln -sv ..%{_bindir}/cpp %{buildroot}/lib
  41. install -vdm 755 %{buildroot}%{_bindir}
  42. ln -sv gcc %{buildroot}%{_bindir}/cc
  43. install -vdm 755 %{buildroot}%{_libdir}/bfd-plugins
  44. ln -sfv ../../libexec/gcc/$(gcc -dumpmachine)/%{version}/liblto_plugin.so %{buildroot}%{_libdir}/bfd-plugins/
  45. cd -
  46. install -vdm 755 %{buildroot}/usr/share/gdb/auto-load/usr/lib
  47. mv -v %{buildroot}/usr/lib/*gdb.py %{buildroot}/usr/share/gdb/auto-load/usr/lib
  48. #-----------------------------------------------------------------------------
  49. # Copy license/copying file
  50. install -D -m644 COPYING %{buildroot}/usr/share/licenses/%{name}/LICENSE
  51. #-----------------------------------------------------------------------------
  52. # Create file list
  53. rm %{buildroot}%{_infodir}/dir
  54. find %{buildroot} -name '*.la' -delete
  55. find "${RPM_BUILD_ROOT}" -not -type d -print > filelist.list
  56. sed -i "s|^${RPM_BUILD_ROOT}||" filelist.list
  57. sed -i '/man\/man/d' filelist.list
  58. sed -i '/\/usr\/share\/info/d' filelist.list
  59. #-----------------------------------------------------------------------------
  60. %files -f filelist.list
  61. %defattr(-,root,root)
  62. %{_infodir}/*
  63. %{_mandir}/man1/*
  64. %{_mandir}/man7/*
  65. #-----------------------------------------------------------------------------
  66. %changelog
  67. * Sun May 31 2020 Chris Cromer <chris@cromer.cl> 9.2.0-1
  68. * Tue Mar 26 2019 baho-utot <baho-utot@columbus.rr.com> 8.2.0-1
  69. * Tue Jan 09 2018 baho-utot <baho-utot@columbus.rr.com> 7.3.0-1
  70. - Initial build. First version