#!/usr/bin/env bash # This file is part of the OpenADK project. OpenADK is copyrighted # material, please see the LICENCE file in the top-level directory. topdir=$(readlink -nf $(dirname $0)/.. 2>/dev/null || (cd $(dirname $0)/..; pwd -P)) . $topdir/.config rcconf=$topdir/root_${ADK_TARGET_SYSTEM}_${ADK_TARGET_LIBC}/etc/rc.conf for service in $(grep ^ADK_RUNTIME_START_ $topdir/.config |grep -v ADK_RUNTIME_START_SERVICES);do rcname=$(echo $service|sed -e "s#ADK_RUNTIME_START_##") rcname=$(echo $rcname| sed -e "s#=y##") rcname=$(echo $rcname| sed -e "s#^BUSYBOX_##") rcname=$(echo $rcname| tr '[:upper:]' '[:lower:]') if [ $ADK_PKG_XBMCBOX = "y" ];then sed -i -e "s#$rcname=\"NO\"#$rcname=\"DAEMON\"#" $rcconf else sed -i -e "s#$rcname=\"NO\"#$rcname=\"YES\"#" $rcconf fi done