dde-dock/debian/postinst
fanpengcheng_cm ca761ec7b8 feat:Lock the application's physical memory
dock锁定到物理内存,不要到swap分区
2020-03-14 21:26:29 +08:00

21 lines
393 B
Bash

#!/bin/sh
set -e
if [ "$1" = configure ]; then
if command -v setcap > /dev/null; then
if setcap cap_ipc_lock+eip /usr/bin/dde-dock;then
chmod u-s /usr/bin/dde-dock
else
echo "Setcap failed, falling back to setuid" >&2
chmod u+s /usr/bin/dde-dock
fi
else
echo "Setcap is not installed, falling back to setuid" >&2
chmod u+s /usr/bin/dde-dock
fi
fi
#DEBHELPER#
exit 0