filesystem libcap-ng

This commit is contained in:
joborun linux 2024-04-07 23:11:37 +03:00
parent de23a92662
commit e909ca5d8f
7 changed files with 429 additions and 113 deletions

View File

@ -6,21 +6,57 @@
#-----------------------------------------| DESCRIPTION |---------------------------------------
pkgname=filesystem
pkgver=2024.01.19
pkgver=2024.04.07
pkgrel=01
pkgdesc='Base joborun Linux filesystem'
groups=( jobbot base )
url='https://pozol.eu'
depends=('iana-etc')
backup=('etc/crypttab' 'etc/fstab' 'etc/group' 'etc/gshadow' 'etc/host.conf'
'etc/hosts' 'etc/issue' 'etc/ld.so.conf' 'etc/nsswitch.conf'
'etc/passwd' 'etc/profile' 'etc/resolv.conf' 'etc/securetty'
'etc/shadow' 'etc/shells' 'etc/subuid' 'etc/subgid')
source=('crypttab' 'fstab' 'group' 'gshadow' 'host.conf' 'hosts'
'issue' 'ld.so.conf' 'locale.sh' 'motd' 'nsswitch.conf' 'os-release'
'passwd' 'profile' 'resolv.conf' 'securetty' 'shadow' 'shells'
'subuid' 'subgid' 'sysusers' 'sysctl' 'tmpfiles' 'modprobe.d.usb-load-ehci-first'
'jobo-release')
backup=(
'etc/crypttab'
'etc/fstab'
'etc/group'
'etc/gshadow'
'etc/host.conf'
'etc/hosts'
'etc/issue'
'etc/ld.so.conf'
'etc/nsswitch.conf'
'etc/passwd'
'etc/profile'
'etc/resolv.conf'
'etc/securetty'
'etc/shadow'
'etc/shells'
'etc/subgid'
'etc/subuid')
source=(
'crypttab'
'fstab'
'group'
'gshadow'
'host.conf'
'hosts'
'issue'
'ld.so.conf'
'locale.sh'
'motd'
'nsswitch.conf'
'os-release'
'passwd'
'profile'
'resolv.conf'
'securetty'
'shadow'
'shells'
'sysctl'
'subuid'
'subgid'
'sysusers'
'tmpfiles'
'modprobe.d.usb-load-ehci-first'
'jobo-release')
# 'env-generator' 'joborun-linux-logo.svg' 'joborun-linux-logo.png'
# 'joborun-linux-logo-text.svg' 'joborun-linux-logo-text-dark.svg')
@ -120,7 +156,7 @@ package() {
arch=(x86_64)
license=('GPL')
license=('GPL-3.0-or-later')
sha256sums=(e03bede3d258d680548696623d5979c6edf03272e801a813c81ba5a5c64f4f82 # crypttab
115d324c8518affc7bec5559579d85f8f5491646b6110ea9567a586a26a76da9 # fstab
@ -140,13 +176,13 @@ sha256sums=(e03bede3d258d680548696623d5979c6edf03272e801a813c81ba5a5c64f4f82 #
d88be2b45b43605ff31dd83d6a138069b6c2e92bc8989b7b9ab9eba8da5f8c7b # securetty
b302b2e8b06d27d078c5ad68655d441e2a07357b925a867dcf6a33f3a5464b3a # shadow
38ea9a181c4bca9e921a5ca2710530c56accf04b483e6b43b72a118e8a3bdbc7 # shells
89e43a0b7028f52d5c8e7fb961d962c4b4f4e9595880a6157274ddb2c7c0b6b4 # sysctl
e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855 # subgid
e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855 # subuid
e7c1a8ca1216879597348a553a7d5ebf0fa0de66179e3bae697935dc86aa3958 # sysusers
89e43a0b7028f52d5c8e7fb961d962c4b4f4e9595880a6157274ddb2c7c0b6b4 # sysctl
d883a15209635206b044e8ac943f44e0ec7ec0a0ef61915163707642da0ac989 # tmpfiles
90fb123aa8c0176bc144322b585bb889181c437542ddbe546af43e11b95be6ab # modprobe.d.usb-load-ehci-first
673953e0ad7fc53247f4feadc2c2d4506396840d1f8796526f48d47333ac7652) # jobo-release
## 620fc5159df5a8af3870b3724e2711b6b2b475f33bbfbd2956b45e3e02f054eb filesystem-2024.01.19-01-x86_64.pkg.tar.lz
## e74e20572dd4b29e05e2f12656b15283f82a228bf7f0c2e05634e79ce0db32cc filesystem-2024.04.07-01-x86_64.pkg.tar.lz

View File

@ -3,23 +3,68 @@
# Contributor: Tom Gundersen <teg@jklm.no>
pkgname=filesystem
pkgver=2024.01.19
pkgver=2024.04.07
pkgrel=1
pkgdesc='Base Arch Linux files'
arch=('any')
license=('GPL-3.0-or-later')
url='https://archlinux.org'
depends=('iana-etc')
backup=('etc/crypttab' 'etc/fstab' 'etc/group' 'etc/gshadow' 'etc/host.conf'
'etc/hosts' 'etc/issue' 'etc/ld.so.conf' 'etc/nsswitch.conf'
'etc/passwd' 'etc/profile' 'etc/resolv.conf' 'etc/securetty'
'etc/shadow' 'etc/shells' 'etc/subuid' 'etc/subgid')
source=('crypttab' 'env-generator' 'fstab' 'group' 'gshadow' 'host.conf' 'hosts'
'issue' 'ld.so.conf' 'locale.sh' 'nsswitch.conf' 'os-release' 'profile'
'passwd' 'resolv.conf' 'securetty' 'shadow' 'shells' 'sysctl' 'sysusers'
'tmpfiles' 'subuid' 'subgid' 'archlinux-logo.svg' 'archlinux-logo.png'
'archlinux-logo-text.svg' 'archlinux-logo-text-dark.svg')
sha256sums=('e03bede3d258d680548696623d5979c6edf03272e801a813c81ba5a5c64f4f82'
backup=(
'etc/crypttab'
'etc/fstab'
'etc/group'
'etc/gshadow'
'etc/host.conf'
'etc/hosts'
'etc/issue'
'etc/ld.so.conf'
'etc/nsswitch.conf'
'etc/passwd'
'etc/profile'
'etc/resolv.conf'
'etc/securetty'
'etc/shadow'
'etc/shells'
'etc/subgid'
'etc/subuid'
)
source=(
'arch-release'
'archlinux-logo.png'
'archlinux-logo.svg'
'archlinux-logo-text.svg'
'archlinux-logo-text-dark.svg'
'crypttab'
'env-generator'
'fstab'
'group'
'gshadow'
'host.conf'
'hosts'
'issue'
'ld.so.conf'
'locale.sh'
'nsswitch.conf'
'os-release'
'passwd'
'profile'
'resolv.conf'
'securetty'
'shadow'
'shells'
'sysctl'
'sysusers'
'tmpfiles'
'subgid'
'subuid'
)
sha256sums=('01ba4719c80b6fe911b091a7c05124b64eeece964e09c058ef8f9805daca546b'
'3f48779141b68a81e07fee710a42025d4f67b16240295aa4cf148a7ba99cab3c'
'3ffe8ea4e98db43a3ec4dcca55fd4009cd8b8d220f0996aef7a5b427fdf65234'
'601069e6e8920309178c397fd8cebe43410827d01899d31777d13212f0dfacf8'
'96e3cc81623c0537a19799f9eefa966fe46ff5f28a9dc7af1187990973baa127'
'e03bede3d258d680548696623d5979c6edf03272e801a813c81ba5a5c64f4f82'
'ed0cb4f1db4021f8c3b5ce78fdf91d2c0624708f58f36c9cf867f4d93c3bc6da'
'e54626e74ed8fee4173b62a545ab1c3a3a069e4217a0ee8fc398d9933e9c1696'
'244f0718ee2a9d6862ae59d6c18c1dd1568651eada91a704574fa527fbac2b3a'
@ -31,106 +76,172 @@ sha256sums=('e03bede3d258d680548696623d5979c6edf03272e801a813c81ba5a5c64f4f82'
'8ca2d8eef6fb5143c9ef7e9174ccfef59ac7ad2deee243574cd10c763156cc10'
'c8ee7a9faf798caab178ec51afae4146f1efd8a716b7acedf28345b6c75f9697'
'71ff7a6e248d9a0718344c957ec709cb6f0b18631682fa404d7cff2af3ff341d'
'8f08231922fe185d3132f9aedded5cd688fb7c482a6f6f272402ded82fa4849a'
'13e2783884783ef46b8345fbcdf7880f0414c0a9c42e2b2fc6a2b048cbc2d86e'
'8f08231922fe185d3132f9aedded5cd688fb7c482a6f6f272402ded82fa4849a'
'5557d8e601b17a80d1ea7de78a9869be69637cb6a02fbfe334e22fdf64e61d4c'
'd88be2b45b43605ff31dd83d6a138069b6c2e92bc8989b7b9ab9eba8da5f8c7b'
'6e13705ac4d6f69cdba118c6b70c722346fd3c45224133e6bbfe28aca719563c'
'ec289c03aa0d150e90e8287f001c8e6552ab9dd54f450bdb5c2d2254e477965b'
'89e43a0b7028f52d5c8e7fb961d962c4b4f4e9595880a6157274ddb2c7c0b6b4'
'1a1f39695826ca8d5e33ac5801c21f17c6e1d0593b281a1e77be099d454d9715'
'30b97e8f5965744138f7a394e04454db6d509fb89e0a9b615bcd9037df3d6f2a'
'5d8e61479f0093852365090e84d8d95b1e7fccfab068274ee25863bde6ff3e07'
'01d1aeb2cb35965074943bb99a4bb646959e0270a81dcd6af9a7b1c092fb3524'
'e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855'
'e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855'
'3ffe8ea4e98db43a3ec4dcca55fd4009cd8b8d220f0996aef7a5b427fdf65234'
'3f48779141b68a81e07fee710a42025d4f67b16240295aa4cf148a7ba99cab3c'
'601069e6e8920309178c397fd8cebe43410827d01899d31777d13212f0dfacf8'
'96e3cc81623c0537a19799f9eefa966fe46ff5f28a9dc7af1187990973baa127')
'e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855')
package() {
cd "$pkgdir"
local group link mode source_file user
declare -A directories
declare -A files
declare -A symlinks
# setup root filesystem
for d in boot dev etc home mnt usr var opt srv/http run; do
install -d -m755 $d
done
install -d -m555 proc
install -d -m555 sys
install -d -m0750 root
install -d -m1777 tmp
# vsftpd won't run with write perms on /srv/ftp
# ftp (uid 14/gid 11)
install -d -m555 -g 11 srv/ftp
# associative array with directories and their assigned mode, user and group
# all paths are relative to the root directory /
directories=(
["boot"]="755:0:0"
["dev"]="755:0:0"
["etc"]="755:0:0"
["etc/ld.so.conf.d"]="755:0:0"
["etc/profile.d"]="755:0:0"
["etc/skel"]="755:0:0"
["home"]="755:0:0"
["mnt"]="755:0:0"
["opt"]="755:0:0"
["proc"]="555:0:0"
["root"]="0750:0:0"
["run"]="755:0:0"
["srv/http"]="755:0:0"
["srv/ftp"]="555:0:11" # vsftpd won't run with write perms on /srv/ftp
["sys"]="555:0:0"
["tmp"]="1777:0:0"
["usr"]="755:0:0"
["usr/bin"]="755:0:0"
["usr/include"]="755:0:0"
["usr/lib"]="755:0:0"
["usr/lib/ld.so.conf.d"]="755:0:0"
["usr/local/bin"]="755:0:0"
["usr/local/etc"]="755:0:0"
["usr/local/games"]="755:0:0"
["usr/local/include"]="755:0:0"
["usr/local/lib"]="755:0:0"
["usr/local/man"]="755:0:0"
["usr/local/sbin"]="755:0:0"
["usr/local/share"]="755:0:0"
["usr/local/src"]="755:0:0"
["usr/share/factory/etc"]="755:0:0"
["usr/share/man/man1"]="755:0:0"
["usr/share/man/man2"]="755:0:0"
["usr/share/man/man3"]="755:0:0"
["usr/share/man/man4"]="755:0:0"
["usr/share/man/man5"]="755:0:0"
["usr/share/man/man6"]="755:0:0"
["usr/share/man/man7"]="755:0:0"
["usr/share/man/man8"]="755:0:0"
["usr/share/misc"]="755:0:0"
["usr/share/pixmaps"]="755:0:0"
["usr/src"]="755:0:0"
["var"]="755:0:0"
["var/cache"]="755:0:0"
["var/empty"]="755:0:0"
["var/games"]="775:0:50" # allow setgid games (gid 50) to write scores
["var/lib/misc"]="755:0:0"
["var/local"]="755:0:0"
["var/log/old"]="755:0:0"
["var/opt"]="755:0:0"
["var/spool/mail"]="1777:0:0"
["var/tmp"]="1777:0:0"
)
# setup /etc and /usr/share/factory/etc
install -d etc/{ld.so.conf.d,skel,profile.d} usr/share/factory/etc
for f in fstab group host.conf hosts issue ld.so.conf nsswitch.conf \
passwd resolv.conf securetty shells profile subuid subgid; do
install -m644 "$srcdir"/$f etc/
install -m644 "$srcdir"/$f usr/share/factory/etc/
done
ln -s ../proc/self/mounts etc/mtab
for f in gshadow shadow crypttab; do
install -m600 "$srcdir"/$f etc/
install -m600 "$srcdir"/$f usr/share/factory/etc/
done
touch etc/arch-release
install -m644 "$srcdir"/locale.sh etc/profile.d/locale.sh
install -Dm644 "$srcdir"/os-release usr/lib/os-release
# setup /var
for d in cache local opt log/old lib/misc empty; do
install -d -m755 var/$d
done
install -d -m1777 var/{tmp,spool/mail}
# allow setgid games (gid 50) to write scores
install -d -m775 -g 50 var/games
ln -s spool/mail var/mail
ln -s ../run var/run
ln -s ../run/lock var/lock
# setup /usr hierarchy
for d in bin include lib share/{misc,pixmaps} src; do
install -d -m755 usr/$d
done
for d in {1..8}; do
install -d -m755 usr/share/man/man$d
done
install -d usr/lib/ld.so.conf.d
# add lib symlinks
ln -s usr/lib lib
# associative array with symlink names and their respective targets
# all paths are relative to the root directory /
symlinks=(
["bin"]="usr/bin"
["etc/mtab"]="../proc/self/mounts"
["lib"]="usr/lib"
["sbin"]="usr/bin"
["usr/local/share/man"]="../man"
["usr/sbin"]="bin"
["var/lock"]="../run/lock"
["var/mail"]="spool/mail"
["var/run"]="../run"
)
[[ $CARCH = 'x86_64' ]] && {
ln -s usr/lib lib64
ln -s lib usr/lib64
symlinks["lib64"]="usr/lib"
symlinks["usr/lib64"]="lib"
}
# add bin symlinks
ln -s usr/bin bin
ln -s usr/bin sbin
ln -s bin usr/sbin
# associative array of target files, their source file, file mode, user and group ownership
files=(
["etc/arch-release"]="arch-release:644:0:0"
["etc/crypttab"]="crypttab:600:0:0"
["etc/fstab"]="fstab:644:0:0"
["etc/group"]="group:644:0:0"
["etc/gshadow"]="gshadow:600:0:0"
["etc/host.conf"]="host.conf:644:0:0"
["etc/hosts"]="hosts:644:0:0"
["etc/issue"]="issue:644:0:0"
["etc/ld.so.conf"]="ld.so.conf:644:0:0"
["etc/nsswitch.conf"]="nsswitch.conf:644:0:0"
["etc/passwd"]="passwd:644:0:0"
["etc/profile"]="profile:644:0:0"
["etc/profile.d/locale.sh"]="locale.sh:644:0:0"
["etc/resolv.conf"]="resolv.conf:644:0:0"
["etc/securetty"]="securetty:644:0:0"
["etc/shells"]="shells:644:0:0"
["etc/shadow"]="shadow:600:0:0"
["etc/subgid"]="subgid:644:0:0"
["etc/subuid"]="subuid:644:0:0"
["usr/lib/os-release"]="os-release:644:0:0"
["usr/lib/sysctl.d/10-arch.conf"]="sysctl:644:0:0"
["usr/lib/sysusers.d/arch.conf"]="sysusers:644:0:0"
["usr/lib/tmpfiles.d/arch.conf"]="tmpfiles:644:0:0"
["usr/lib/systemd/system-environment-generators/10-arch"]="env-generator:755:0:0"
["usr/share/factory/etc/arch-release"]="arch-release:644:0:0"
["usr/share/factory/etc/crypttab"]="crypttab:600:0:0"
["usr/share/factory/etc/fstab"]="fstab:644:0:0"
["usr/share/factory/etc/group"]="group:644:0:0"
["usr/share/factory/etc/gshadow"]="gshadow:600:0:0"
["usr/share/factory/etc/host.conf"]="host.conf:644:0:0"
["usr/share/factory/etc/hosts"]="hosts:644:0:0"
["usr/share/factory/etc/issue"]="issue:644:0:0"
["usr/share/factory/etc/ld.so.conf"]="ld.so.conf:644:0:0"
["usr/share/factory/etc/nsswitch.conf"]="nsswitch.conf:644:0:0"
["usr/share/factory/etc/passwd"]="passwd:644:0:0"
["usr/share/factory/etc/profile"]="profile:644:0:0"
["usr/share/factory/etc/profile.d/locale.sh"]="locale.sh:644:0:0"
["usr/share/factory/etc/resolv.conf"]="resolv.conf:644:0:0"
["usr/share/factory/etc/securetty"]="securetty:644:0:0"
["usr/share/factory/etc/shadow"]="shadow:600:0:0"
["usr/share/factory/etc/shells"]="shells:644:0:0"
["usr/share/factory/etc/subgid"]="subgid:644:0:0"
["usr/share/factory/etc/subuid"]="subuid:644:0:0"
["usr/share/pixmaps/archlinux-logo.png"]="archlinux-logo.png:644:0:0"
["usr/share/pixmaps/archlinux-logo.svg"]="archlinux-logo.svg:644:0:0"
["usr/share/pixmaps/archlinux-logo-text.svg"]="archlinux-logo-text.svg:644:0:0"
["usr/share/pixmaps/archlinux-logo-text-dark.svg"]="archlinux-logo-text-dark.svg:644:0:0"
)
# setup /usr/local hierarchy
for d in bin etc games include lib man sbin share src; do
install -d -m755 usr/local/$d
cd "$pkgdir"
for dir in "${!directories[@]}"; do
mode="$(cut -f 1 -d ':' <<< "${directories[$dir]}")"
user="$(cut -f 2 -d ':' <<< "${directories[$dir]}")"
group="$(cut -f 3 -d ':' <<< "${directories[$dir]}")"
install -vdm "$mode" -o "$user" -g "$group" "$dir"
done
ln -s ../man usr/local/share/man
# setup systemd-sysctl
install -D -m644 "$srcdir"/sysctl usr/lib/sysctl.d/10-arch.conf
for link in "${!symlinks[@]}"; do
ln -sv "${symlinks[$link]}" "$link"
done
# setup systemd-sysusers
install -D -m644 "$srcdir"/sysusers usr/lib/sysusers.d/arch.conf
for target_file in "${!files[@]}"; do
source_file="$(cut -f 1 -d ':' <<< "${files[$target_file]}")"
mode="$(cut -f 2 -d ':' <<< "${files[$target_file]}")"
user="$(cut -f 3 -d ':' <<< "${files[$target_file]}")"
group="$(cut -f 4 -d ':' <<< "${files[$target_file]}")"
# setup systemd-tmpfiles
install -D -m644 "$srcdir"/tmpfiles usr/lib/tmpfiles.d/arch.conf
# setup systemd.environment-generator
install -D -m755 "$srcdir"/env-generator usr/lib/systemd/system-environment-generators/10-arch
# add logo
install -D -m644 "$srcdir"/archlinux-logo{.png,.svg,-text.svg,-text-dark.svg} usr/share/pixmaps
install -vDm "$mode" -o "$user" -g "$group" "$srcdir/$source_file" "$target_file"
done
}
# vim:set ts=2 sw=2 et:

View File

@ -0,0 +1,136 @@
# Maintainer: David Runge <dvzrv@archlinux.org>
# Maintainer: Sébastien Luttringer
# Contributor: Tom Gundersen <teg@jklm.no>
pkgname=filesystem
pkgver=2024.01.19
pkgrel=1
pkgdesc='Base Arch Linux files'
arch=('any')
license=('GPL-3.0-or-later')
url='https://archlinux.org'
depends=('iana-etc')
backup=('etc/crypttab' 'etc/fstab' 'etc/group' 'etc/gshadow' 'etc/host.conf'
'etc/hosts' 'etc/issue' 'etc/ld.so.conf' 'etc/nsswitch.conf'
'etc/passwd' 'etc/profile' 'etc/resolv.conf' 'etc/securetty'
'etc/shadow' 'etc/shells' 'etc/subuid' 'etc/subgid')
source=('crypttab' 'env-generator' 'fstab' 'group' 'gshadow' 'host.conf' 'hosts'
'issue' 'ld.so.conf' 'locale.sh' 'nsswitch.conf' 'os-release' 'profile'
'passwd' 'resolv.conf' 'securetty' 'shadow' 'shells' 'sysctl' 'sysusers'
'tmpfiles' 'subuid' 'subgid' 'archlinux-logo.svg' 'archlinux-logo.png'
'archlinux-logo-text.svg' 'archlinux-logo-text-dark.svg')
sha256sums=('e03bede3d258d680548696623d5979c6edf03272e801a813c81ba5a5c64f4f82'
'ed0cb4f1db4021f8c3b5ce78fdf91d2c0624708f58f36c9cf867f4d93c3bc6da'
'e54626e74ed8fee4173b62a545ab1c3a3a069e4217a0ee8fc398d9933e9c1696'
'244f0718ee2a9d6862ae59d6c18c1dd1568651eada91a704574fa527fbac2b3a'
'90d879374f77bac47f132164c1e7fc4892e994ff1d1ac376efa0c1c26ea37273'
'4d7b647169063dfedbff5e1e22cee77bd1a4183dbcfd5e802e68939da4bbf733'
'd9cd8a77d9e0aa5e90d7f4ed74c8745c17b525e720e28e4c44364150003c35f9'
'c774dbbcaea38ee1c1141d0daf82aa8177bfb26aca896d6f0c4ccdc902f6ac42'
'785c6c3614a27ae6115a27c1ca55bbf333654780997c4ba7e181172b021d1bf3'
'8ca2d8eef6fb5143c9ef7e9174ccfef59ac7ad2deee243574cd10c763156cc10'
'c8ee7a9faf798caab178ec51afae4146f1efd8a716b7acedf28345b6c75f9697'
'71ff7a6e248d9a0718344c957ec709cb6f0b18631682fa404d7cff2af3ff341d'
'8f08231922fe185d3132f9aedded5cd688fb7c482a6f6f272402ded82fa4849a'
'13e2783884783ef46b8345fbcdf7880f0414c0a9c42e2b2fc6a2b048cbc2d86e'
'5557d8e601b17a80d1ea7de78a9869be69637cb6a02fbfe334e22fdf64e61d4c'
'd88be2b45b43605ff31dd83d6a138069b6c2e92bc8989b7b9ab9eba8da5f8c7b'
'6e13705ac4d6f69cdba118c6b70c722346fd3c45224133e6bbfe28aca719563c'
'ec289c03aa0d150e90e8287f001c8e6552ab9dd54f450bdb5c2d2254e477965b'
'89e43a0b7028f52d5c8e7fb961d962c4b4f4e9595880a6157274ddb2c7c0b6b4'
'30b97e8f5965744138f7a394e04454db6d509fb89e0a9b615bcd9037df3d6f2a'
'5d8e61479f0093852365090e84d8d95b1e7fccfab068274ee25863bde6ff3e07'
'e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855'
'e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855'
'3ffe8ea4e98db43a3ec4dcca55fd4009cd8b8d220f0996aef7a5b427fdf65234'
'3f48779141b68a81e07fee710a42025d4f67b16240295aa4cf148a7ba99cab3c'
'601069e6e8920309178c397fd8cebe43410827d01899d31777d13212f0dfacf8'
'96e3cc81623c0537a19799f9eefa966fe46ff5f28a9dc7af1187990973baa127')
package() {
cd "$pkgdir"
# setup root filesystem
for d in boot dev etc home mnt usr var opt srv/http run; do
install -d -m755 $d
done
install -d -m555 proc
install -d -m555 sys
install -d -m0750 root
install -d -m1777 tmp
# vsftpd won't run with write perms on /srv/ftp
# ftp (uid 14/gid 11)
install -d -m555 -g 11 srv/ftp
# setup /etc and /usr/share/factory/etc
install -d etc/{ld.so.conf.d,skel,profile.d} usr/share/factory/etc
for f in fstab group host.conf hosts issue ld.so.conf nsswitch.conf \
passwd resolv.conf securetty shells profile subuid subgid; do
install -m644 "$srcdir"/$f etc/
install -m644 "$srcdir"/$f usr/share/factory/etc/
done
ln -s ../proc/self/mounts etc/mtab
for f in gshadow shadow crypttab; do
install -m600 "$srcdir"/$f etc/
install -m600 "$srcdir"/$f usr/share/factory/etc/
done
touch etc/arch-release
install -m644 "$srcdir"/locale.sh etc/profile.d/locale.sh
install -Dm644 "$srcdir"/os-release usr/lib/os-release
# setup /var
for d in cache local opt log/old lib/misc empty; do
install -d -m755 var/$d
done
install -d -m1777 var/{tmp,spool/mail}
# allow setgid games (gid 50) to write scores
install -d -m775 -g 50 var/games
ln -s spool/mail var/mail
ln -s ../run var/run
ln -s ../run/lock var/lock
# setup /usr hierarchy
for d in bin include lib share/{misc,pixmaps} src; do
install -d -m755 usr/$d
done
for d in {1..8}; do
install -d -m755 usr/share/man/man$d
done
install -d usr/lib/ld.so.conf.d
# add lib symlinks
ln -s usr/lib lib
[[ $CARCH = 'x86_64' ]] && {
ln -s usr/lib lib64
ln -s lib usr/lib64
}
# add bin symlinks
ln -s usr/bin bin
ln -s usr/bin sbin
ln -s bin usr/sbin
# setup /usr/local hierarchy
for d in bin etc games include lib man sbin share src; do
install -d -m755 usr/local/$d
done
ln -s ../man usr/local/share/man
# setup systemd-sysctl
install -D -m644 "$srcdir"/sysctl usr/lib/sysctl.d/10-arch.conf
# setup systemd-sysusers
install -D -m644 "$srcdir"/sysusers usr/lib/sysusers.d/arch.conf
# setup systemd-tmpfiles
install -D -m644 "$srcdir"/tmpfiles usr/lib/tmpfiles.d/arch.conf
# setup systemd.environment-generator
install -D -m755 "$srcdir"/env-generator usr/lib/systemd/system-environment-generators/10-arch
# add logo
install -D -m644 "$srcdir"/archlinux-logo{.png,.svg,-text.svg,-text-dark.svg} usr/share/pixmaps
}
# vim:set ts=2 sw=2 et:

View File

@ -1,3 +1,2 @@

View File

@ -8,13 +8,14 @@
pkgbase=libcap-ng
pkgname=(libcap-ng python-capng)
pkgver=0.8.4
pkgrel=01
pkgrel=02
pkgdesc='A library for Linux that makes using posix capabilities easy'
url='https://people.redhat.com/sgrubb/libcap-ng/'
depends=(glibc)
makedepends=(python swig)
#options=(debug) # uncomment if you want libcap-ng-debug package made
source=(https://github.com/stevegrubb/libcap-ng/archive/v${pkgver}/${pkgname}-${pkgver}.tar.gz)
source=(https://github.com/stevegrubb/libcap-ng/archive/v${pkgver}/${pkgname}-${pkgver}.tar.gz
$pkgname-0.8.4-remove_exception_handler.patch::https://github.com/stevegrubb/libcap-ng/commit/30453b6553948cd05c438f9f509013e3bb84f25b.patch)
_pick() {
local p="$1" f d; shift
@ -27,6 +28,8 @@ _pick() {
}
prepare() {
# backport patch for removed swig functionality: https://github.com/stevegrubb/libcap-ng/issues/48
patch -Np1 -d $pkgbase-$pkgver -i ../$pkgname-0.8.4-remove_exception_handler.patch
cd $pkgbase-$pkgver
# make stupid autotools happy -_-
touch NEWS
@ -72,4 +75,9 @@ arch=(x86_64)
license=(GPL-2.0-or-later LGPL-2.1-or-later)
sha256sums=(5615c76a61039e283a6bd107c4faf345ae5ad4dcd45907defe5e474d8fdb6fd2) # libcap-ng-0.8.4.tar.gz
sha256sums=(5615c76a61039e283a6bd107c4faf345ae5ad4dcd45907defe5e474d8fdb6fd2 # libcap-ng-0.8.4.tar.gz
9893217e21f1dfd817ef1e25b458a1a5e315b370c1808b435598d48b65b9124d) # libcap-ng-0.8.4-remove_exception_handler.patch
## 3b138f66054614ebd7a75f4db883f8e2a2166e06fcd4d4b2b263bd3cc3713547 libcap-ng-0.8.4-02-x86_64.pkg.tar.lz
## 751b952d1c08ee8342cfbf188be0814c0ce5cfa2649f1ef54d904042be3091d1 python-capng-0.8.4-02-x86_64.pkg.tar.lz

View File

@ -9,7 +9,7 @@ pkgname=(
python-capng
)
pkgver=0.8.4
pkgrel=1
pkgrel=3
pkgdesc='A library for Linux that makes using posix capabilities easy'
arch=(x86_64)
url='https://people.redhat.com/sgrubb/libcap-ng/'
@ -22,9 +22,14 @@ makedepends=(
python
swig
)
source=(https://github.com/stevegrubb/libcap-ng/archive/v${pkgver}/${pkgname}-${pkgver}.tar.gz)
sha512sums=('3e640ba4bfa2d5b5d0eb463abca3b2c745b10e929571c0ec32eb068bdc41fd95e19f7131893a22ceebb4d1f1083d3d87d9a32f0808442d594ac5940791152acf')
b2sums=('f4ea9780b87cdd4f9fa85d4ad3960afe654bc8aa6f5aa298ec87b7d90c87dd981f81577e5113ed76d83aa39c959160bf4deee57be9b458a98f8715e6f7b8dd33')
source=(
https://github.com/stevegrubb/libcap-ng/archive/v${pkgver}/${pkgname}-${pkgver}.tar.gz
$pkgname-0.8.4-remove_exception_handler.patch::https://github.com/stevegrubb/libcap-ng/commit/30453b6553948cd05c438f9f509013e3bb84f25b.patch
)
sha512sums=('3e640ba4bfa2d5b5d0eb463abca3b2c745b10e929571c0ec32eb068bdc41fd95e19f7131893a22ceebb4d1f1083d3d87d9a32f0808442d594ac5940791152acf'
'74de0b06ca948d217fba18dece9072684267bc3f60d53f6c3c164af8f57c48d69d5d17df4a35fee98fdc5919146864168249a690153a95dcda97712efb3e1f7a')
b2sums=('f4ea9780b87cdd4f9fa85d4ad3960afe654bc8aa6f5aa298ec87b7d90c87dd981f81577e5113ed76d83aa39c959160bf4deee57be9b458a98f8715e6f7b8dd33'
'd5a2f35354efb9adb9c45a2173a97358de2fa79fcd6ea5af8987f85a743fc3eb4a2f7f20741538c5487087db9b6f5143041ad7a85d6943b2175ec2c20dac7eb7')
_pick() {
local p="$1" f d; shift
@ -37,6 +42,9 @@ _pick() {
}
prepare() {
# backport patch for removed swig functionality: https://github.com/stevegrubb/libcap-ng/issues/48
patch -Np1 -d $pkgbase-$pkgver -i ../$pkgname-0.8.4-remove_exception_handler.patch
cd $pkgbase-$pkgver
# make stupid autotools happy -_-
touch NEWS

View File

@ -0,0 +1,18 @@
diff --git a/bindings/src/capng_swig.i b/bindings/src/capng_swig.i
index fcdaf18..fa85e13 100644
--- a/bindings/src/capng_swig.i
+++ b/bindings/src/capng_swig.i
@@ -30,13 +30,6 @@
%varargs(16, signed capability = 0) capng_updatev;
-%except(python) {
- $action
- if (result < 0) {
- PyErr_SetFromErrno(PyExc_OSError);
- return NULL;
- }
-}
#endif
%define __signed__