Files
tqma6-yocto-mirror/sources/meta-openembedded/meta-oe/recipes-support/openct/openct/openct.init
Siggi (OpenClaw Agent) 16accb6b24 Complete Yocto mirror with license table for TQMa6UL (2038-compliance)
- 264 license table entries with exact download URLs (224/264 resolved)
- Complete sources/ directory with all BitBake recipes
- Build configuration: tqma6ul-multi-mba6ulx, spaetzle (musl)
- Full traceability for Softwarefreigabeantrag
- GCC 13.4.0, Linux 6.6.102, U-Boot 2023.04, musl 1.2.4
- License distribution: GPL-2.0 (24), MIT (23), GPL-2.0+ (18), BSD-3 (16)
2026-03-01 21:14:11 +00:00

90 lines
1.9 KiB
Bash

#!/bin/sh
#
# openct This shell script takes care of starting and stopping OpenCT.
#
# chkconfig: 2345 24 89
# description: OpenCT is a middleware framework for smart card terminals.
#
# processname: ifdhandler
# config: /etc/openct.conf
### BEGIN INIT INFO
# Provides: openct
# Default-Start: 2 3 4 5
# Default-Stop: 0 1 6
# Should-Start: $syslog $network
# Should-Stop: $syslog $network
# Short-Description: Middleware framework for smart card terminals
# Description: This starts/stops the OpenCT middleware framework support
# for smart card terminals.
### END INIT INFO
. /etc/init.d/functions
exec="/usr/sbin/openct-control"
prog=openct
proc=ifdhandler
OPENCT_OPTIONS=
[ -e /etc/sysconfig/$prog ] && . /etc/sysconfig/$prog
lockfile=/var/lock/subsys/$prog
start() {
retval=0
if ! status $proc >/dev/null 2>&1 ; then
action $"Initializing OpenCT smart card terminals: " \
$exec $OPENCT_OPTIONS init
retval=$?
[ $retval -eq 0 ] && touch $lockfile
fi
return $retval
}
stop() {
if status $proc >/dev/null 2>&1 ; then
action $"Stopping OpenCT smart card terminals: " \
$exec $OPENCT_OPTIONS shutdown
fi
retval=$?
if [ $retval -eq 0 ] ; then
rm -f /var/run/openct/status
rm -f $lockfile
fi
return $retval
}
restart() {
stop
start
}
oct_status() {
status $proc
retval=$?
if [ -e /var/run/openct/status ] ; then
$exec $OPENCT_OPTIONS status
[ -e /var/run/openct/status ] && \
echo $"Waiting for reader attach/detach events..."
fi
return $retval
}
case "$1" in
start|stop|restart)
$1
;;
reload|force-reload)
restart
;;
status)
oct_status
;;
try-restart|condrestart)
[ ! -f $lockfile ] || restart
;;
*)
echo $"Usage: $0 {start|stop|status|restart|try-restart|reload|force-reload}"
exit 2
esac