#!/bin/sh
OPTS=""
if [ -n "$D" ]; then
    OPTS="--root=$D"
fi
if type systemctl >/dev/null 2>/dev/null; then
    systemctl $OPTS enable enigma2.service
    if [ -z "$D" -a "enable" = "enable" ]; then
        systemctl start enigma2.service
    fi
fi
if [ x"$D" = "x" ]; then
	if [ -x /sbin/ldconfig ]; then /sbin/ldconfig ; fi
fi
