# HG changeset patch # User Hans-G?nter Theisgen # Date 1645709123 -3600 # Node ID 0db0ae7e04c2e49e55f7969e97d41789fb2b45c9 # Parent 7dc646816bdc64256ed0ed7cbbd9b63b0b107a41 updated fcron (3.2.1 -> 3.3.1) diff -r 7dc646816bdc -r 0db0ae7e04c2 fcron/description.txt --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/fcron/description.txt Thu Feb 24 14:25:23 2022 +0100 @@ -0,0 +1,11 @@ +Fcron is a periodical command scheduler which aims at replacing +Vixie Cron, so it implements most of its functionalities. + +But fcron makes no assumptions on whether your system is running +all the time or regularly: you can, for instance, tell fcron to +execute tasks every x hours y minutes of system up time or to do +a job only once in a specified interval of time. + +Fcron has also much more functionalities: you can also set a nice +value to a job, run it depending on the system load average and +much more! diff -r 7dc646816bdc -r 0db0ae7e04c2 fcron/receipt --- a/fcron/receipt Wed Feb 23 17:37:38 2022 +0000 +++ b/fcron/receipt Thu Feb 24 14:25:23 2022 +0100 @@ -1,7 +1,7 @@ # SliTaz package receipt. PACKAGE="fcron" -VERSION="3.2.1" +VERSION="3.3.1" CATEGORY="network" TAGS="cron scheduler" SHORT_DESC="Periodical command scheduler." @@ -12,7 +12,7 @@ TARBALL="$PACKAGE-$VERSION.src.tar.gz" WGET_URL="http://fcron.free.fr/archives/$TARBALL" -DEPENDS="" +DEPENDS="readline" BUILD_DEPENDS="perl readline-dev" # What is the latest version available today? @@ -25,23 +25,24 @@ # Rules to configure and make the package. compile_rules() { - ./configure \ - --prefix=/usr \ - --sysconfdir=/etc \ - --localstatedir=/var \ - --without-sendmail \ - --with-username=nobody \ - --with-groupname=nogroup \ - --with-pam=no \ - --with-selinux=no \ - --with-answer-all=no \ - --with-boot-install=no \ - --with-editor=/bin/vi \ - --with-sysfcrontab=yes \ - --with-systemdsystemunitdir=none \ + ./configure \ + LIBS="-lrt" \ + --prefix=/usr \ + --sysconfdir=/etc \ + --localstatedir=/var \ + --without-sendmail \ + --with-answer-all=no \ + --with-boot-install=no \ + --with-editor=/bin/vi \ + --with-groupname=nogroup \ + --with-pam=no \ + --with-selinux=no \ + --with-sysfcrontab=yes \ + --with-systemdsystemunitdir=no \ + --with-username=nobody \ $CONFIGURE_ARGS && make && - make DESTDIR=$DESTDIR install + make install DESTDIR=$DESTDIR } # Rules to gen a SliTaz package suitable for Tazpkg. @@ -57,3 +58,18 @@ cp -a stuff/fcron $fs/etc/init.d } + +# Post install commands for Tazpkg +post_install() +{ + if ! grep -q ^FCRON_OPTIONS "$1/etc/daemons.conf" + then + echo -e ' +# inserted by post_install of fcron: +# Fcron daemon options. +FCRON_OPTIONS="-b" + +' >> "$1/etc/daemons.conf" + fi +} + diff -r 7dc646816bdc -r 0db0ae7e04c2 fcron/stuff/fcron --- a/fcron/stuff/fcron Wed Feb 23 17:37:38 2022 +0000 +++ b/fcron/stuff/fcron Thu Feb 24 14:25:23 2022 +0100 @@ -1,8 +1,8 @@ #!/bin/sh -# /etc/init.d/fcron : Start, stop and fcron on SliTaz, at -# boot time or with the command line. +# /etc/init.d/fcron : Start, stop and restart fcron on SliTaz, +# at boot time or with the command line. # -# To start SSH server at boot time, just put fcron in the $RUN_DAEMONS +# To start fcron server at boot time, just put fcron in the RUN_DAEMONS # variable of /etc/rcS.conf and configure options with /etc/daemons.conf # . /etc/init.d/rc.functions @@ -11,44 +11,48 @@ NAME=fcron DESC="$(_ '%s daemon' Cron)" DAEMON=/usr/bin/fcron -OPTIONS=-b +OPTIONS="$FCRON_OPTIONS" +[ -n "$FCRON_OPTIONS" ] || OPTIONS="-b" PIDFILE=/var/run/fcron.pid case "$1" in - start) - if active_pidfile $PIDFILE fcron ; then - _ '%s is already running.' $NAME - exit 1 - fi - action 'Starting %s: %s...' "$DESC" $NAME - $DAEMON $OPTIONS - status - ;; - stop) - if ! active_pidfile $PIDFILE fcron ; then - _ '%s is not running.' $NAME - exit 1 - fi - action 'Stopping %s: %s...' "$DESC" $NAME - kill $(cat $PIDFILE) - status - ;; - restart) - if ! active_pidfile $PIDFILE fcron ; then - _ '%s is not running.' $NAME - exit 1 - fi - action 'Restarting %s: %s...' "$DESC" $NAME - kill $(cat $PIDFILE) - sleep 2 - $DAEMON $OPTIONS - status - ;; - *) - emsg "$(_ 'Usage:') $0 [start|stop|restart]" - newline - exit 1 - ;; + (start) + if active_pidfile $PIDFILE fcron + then + _ '%s is already running.' $NAME + exit 1 + fi + action 'Starting %s: %s...' "$DESC" $NAME + $DAEMON $OPTIONS + status + ;; + (stop) + if ! active_pidfile $PIDFILE fcron + then + _ '%s is not running.' $NAME + exit 1 + fi + action 'Stopping %s: %s...' "$DESC" $NAME + kill $(cat $PIDFILE) + status + ;; + (restart) + if ! active_pidfile $PIDFILE fcron + then + _ '%s is not running.' $NAME + exit 1 + fi + action 'Restarting %s: %s...' "$DESC" $NAME + kill $(cat $PIDFILE) + sleep 2 + $DAEMON $OPTIONS + status + ;; + (*) + emsg "$(_ 'Usage:') $0 [start|stop|restart]" + newline + exit 1 + ;; esac exit 0