OK5718 qt程序自启动设置
上电启动显示[OK[ Started helloworld但是我的界面没有启动起来 vi /etc/init.d/matrix-gui-2.0修改为如下内容红色字体为添加内容,即启动指令,此例是启动/home/forlinx/qt/下的keypad紫色字体需要注释掉如下即可完成自启#! /bin/sh matrixgui="/home/forlinx/qt/matrix_browser"GUI_OPTS="http://127.0.0.1:80/"""PIDFILE="/var/run/matrix-gui-2.0.pid" # Important System Environment Variablesfor sh in /etc/profile.d/*.sh ; do [-r "$sh" ] && . "$sh"done/home/forlinx/qt/keypad #itest -x"$matrixgui" || exit 0 #case "$1"in#start) #Clear out the the tmp and lock directory# cd /usr/share/matrix-gui-2.0# rm -rf tmp/*# rm -rf lock/*# cd - # if [ -e $PIDFILE ]; then# PIDDIR=/proc/$(cat $PIDFILE)# if [ -d ${PIDDIR} -a"$(readlink -f ${PIDDIR}/exe)" ="${matrixgui}" ]; then# echo "$DESC already started; notstarting."# else# echo "Removing stale PID file$PIDFILE."# rm -f $PIDFILE# fi# fi # echo -n "Starting Matrix GUIapplication"# start-stop-daemon --start --quiet--background -m --pidfile $PIDFILE --exec $matrixgui -- $GUI_OPTS# echo "."# ;; #stop)# echo -n "Stopping Matrix GUIapplication"# start-stop-daemon --stop --quiet --pidfile$PIDFILE# echo "."# ;;#*)# echo "Usage:/etc/init.d/matrix-gui-2.0 {start|stop}"# exit 1esac exit 0
页:
[1]