Arc Forumnew | comments | leaders | submitlogin
rc-script for Arc in Gentoo Linux
4 points by ryuji 6118 days ago | discuss
I running Arc in Gentoo, and I wrote rc-script for news.arc. It works on Anarki.

rc-news.arc

    (load "news.arc")
    (nsv)
/etc/init.d/news

    #!/sbin/runscript

    depend() {
      use net
      before lighttpd
    }

    MZSCHEME="/usr/local/bin/mzscheme" # path to mzscheme
    ARC_HOME="/usr/local/arc"          # path to arc directory

    start() {
      ebegin "Starting News"
      start-stop-daemon --start --quiet --background --make-pidfile \
                        --pidfile /var/run/news.pid --exec "$MZSCHEME" \
                        -- --no-init-file --mute-banner --load-cd \
                           "$ARC_HOME/as.scm" "$ARC_HOME/rc-news.arc"
      eend 0 "Failed to start News"
    }

    stop() {
      ebegin "Stopping News"
      start-stop-daemon --stop --quiet --pidfile /var/run/news.pid 
      eend 0 "Failed to stop News"
    }
Now,

    # /etc/init.d/news start
    # /etc/init.d/news restart
    # /etc/init.d/news stop 
In this way stop-start control is possible.

See also http://mgiken.com/2008/03/30/144523 (This is my blog, but Japanese version only).