summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSteve Arnold <nerdboy@gentoo.org>2003-11-01 04:40:49 +0000
committerSteve Arnold <nerdboy@gentoo.org>2003-11-01 04:40:49 +0000
commitb4d819103dd0c897a0e97687e1d192f762b98351 (patch)
tree9f521a64d67afe3bf6fc462ba98c9db8e72c7ba1 /net-misc
parentnew gentoo-style init script (diff)
downloadgentoo-2-b4d819103dd0c897a0e97687e1d192f762b98351.tar.gz
gentoo-2-b4d819103dd0c897a0e97687e1d192f762b98351.tar.bz2
gentoo-2-b4d819103dd0c897a0e97687e1d192f762b98351.zip
new gentoo-style init script
Diffstat (limited to 'net-misc')
-rw-r--r--net-misc/hylafax/ChangeLog11
-rw-r--r--net-misc/hylafax/Manifest6
-rw-r--r--net-misc/hylafax/files/digest-hylafax-4.1.7-r21
-rw-r--r--net-misc/hylafax/files/hylafax159
-rw-r--r--net-misc/hylafax/hylafax-4.1.7-r2.ebuild80
5 files changed, 252 insertions, 5 deletions
diff --git a/net-misc/hylafax/ChangeLog b/net-misc/hylafax/ChangeLog
index c6a70ae25de9..a6c50d37511c 100644
--- a/net-misc/hylafax/ChangeLog
+++ b/net-misc/hylafax/ChangeLog
@@ -1,6 +1,12 @@
# ChangeLog for net-misc/hylafax
# Copyright 2002-2003 Gentoo Technologies, Inc.; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/net-misc/hylafax/ChangeLog,v 1.19 2003/10/25 05:57:26 nerdboy Exp $
+# $Header: /var/cvsroot/gentoo-x86/net-misc/hylafax/ChangeLog,v 1.20 2003/11/01 04:40:46 nerdboy Exp $
+
+*hylafax-4.1.7-r2 (31 Oct 2003)
+
+ 31 Oct 2003; <nerdboy@gentoo.org> hylafax-4.1.7-r2.ebuild, files/hylafax:
+ new gentoo-style init script contributed by Patrick Daxboeck
+ <gentoo@daxboeck.com>
24 Oct 2003; <nerdboy@gentoo.org> hylafax-4.1.7-r1.ebuild:
bump r1 to x86 (a little early, but...)
@@ -21,7 +27,8 @@
20 Sep 2003; <sarnold@gentoo.org> hylafax-4.1.7.ebuild:
version bump with ebuild from Stephane LOEUILLET, re Bug 28574
- 06 Dec 2002; Rodney Rees <manson@gentoo.org> : changed sparc ~sparc keywords
+ 06 Dec 2002; Rodney Rees <manson@gentoo.org> : changed sparc ~sparc
+ keywords
*hylafax-4.1.5 (25 Oct 2002)
diff --git a/net-misc/hylafax/Manifest b/net-misc/hylafax/Manifest
index 30687357f657..76201ba61412 100644
--- a/net-misc/hylafax/Manifest
+++ b/net-misc/hylafax/Manifest
@@ -1,10 +1,10 @@
-MD5 78a6e23566b80aa5bd96d7e3c4bdf88e ChangeLog 4486
+MD5 9afe1ad5ee7d6463b4e872c7ac50c20e ChangeLog 4577
MD5 6057f28d0a94aa5ef3a23980ff473676 hylafax-4.1.5.ebuild 1714
MD5 0035400761422f75b958a55adf5773b2 hylafax-4.1.7.ebuild 2133
MD5 d82acf1bcf0f7f9e181d6a2821292f2e metadata.xml 435
MD5 9fa5e274acf12b629a9ddf5cfbf6f9c5 hylafax-4.1.7-r1.ebuild 2186
-MD5 562f6b3c91103da888d50aef55c970ec hylafax-4.1.7-r2.ebuild 2225
-MD5 e6e51a44ddd0e7fb91d8ceb6112eab9d files/hylafax 3659
+MD5 4baf1c5ef974336f9b495d76c787860f hylafax-4.1.7-r2.ebuild 2225
+MD5 75f80b00ebdc1319633a6960216179d5 files/hylafax 3753
MD5 2ebb269cf0ba67d69d582a3f139c11e5 files/digest-hylafax-4.1.5 66
MD5 620e9bbfd90a0fad3a5324cac04ffc81 files/hylafax-4.1.2-gentoo-diffs.tar.bz2 3993
MD5 2db231b7619b5613bc06da8711626b05 files/digest-hylafax-4.1.7 66
diff --git a/net-misc/hylafax/files/digest-hylafax-4.1.7-r2 b/net-misc/hylafax/files/digest-hylafax-4.1.7-r2
new file mode 100644
index 000000000000..cff01ad567c0
--- /dev/null
+++ b/net-misc/hylafax/files/digest-hylafax-4.1.7-r2
@@ -0,0 +1 @@
+MD5 1302066b0055a060e525026919d98ff7 hylafax-4.1.7.tar.gz 1285766
diff --git a/net-misc/hylafax/files/hylafax b/net-misc/hylafax/files/hylafax
new file mode 100644
index 000000000000..57e976646229
--- /dev/null
+++ b/net-misc/hylafax/files/hylafax
@@ -0,0 +1,159 @@
+#!/sbin/runscript
+# Copyright 1999-2003 Gentoo Technologies, Inc.
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/net-misc/hylafax/files/hylafax,v 1.1 2003/11/01 04:40:46 nerdboy Exp $
+
+depend() {
+ need net
+}
+
+checkconfig() {
+ SPOOL=/var/spool/fax
+ if [ ! -f $SPOOL/etc/setup.cache ] ; then
+ eerror "No $SPOOL/etc/setup.cache file exists! Use faxsetup(8C) !"
+ fi
+
+}
+
+start() {
+ ebegin "Starting HylaFAX Servers."
+ SPOOL=/var/spool/fax
+ checkconfig || return 1
+
+ . $SPOOL/etc/setup.cache
+
+ # Just in case these are not in setup.cache yet
+ if [ -z "$HFAXD_SERVER" ]; then
+ HFAXD_SERVER=yes
+ fi
+ if [ -z "$FAXQ_SERVER" ]; then
+ FAXQ_SERVER=yes
+ fi
+ if [ -z "$HFAXD_OLD_PROTOCOL" ]; then
+ HFAXD_OLD_PROTOCOL=no
+ fi
+ if [ -z "$HFAXD_SNPP_SERVER" ]; then
+ HFAXD_SNPP_SERVER=no
+ fi
+
+ IS_ON=/etc/chkconfig # NB: chkconfig is IRIX- and Linux-specific
+ FAXQ=$SBIN/faxq
+ HFAXD=$LIBEXEC/hfaxd
+ FAXQUIT=$SBIN/faxquit
+ FAXPORT=hylafax # designated port for new protocol
+ SNPPPORT=444 # official port for SNPP
+
+ if test ! -x $IS_ON ; then
+ IS_ON=true
+ fi
+
+ if $IS_ON verbose ; then
+ ECHO=echo
+ else # For a quiet startup and shutdown
+ ECHO=:
+ fi
+#
+# Figure out which brand of echo we have and define prompt
+# and printf shell functions accordingly. Note that we
+# assume that if the System V-style echo is not present,
+# then the BSD printf program is available. These functions
+# are defined here so that they can be tailored on a per-site,
+# etc. basis.
+#
+ if [ `echo foo\\\c`@ = "foo@" ]; then
+# System V-style echo supports \r
+# and \c which is all that we need
+ printf()
+ {
+ $ECHO "$*\\c"
+ }
+ elif [ "`echo -n foo`@" = "foo@" ]; then
+# BSD-style echo; use echo -n to get
+# a line without the trailing newline
+ printf()
+ {
+ $ECHO -n "$*"
+ }
+ else
+# something else; do without
+ printf()
+ {
+ $ECHO "$*"
+ }
+ fi
+
+#
+#
+# killall -SIGNAL process-name
+#
+# Emulate the necessary functionality of the
+# killall program
+#
+ killall()
+ {
+# NB: ps ax should give an error on System V, so we try it first!
+ pid="`ps ax 2>/dev/null | $AWK \"\
+ /[\/ (]$2[ )]/ {print \\$1;}
+ /[\/ ]$2\$/ {print \\$1;}\"`"
+ test "$pid" ||
+ pid="`ps -e 2>/dev/null | $AWK \"/ $2[ ]*\$/ {print \\$1;}\"`"
+ test "$pid" && kill $1 $pid; return
+ }
+
+ if $IS_ON fax && test -x $FAXQ; then
+ if test $FAXQ_SERVER = yes ; then
+ killall -15 faxq
+ fi
+ if test $HFAXD_SERVER = yes ; then
+ killall -15 hfaxd
+ fi
+ printf "HylaFAX:"
+ if test $FAXQ_SERVER = yes ; then
+ $FAXQ; printf " faxq"
+ fi
+ if test $HFAXD_SERVER = yes ; then
+ HFAXD_OPT="-i $FAXPORT"
+# HFAXD="$HFAXD -i $FAXPORT"
+ HFAXMSG=" hfaxd"
+ if [ $HFAXD_OLD_PROTOCOL = yes ]; then
+ HFAXD_OPT="$HFAXD_OPT -o 4557"
+# HFAXD="$HFAXD -o 4557"
+ HFAXMSG="$HFAXMSG (with old protocol"
+ else
+ HFAXMSG="$HFAXMSG (without old protocol"
+ fi
+ if [ $HFAXD_SNPP_SERVER = yes ]; then
+ HFAXD_OPT="$HFAXD_OPT -s $SNPPPORT"
+# HFAXD="$HFAXD -s $SNPPPORT"
+ HFAXMSG="$HFAXMSG & with SNPP support)"
+
+ HFAXMSG="$HFAXMSG & without SNPP support)"
+ fi
+# $HFAXD ; printf "$HFAXMSG"
+ echo $HFAXMSG
+ echo $HFAXD $HFAXD_OPT
+ /sbin/start-stop-daemon --start --quiet --exec $HFAXD -- $HFAXD_OPT
+ fi
+ if test $FAXQ_SERVER != yes -a $HFAXD_SERVER != yes ; then
+ printf " not started (script disabled by configure)"
+ fi
+ $ECHO "."
+ fi
+ eend $?
+
+}
+
+stop() {
+ ebegin "Stopping HylaFAX Servers."
+ checkconfig || return 2
+ . $SPOOL/etc/setup.cache
+ FAXQUIT=$SBIN/faxquit
+ HFAXD=$LIBEXEC/hfaxd
+
+# $ECHO "Stopping HylaFAX Servers."
+ $FAXQUIT >/dev/null 2>&1
+ /sbin/start-stop-daemon --stop --quiet --exec $HFAXD
+ eend $?
+# killall -15 hfaxd
+
+}
diff --git a/net-misc/hylafax/hylafax-4.1.7-r2.ebuild b/net-misc/hylafax/hylafax-4.1.7-r2.ebuild
new file mode 100644
index 000000000000..840c7745d89e
--- /dev/null
+++ b/net-misc/hylafax/hylafax-4.1.7-r2.ebuild
@@ -0,0 +1,80 @@
+# Copyright 1999-2003 Gentoo Technologies, Inc.
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/net-misc/hylafax/hylafax-4.1.7-r2.ebuild,v 1.1 2003/11/01 04:40:46 nerdboy Exp $
+
+# This is basically unchanged from the one supplied by Stephane Loeuillet
+# to Gentoo bug: http://bugs.gentoo.org/show_bug.cgi?id=28574
+# Nice job, and thanks :)
+# Now with autoreconf for new gcc, and a new gentoo init script.
+
+IUSE="jpeg"
+
+S=${WORKDIR}/${P}
+DESCRIPTION="Client-server fax package for class 1 and 2 fax modems."
+HOMEPAGE="http://www.hylafax.org"
+SRC_URI="ftp://ftp.hylafax.org/source/${P}.tar.gz"
+
+SLOT="0"
+LICENSE="hylafax"
+KEYWORDS="~x86 ~ppc ~sparc ~alpha ~mips ~hppa ~arm"
+
+DEPEND="net-dialup/mgetty
+ >=sys-libs/zlib-1.1.4
+ >=app-text/ghostscript-5.50
+ >=media-libs/tiff-3.5.5
+ jpeg? ( media-libs/jpeg )
+ sys-apps/gawk"
+
+RDEPEND="${DEPEND}"
+
+src_compile() {
+ # no 'econf' here because does not support standard --prefix option (prehistoric autoconf v1.92 used !!!)
+ autoreconf -f
+ ./configure \
+ --with-DIR_BIN=/usr/bin \
+ --with-DIR_SBIN=/usr/sbin \
+ --with-DIR_LIB=/usr/lib \
+ --with-DIR_LIBEXEC=/usr/sbin \
+ --with-DIR_LIBDATA=/usr/lib/fax \
+ --with-DIR_LOCKS=/var/lock \
+ --with-DIR_MAN=/usr/share/man \
+ --with-DIR_SPOOL=/var/spool/fax \
+ --with-AFM=no \
+ --with-AWK=/usr/bin/gawk \
+ --with-PATH_VGETTY=/sbin/vgetty \
+ --with-PATH_GETTY=/sbin/agetty \
+ --with-HTML=no \
+ --with-PATH_DPSRIP=/var/spool/fax/bin/ps2fax \
+ --with-PATH_IMPRIP=/usr/share/fax/psrip \
+ --with-SYSVINIT=/etc/init.d \
+ --with-INTERACTIVE=no \
+ --with-OPTIMIZER="${CFLAGS}" || die
+ # no 'emake' for the same reason (might use an old automake version)
+ make || die
+}
+
+src_install() {
+
+ dodir /usr/{bin,sbin} /usr/lib/fax /usr/share/man \
+ /var/spool/fax/{archive,client,pollq,recvq,tmp}
+ chown -R uucp:uucp ${D}/var/spool/fax
+
+ make \
+ BIN=${D}/usr/bin \
+ SBIN=${D}/usr/sbin \
+ LIBDIR=${D}/usr/lib \
+ LIB=${D}/usr/lib \
+ LIBEXEC=${D}/usr/sbin \
+ LIBDATA=${D}/usr/lib/fax \
+ MAN=${D}/usr/share/man \
+ SPOOL=${D}/var/spool/fax \
+ install || die
+
+ insinto /etc/init.d
+ insopts -m 755
+ doins ${FILESDIR}/hylafax
+
+ dodoc COPYRIGHT README TODO VERSION
+
+ dohtml -r html/
+}