aboutsummaryrefslogtreecommitdiffstats
path: root/packages/cortexa57-poky-linux/lttng-tools/lttng-tools/latest.pkg_postinst
diff options
context:
space:
mode:
Diffstat (limited to 'packages/cortexa57-poky-linux/lttng-tools/lttng-tools/latest.pkg_postinst')
-rw-r--r--packages/cortexa57-poky-linux/lttng-tools/lttng-tools/latest.pkg_postinst27
1 files changed, 27 insertions, 0 deletions
diff --git a/packages/cortexa57-poky-linux/lttng-tools/lttng-tools/latest.pkg_postinst b/packages/cortexa57-poky-linux/lttng-tools/lttng-tools/latest.pkg_postinst
new file mode 100644
index 000000000000..4c9ed36dedce
--- /dev/null
+++ b/packages/cortexa57-poky-linux/lttng-tools/lttng-tools/latest.pkg_postinst
@@ -0,0 +1,27 @@
+#!/bin/sh
+set -e
+if systemctl >/dev/null 2>/dev/null; then
+ OPTS=""
+
+ if [ -n "$D" ]; then
+ OPTS="--root=$D"
+ fi
+
+ if [ "disable" = "enable" ]; then
+ for service in lttng-sessiond.service; do
+ systemctl ${OPTS} enable "$service"
+ done
+ fi
+
+ if [ -z "$D" ]; then
+ systemctl daemon-reload
+ systemctl preset lttng-sessiond.service
+
+ if [ "disable" = "enable" ]; then
+ systemctl --no-block restart lttng-sessiond.service
+ fi
+ fi
+fi
+if [ x"$D" = "x" ]; then
+ if [ -x /sbin/ldconfig ]; then /sbin/ldconfig ; fi
+fi