PKGBUILD 5.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141
  1. # Maintainer (Arch): Sébastien Luttringer
  2. # Contributor (Arch): Tom Gundersen <teg@jklm.no>
  3. # Maintainer: Omar Vega Ramos <ovruni@gnu.org.pe>
  4. # Contributor: Nicolás Reynolds <fauno@kiwwwi.com.ar>
  5. pkgname=filesystem
  6. pkgver=2021.01.19
  7. pkgrel=1
  8. pkgrel+=.parabola1
  9. pkgdesc='Base Parabola GNU/Linux-libre files'
  10. arch=('x86_64')
  11. arch+=('armv7h' 'i686' 'ppc64le')
  12. license=('GPL')
  13. url='https://www.parabola.nu'
  14. depends=('iana-etc')
  15. backup=('etc/crypttab' 'etc/fstab' 'etc/group' 'etc/gshadow' 'etc/host.conf'
  16. 'etc/hosts' 'etc/issue' 'etc/ld.so.conf' 'etc/motd' 'etc/nsswitch.conf'
  17. 'etc/passwd' 'etc/profile' 'etc/resolv.conf' 'etc/securetty'
  18. 'etc/shadow' 'etc/shells')
  19. source=('crypttab' 'env-generator' 'fstab' 'group' 'gshadow' 'host.conf' 'hosts'
  20. 'issue' 'ld.so.conf' 'locale.sh' 'motd' 'nsswitch.conf' 'os-release'
  21. 'passwd' 'profile' 'resolv.conf' 'securetty' 'shadow' 'shells' 'sysctl'
  22. 'sysusers' 'tmpfiles' 'parabola.svg' 'parabola.png'
  23. 'parabola-logo.svg' 'parabola-logo.png')
  24. sha256sums=('e03bede3d258d680548696623d5979c6edf03272e801a813c81ba5a5c64f4f82'
  25. 'ed0cb4f1db4021f8c3b5ce78fdf91d2c0624708f58f36c9cf867f4d93c3bc6da'
  26. 'e54626e74ed8fee4173b62a545ab1c3a3a069e4217a0ee8fc398d9933e9c1696'
  27. '244f0718ee2a9d6862ae59d6c18c1dd1568651eada91a704574fa527fbac2b3a'
  28. '90d879374f77bac47f132164c1e7fc4892e994ff1d1ac376efa0c1c26ea37273'
  29. '4d7b647169063dfedbff5e1e22cee77bd1a4183dbcfd5e802e68939da4bbf733'
  30. 'd9cd8a77d9e0aa5e90d7f4ed74c8745c17b525e720e28e4c44364150003c35f9'
  31. '8b8f24af3454e87b4e316b4978d0de7958a98cc44606aa801d9696d2c21f4385'
  32. 'dad04a370e488aa85fb0a813a5c83cf6fd981ce01883fc59685447b092de84b5'
  33. '8ca2d8eef6fb5143c9ef7e9174ccfef59ac7ad2deee243574cd10c763156cc10'
  34. 'e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855'
  35. '39d2f719f095028fa655c246bc8608cf3b00971cb7d8c3dbae5a6d89b93a6ca7'
  36. '1fb18c22836c5b679d183a504e594f14d2fdbeb7ce97dd3de5a0c88299f3d597'
  37. '5e06477834f51abf42ea4e8dc199632afc6afbfd8c44354685a271e9a48d2c0a'
  38. '5e4088ad8d0853d390fa303f6be8c3f69c33834200cba9e90f7849f1993ca8d0'
  39. '5557d8e601b17a80d1ea7de78a9869be69637cb6a02fbfe334e22fdf64e61d4c'
  40. 'd88be2b45b43605ff31dd83d6a138069b6c2e92bc8989b7b9ab9eba8da5f8c7b'
  41. '6e13705ac4d6f69cdba118c6b70c722346fd3c45224133e6bbfe28aca719563c'
  42. 'c390b31fffc4a2b5d78ae8c89f5317aadef1f71baac09cfb467b675db1406d61'
  43. '89e43a0b7028f52d5c8e7fb961d962c4b4f4e9595880a6157274ddb2c7c0b6b4'
  44. '04dd4cbe5078f5181176ade3a82f333e3f48091b118360d69cc45a3526503818'
  45. '618ac097441c1f2daffc9967e5c3cd18ea8866f776db62d04bf401c53907b1c9'
  46. 'cb8ece3772744ef162d0ff6018e6a7051889c2aba1bf6439ba9e74a64ac46927'
  47. '826c61cb40bb0b31e2071b21e04ad7f8c6aabe2817e681246569ae9dff81cd9b'
  48. 'cb8ece3772744ef162d0ff6018e6a7051889c2aba1bf6439ba9e74a64ac46927'
  49. '826c61cb40bb0b31e2071b21e04ad7f8c6aabe2817e681246569ae9dff81cd9b')
  50. package() {
  51. cd "$pkgdir"
  52. # setup root filesystem
  53. for d in boot dev etc home mnt usr var opt srv/http run; do
  54. install -d -m755 $d
  55. done
  56. install -d -m555 proc
  57. install -d -m555 sys
  58. install -d -m0750 root
  59. install -d -m1777 tmp
  60. # vsftpd won't run with write perms on /srv/ftp
  61. # ftp (uid 14/gid 11)
  62. install -d -m555 -g 11 srv/ftp
  63. # setup /etc and /usr/share/factory/etc
  64. install -d etc/{ld.so.conf.d,skel,profile.d} usr/share/factory/etc
  65. for f in fstab group host.conf hosts issue ld.so.conf motd nsswitch.conf \
  66. passwd resolv.conf securetty shells profile; do
  67. install -m644 "$srcdir"/$f etc/
  68. install -m644 "$srcdir"/$f usr/share/factory/etc/
  69. done
  70. ln -s ../proc/self/mounts etc/mtab
  71. for f in gshadow shadow crypttab; do
  72. install -m600 "$srcdir"/$f etc/
  73. install -m600 "$srcdir"/$f usr/share/factory/etc/
  74. done
  75. touch etc/parabola-release
  76. ln -sv parabola-release etc/arch-release
  77. install -m644 "$srcdir"/locale.sh etc/profile.d/locale.sh
  78. install -Dm644 "$srcdir"/os-release usr/lib/os-release
  79. # setup /var
  80. for d in cache local opt log/old lib/misc empty; do
  81. install -d -m755 var/$d
  82. done
  83. install -d -m1777 var/{tmp,spool/mail}
  84. # allow setgid games (gid 50) to write scores
  85. install -d -m775 -g 50 var/games
  86. ln -s spool/mail var/mail
  87. ln -s ../run var/run
  88. ln -s ../run/lock var/lock
  89. # setup /usr hierarchy
  90. for d in bin include lib share/{misc,pixmaps} src; do
  91. install -d -m755 usr/$d
  92. done
  93. for d in {1..8}; do
  94. install -d -m755 usr/share/man/man$d
  95. done
  96. # add lib symlinks
  97. ln -s usr/lib lib
  98. [[ $CARCH = 'x86_64' ]] && {
  99. ln -s usr/lib lib64
  100. ln -s lib usr/lib64
  101. }
  102. [[ $CARCH = 'powerpc64le' ]] && {
  103. ln -s usr/lib lib64
  104. ln -s lib usr/lib64
  105. }
  106. # add bin symlinks
  107. ln -s usr/bin bin
  108. ln -s usr/bin sbin
  109. ln -s bin usr/sbin
  110. # setup /usr/local hierarchy
  111. for d in bin etc games include lib man sbin share src; do
  112. install -d -m755 usr/local/$d
  113. done
  114. ln -s ../man usr/local/share/man
  115. # setup systemd-sysctl
  116. install -D -m644 "$srcdir"/sysctl usr/lib/sysctl.d/10-arch.conf
  117. # setup systemd-sysusers
  118. install -D -m644 "$srcdir"/sysusers usr/lib/sysusers.d/arch.conf
  119. # setup systemd-tmpfiles
  120. install -D -m644 "$srcdir"/tmpfiles usr/lib/tmpfiles.d/arch.conf
  121. # setup systemd.environment-generator
  122. install -D -m755 "$srcdir"/env-generator usr/lib/systemd/system-environment-generators/10-arch
  123. # add logo
  124. install -D -m644 "$srcdir"/parabola{,-logo}.{svg,png} usr/share/pixmaps
  125. }