base-files: update vkpurge for dracut, move to usr/sbin.
This commit is contained in:
parent
8f2369da55
commit
6b90435a98
2 changed files with 11 additions and 17 deletions
|
@ -23,14 +23,15 @@ _EOF
|
||||||
|
|
||||||
list_kernels()
|
list_kernels()
|
||||||
{
|
{
|
||||||
local k kpkg installed kver kvertmp skip
|
local k kpkg installed kver kvertmp skip _f
|
||||||
|
|
||||||
for k in /var/lib/initramfs-tools/*; do
|
for k in /boot/initramfs-*.img; do
|
||||||
kver=$(basename $k)
|
_f=$(basename $k)
|
||||||
kvertmp=$(basename $k|sed -e 's|-rc|rc|')
|
kver=$(xbps-uhelper getpkgversion ${_f})
|
||||||
|
kvertmp=$(xbps-uhelper getpkgversion ${_f}|sed -e 's|-rc|rc|')
|
||||||
for kpkg in kernel kernel-snapshot; do
|
for kpkg in kernel kernel-snapshot; do
|
||||||
installed=$(xbps-uhelper -r / version $kpkg)
|
installed=$(xbps-uhelper -r / version $kpkg)
|
||||||
if [ "$installed" = "$kvertmp" ]; then
|
if [ "$installed" = "${kvertmp%.img}" ]; then
|
||||||
skip=1
|
skip=1
|
||||||
break
|
break
|
||||||
fi
|
fi
|
||||||
|
@ -39,7 +40,7 @@ list_kernels()
|
||||||
unset skip
|
unset skip
|
||||||
continue
|
continue
|
||||||
fi
|
fi
|
||||||
echo "$kver"
|
echo "${kver%.img}"
|
||||||
done
|
done
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -88,11 +89,6 @@ remove_kernel()
|
||||||
fi
|
fi
|
||||||
# Execute post-remove kernel hooks.
|
# Execute post-remove kernel hooks.
|
||||||
run_hooks post-remove $rmkver
|
run_hooks post-remove $rmkver
|
||||||
|
|
||||||
# Make sure there are no stale files.
|
|
||||||
if [ -f /var/lib/initramfs-tools/${rmkver} ]; then
|
|
||||||
rm -f /var/lib/initramfs-tools/${rmkver}
|
|
||||||
fi
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if [ "$1" = "list" ]; then
|
if [ "$1" = "list" ]; then
|
||||||
|
|
|
@ -1,6 +1,8 @@
|
||||||
# Template file for 'base-files'
|
# Template file for 'base-files'
|
||||||
pkgname=base-files
|
pkgname=base-files
|
||||||
version=0.62
|
version=0.63
|
||||||
|
noarch=yes
|
||||||
|
bootstrap=yes
|
||||||
fulldepends="base-directories xbps-triggers"
|
fulldepends="base-directories xbps-triggers"
|
||||||
short_desc="Void GNU/Linux base system files"
|
short_desc="Void GNU/Linux base system files"
|
||||||
maintainer="Juan RP <xtraeme@gmail.com>"
|
maintainer="Juan RP <xtraeme@gmail.com>"
|
||||||
|
@ -10,9 +12,6 @@ long_desc="
|
||||||
This package installs the base system files that aren't installed by any
|
This package installs the base system files that aren't installed by any
|
||||||
other package and are required on any GNU/Linux system."
|
other package and are required on any GNU/Linux system."
|
||||||
|
|
||||||
noarch=yes
|
|
||||||
bootstrap=yes
|
|
||||||
|
|
||||||
conf_files="
|
conf_files="
|
||||||
/etc/inputrc
|
/etc/inputrc
|
||||||
/etc/profile
|
/etc/profile
|
||||||
|
@ -25,7 +24,6 @@ conf_files="
|
||||||
/etc/skel/.inputrc
|
/etc/skel/.inputrc
|
||||||
/etc/issue"
|
/etc/issue"
|
||||||
|
|
||||||
|
|
||||||
do_install() {
|
do_install() {
|
||||||
# Install misc config files.
|
# Install misc config files.
|
||||||
for f in bash_logout bash_profile bashrc inputrc; do
|
for f in bash_logout bash_profile bashrc inputrc; do
|
||||||
|
@ -49,5 +47,5 @@ do_install() {
|
||||||
install -m644 ${FILESDIR}/licenses/* ${DESTDIR}/usr/share/licenses
|
install -m644 ${FILESDIR}/licenses/* ${DESTDIR}/usr/share/licenses
|
||||||
|
|
||||||
# vkpurge
|
# vkpurge
|
||||||
vinstall ${FILESDIR}/vkpurge 755 sbin vkpurge
|
vinstall ${FILESDIR}/vkpurge 755 usr/sbin vkpurge
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue