27 lines
579 B
Bash
27 lines
579 B
Bash
#!/bin/sh
|
|
set -e
|
|
|
|
# postrm script for legatus-qt6-sv
|
|
|
|
if [ "$1" = "remove" ]; then
|
|
# Update linker cache
|
|
ldconfig
|
|
|
|
# Disable systemd service
|
|
if [ -f "/etc/systemd/system/lts_sv.service" ]; then
|
|
systemctl disable lts_sv.service 2>/dev/null || true
|
|
systemctl stop lts_sv.service 2>/dev/null || true
|
|
fi
|
|
fi
|
|
|
|
if [ "$1" = "purge" ]; then
|
|
# Remove configuration files on purge
|
|
rm -f /etc/lts-cc.conf
|
|
rm -f /etc/ld.so.conf.d/lts_sv.conf
|
|
rm -f /etc/security/limits.d/lts_sv_limits.conf
|
|
|
|
# Update linker cache
|
|
ldconfig
|
|
fi
|
|
|
|
exit 0 |