busybox: port userconfig script setup to systemd

Signed-off-by: Stephan Raue <stephan@openelec.tv>
This commit is contained in:
Stephan Raue 2013-08-08 04:00:57 +02:00
parent 85c9783459
commit 6c126347ad
3 changed files with 18 additions and 4 deletions

View File

@ -103,6 +103,10 @@ post_makeinstall_target() {
rm -rf $INSTALL/bin/systemd-machine-id-setup
cp $PKG_DIR/scripts/systemd-machine-id-setup $INSTALL/bin
# copy openelec helper scripts
mkdir -p $INSTALL/lib/systemd/
cp $PKG_DIR/scripts/openelec-userconfig $INSTALL/lib/systemd/
# provide 'halt', 'shutdown', 'reboot' & co.
mkdir -p $INSTALL/sbin
ln -sf /bin/systemctl $INSTALL/sbin/halt
@ -155,4 +159,5 @@ post_install() {
add_group utmp 22
enable_service machine-id.service
enable_service userconfig.service
}

View File

@ -1,3 +1,4 @@
#!/bin/sh
################################################################################
# This file is part of OpenELEC - http://www.openelec.tv
# Copyright (C) 2009-2012 Stephan Raue (stephan@openelec.tv)
@ -17,11 +18,7 @@
# the Free Software Foundation, 51 Franklin Street, Suite 500, Boston, MA 02110, USA.
# http://www.gnu.org/copyleft/gpl.html
################################################################################
#
# copy userconfig and samples
#
# runlevels: openelec, textmode
if [ -d /usr/config ]; then
progress "copy userconfig and samples"

View File

@ -0,0 +1,12 @@
[Unit]
Description=Setup User config dir
DefaultDependencies=no
After=local-fs.target
[Service]
Type=oneshot
ExecStart=/lib/systemd/openelec-userconfig
RemainAfterExit=yes
[Install]
WantedBy=sysinit.target