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.
 
 
 
 

57 lines
2.2 KiB

  1. #TARBALL: https://www.python.org/ftp/python/2.7.15/Python-2.7.15.tar.xz
  2. #MD5SUM: a80ae3cc478460b922242f43a1b4094d;SOURCES/Python-2.7.15.tar.xz
  3. #-----------------------------------------------------------------------------
  4. Summary: The Python 2 package contains the Python development environment.
  5. Name: python2
  6. Version: 2.7.15
  7. Release: 1
  8. License: Any
  9. URL: Any
  10. Group: LFS/Base
  11. Vendor: Elizabeth
  12. Source0: Python-%{VERSION}.tar.xz
  13. Requires: filesystem
  14. %description
  15. The Python 2 package contains the Python development environment.
  16. This is useful for object-oriented programming, writing scripts,
  17. prototyping large programs or developing entire applications.
  18. #-----------------------------------------------------------------------------
  19. %prep
  20. cd %{_builddir}
  21. %setup -q -n "Python-%{VERSION}"
  22. # %%setup -q -T -D -a 1 -n Python-%{VERSION}
  23. %build
  24. ./configure --prefix=%{_prefix} \
  25. --enable-shared \
  26. --with-system-expat \
  27. --with-system-ffi \
  28. --with-ensurepip=yes \
  29. --enable-unicode=ucs4
  30. make %{?_smp_mflags}
  31. %install
  32. make DESTDIR=%{buildroot} install
  33. chmod -v 755 %{buildroot}/usr/lib/libpython2.7.so.1.0
  34. rm %{buildroot}%{_libdir}/python2.7/cgi.py
  35. rm '%{buildroot}/usr/lib/python2.7/site-packages/setuptools/command/launcher manifest.xml'
  36. rm "%{buildroot}/usr/lib/python2.7/site-packages/setuptools/script (dev).tmpl"
  37. #-----------------------------------------------------------------------------
  38. # Copy license/copying file
  39. install -D -m644 LICENSE %{buildroot}/usr/share/licenses/%{name}/LICENSE
  40. rm %{buildroot}/usr/bin/2to3
  41. #-----------------------------------------------------------------------------
  42. # Create file list
  43. # rm %{buildroot}%{_infodir}/dir
  44. find %{buildroot} -name '*.la' -delete
  45. find "${RPM_BUILD_ROOT}" -not -type d -print > filelist.rpm
  46. sed -i "s|^${RPM_BUILD_ROOT}||" filelist.rpm
  47. sed -i '/man\/man/d' filelist.rpm
  48. sed -i '/\/usr\/share\/info/d' filelist.rpm
  49. #-----------------------------------------------------------------------------
  50. %files -f filelist.rpm
  51. %defattr(-,root,root)
  52. %{_mandir}/man1/*
  53. #-----------------------------------------------------------------------------
  54. %changelog
  55. * Wed Sep 26 2018 baho-utot <baho-utot@columbus.rr.com> python2-2.7.14-1
  56. - Initial build. First version