l_template_changes.patch 4.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119
  1. --- template.orig 2020-12-10 20:43:57.421966000 +0600
  2. +++ template 2020-12-10 23:33:36.997493000 +0600
  3. @@ -3,6 +3,12 @@ pkgname=debootstrap
  4. version=1.0.123
  5. +# Liberation: _pureos* variables added for pureos distfiles
  6. +_pureospkgver=1.0.108
  7. +_pureospkgrel=pureos2
  8. revision=2
  9. -build_style=fetch
  10. +# Liberation: We're building from source. So changed fetch into this.
  11. +build_style=gnu-makefile
  12. depends="binutils gnupg gzip tar wget xz"
  13. -short_desc="Bootstrap a basic Debian system"
  14. +# Liberation: Changed according to Parabola to indicate inclusion of Free distros
  15. +# and ommision of Debian
  16. +short_desc="Bootstrap a basic gNewSense and Trisquel system, without Debian support"
  17. maintainer="Leah Neukirchen <leah@vuxu.org>"
  18. @@ -10,6 +16,7 @@ license="MIT"
  19. homepage="http://packages.qa.debian.org/d/debootstrap.html"
  20. -distfiles="${DEBIAN_SITE}/main/d/${pkgname}/${pkgname}_${version}_all.deb
  21. - ${DEBIAN_SITE}/main/d/debian-archive-keyring/debian-archive-keyring_2019.1_all.deb"
  22. -checksum="0ab37218fa9719517fccee68b552545f17a5336bbf5801c6d565213ca1aa014e
  23. - 9cefd8917f3d97a999c136aa87f04a3024408b5bc1de470de7d6dfa5e4bd4361"
  24. +# Liberation: Changed files to build from source
  25. +distfiles="https://github.com/felixonmars/${pkgname}/archive/${version}.tar.gz
  26. + https://repo.puri.sm/pureos/pool/main/d/${pkgname}/${pkgname}_${_pureospkgver}${_pureospkgrel}.tar.gz"
  27. +checksum="ccc6cf2eb5e5481d88e1cebd5430a86ffc686be019f7f4dc66cfbb717b107d56
  28. + c0d8c1d7bf7f612c654c475c7e997711fc0a925ddebc0b8c063d4386a25a9cd5"
  29. @@ -27,9 +34,81 @@ esac
  30. -do_install() {
  31. - bsdtar xOf ${pkgname}_${version}_all.deb data.tar.gz | bsdtar xvzf - -C ${DESTDIR}
  32. - bsdtar xOf debian-archive-keyring_2019.1_all.deb data.tar.xz | bsdtar xvJf - -C ${DESTDIR} ./usr/share/keyrings/debian-archive-keyring.gpg
  33. - mv ${DESTDIR}/usr/sbin ${DESTDIR}/usr/bin
  34. - sed -i 's|export PATH|export PATH="/usr/sbin:/sbin:/usr/bin:/bin"|' ${DESTDIR}/usr/bin/debootstrap
  35. - vlicense ${DESTDIR}/usr/share/doc/debootstrap/copyright LICENSE
  36. - rm ${DESTDIR}/usr/share/doc/debootstrap/copyright
  37. +# Liberation
  38. +# Some commands has been taken and modified from:
  39. +# https://git.parabola.nu/abslibre.git/tree/libre/debootstrap/PKGBUILD
  40. +post_patch() {
  41. + # Invalid argument fix
  42. + sed -i 's/chown/#chown/g' Makefile
  43. +
  44. + # Below is mostly from Parabola project with minor changes...
  45. +
  46. + sed -i 's/sbin/bin/g' Makefile
  47. +
  48. + # gNewSense/Trisquel defaults
  49. + sed -i 's|export PATH|export PATH="/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin"|' debootstrap
  50. +
  51. + # arch-detect.patch from Parabola was omitted
  52. +
  53. + # Remove Debian files
  54. + rm -v debootstrap.8
  55. +
  56. + # Add rebranded man
  57. + install -m644 ${FILESDIR}/debootstrap.8 .
  58. +
  59. + # Remove (non-FSDG compliant) distributions's scripts
  60. + for SCRIPT in scripts/* ; do
  61. + case $SCRIPT in
  62. + scripts/debian-common)
  63. + ;;
  64. + *)
  65. + rm -v $SCRIPT
  66. + ;;
  67. + esac
  68. + done
  69. +
  70. + # Add gNewSense script
  71. + install -m644 ${FILESDIR}/gnewsense scripts
  72. +
  73. + # Add PureOS script
  74. + install -m644 ${XBPS_BUILDDIR}/debootstrap/scripts/amber scripts/pureos
  75. +
  76. + # Add Trisquel script
  77. + install -m644 ${FILESDIR}/trisquel scripts
  78. +
  79. + # Enter to scripts dir
  80. + cd scripts
  81. +
  82. + # Create gNewSense symlinks
  83. + ln -s gnewsense ucclia
  84. + ln -s gnewsense parkes
  85. +
  86. + # Create PureOS symlinks
  87. + ln -s pureos amber
  88. + ln -s pureos green
  89. + ln -s pureos landing
  90. + ln -s pureos purple
  91. +
  92. + # Create Trisquel symlinks
  93. + ln -s trisquel awen
  94. + ln -s trisquel belenos
  95. + ln -s trisquel brigantia
  96. + ln -s trisquel dagda
  97. + ln -s trisquel dwyn
  98. + ln -s trisquel etiona
  99. + ln -s trisquel flidas
  100. + ln -s trisquel robur
  101. + ln -s trisquel slaine
  102. + ln -s trisquel taranis
  103. + ln -s trisquel toutatis
  104. +}
  105. +
  106. +# Liberation: Removed do_install
  107. +
  108. +# Liberation
  109. +# Some commands has been taken and modified from:
  110. +# https://git.parabola.nu/abslibre.git/tree/libre/debootstrap/PKGBUILD
  111. +post_install() {
  112. + install -Dm644 ${FILESDIR}/debootstrap.8 "${DESTDIR}"/usr/share/man/man8/debootstrap.8
  113. +
  114. + # Some commands from previous do_install...
  115. + vlicense debian/copyright LICENSE
  116. echo ${_debarch} >${DESTDIR}/usr/share/debootstrap/arch