summaryrefslogtreecommitdiffstats
path: root/source/ap/slackpkg/files/core-functions.sh
diff options
context:
space:
mode:
author Patrick J Volkerding <volkerdi@slackware.com>2022-01-17 22:44:42 +0000
committer Eric Hameleers <alien@slackware.com>2022-01-18 08:59:56 +0100
commit387bf82d1caf0cb8c6e4407796b3fabe587be38e (patch)
tree8a135ebf9f79d0872c3dcf6132fb24bf8f18a73b /source/ap/slackpkg/files/core-functions.sh
parent54efc574732f81aa298dd8ea253200222d32f1b2 (diff)
downloadcurrent-387bf82d1caf0cb8c6e4407796b3fabe587be38e.tar.gz
current-387bf82d1caf0cb8c6e4407796b3fabe587be38e.tar.xz
Mon Jan 17 22:44:42 UTC 202220220117224442
Things haven't quite settled down yet with more bugfixes and a couple of safe upgrades, so not today folks. But enjoy Slackware's half-birthday anyway! ;-) ap/slackpkg-15.0.10-noarch-1.txz: Upgraded. Fix mirrors.ucr.ac.cr link address (Emmet Ford) Remove wroc.pl mirrors (Emmet Ford) Remove kddilabs.jp from mirrors (Emmet Ford) Unattended usage improvements (PiterPUNK) Create file to flag if the system needs restart (PiterPUNK) Thanks to Robby Workman. kde/kstars-3.5.7-x86_64-1.txz: Upgraded. kde/kwin-5.23.5-x86_64-2.txz: Rebuilt. [PATCH] Bypass wayland interface blacklisting. Thanks to LuckyCyborg. kde/plasma-workspace-5.23.5-x86_64-3.txz: Rebuilt. [PATCH 1/2] Revert "Drop setupX11 from startplasma-waylandsession." [PATCH 2/2] Revert "Drop X11 root properties for KDE full session." Thanks to LuckyCyborg. l/libical-3.0.13-x86_64-1.txz: Upgraded. n/p11-kit-0.24.1-x86_64-1.txz: Upgraded. n/stunnel-5.62-x86_64-1.txz: Upgraded. x/xterm-370-x86_64-4.txz: Rebuilt. Fixed XTerm-console (previously XTerm.linux.console). Renamed XTerm.upstream.default to XTerm-upstream. Thanks to GazL. xap/fluxbox-1.3.7-x86_64-6.txz: Rebuilt. [PATCH] replace FbRootWindow::depth with maxDepth. Thanks to OldHolborn. xap/geeqie-1.7.1-x86_64-1.txz: Upgraded.
Diffstat (limited to 'source/ap/slackpkg/files/core-functions.sh')
-rw-r--r--source/ap/slackpkg/files/core-functions.sh23
1 files changed, 23 insertions, 0 deletions
diff --git a/source/ap/slackpkg/files/core-functions.sh b/source/ap/slackpkg/files/core-functions.sh
index 463a1905d..56314e990 100644
--- a/source/ap/slackpkg/files/core-functions.sh
+++ b/source/ap/slackpkg/files/core-functions.sh
@@ -1318,6 +1318,28 @@ for slackpkg to work properly.
fi
}
+# Checks if a critical package were upgraded by Slackpkg.
+# The /var/run/needs_restarting file contains the list of upgraded
+# packages.
+#
+# The file only is created if /var/run filesystem type is tmpfs so
+# the reboot will clean it
+function needs_restarting() {
+ if [ "$(stat -f -c %T /var/run/)" = "tmpfs" ]; then
+ find $ROOT/var/log/packages/ -cnewer $TMPDIR/timestamp -type f \( \
+ -name "kernel-generic-[0-9]*" -o \
+ -name "kernel-huge-[0-9]*" -o \
+ -name "openssl-solibs-[0-9]*" -o \
+ -name "openssl-[0-9]*" -o \
+ -name "glibc-[0-9]*" -o \
+ -name "aaa_glibc-solibs-[0-9]*" -o \
+ -name "eudev-[0-9]*" -o \
+ -name "elogind-[0-9]*" -o \
+ -name "dbus-[0-9]*" \) | \
+ awk -F/ '{ print $NF }' >> $ROOT/var/run/needs_restarting
+ fi
+}
+
function remove_pkg() {
local i
@@ -1342,6 +1364,7 @@ function upgrade_pkg() {
for i in $SHOWLIST; do
getpkg $i upgradepkg Upgrading
done
+ needs_restarting
}
function install_pkg() {