summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorchatty2000-07-12 17:22:32 +0000
committerchatty2000-07-12 17:22:32 +0000
commit227085e3523a86256b92fce2ac9ce02c67167408 (patch)
treeb50073aa20edc2a6fb264a9ad9a83d25dc36cb18
parent0578c020acd44c8df3d143d14bace5871062d956 (diff)
downloadivyd-227085e3523a86256b92fce2ac9ce02c67167408.zip
ivyd-227085e3523a86256b92fce2ac9ce02c67167408.tar.gz
ivyd-227085e3523a86256b92fce2ac9ce02c67167408.tar.bz2
ivyd-227085e3523a86256b92fce2ac9ce02c67167408.tar.xz
ivyd.init is now part of the rpm installation
Now install man pages Replaced a literal value with a macro in inivyd.c
-rw-r--r--src/Makefile25
-rw-r--r--src/inivyd.c2
-rwxr-xr-xsrc/ivyd.init43
3 files changed, 12 insertions, 58 deletions
diff --git a/src/Makefile b/src/Makefile
index 1379bf0..2f8b110 100644
--- a/src/Makefile
+++ b/src/Makefile
@@ -14,6 +14,8 @@
# copyright notice regarding this software
#
#
+BIN = $(PREFIX)/usr/bin
+MAN = $(PREFIX)/usr/man
INCDIRS =
CFLAGS = -g -Wall $(INCDIRS)
@@ -43,20 +45,15 @@ clean:
-rm -f *.o *~ $(PROGS)
install: all
- test -d $(PREFIX)/usr/bin || mkdirhier $(PREFIX)/usr/bin
- install -m 755 in.ivyd $(PREFIX)/usr/bin/in.ivyd
- install -m 755 ivyd $(PREFIX)/usr/bin/ivyd
- install -m 755 ivyecho $(PREFIX)/usr/bin/ivyecho
- test -d $(PREFIX)/etc/rc.d/init.d || mkdirhier $(PREFIX)/etc/rc.d/init.d
- test -d $(PREFIX)/etc/rc.d/rc2.d || mkdirhier $(PREFIX)/etc/rc.d/rc2.d
- test -d $(PREFIX)/etc/rc.d/rc3.d || mkdirhier $(PREFIX)/etc/rc.d/rc3.d
- test -d $(PREFIX)/etc/rc.d/rc4.d || mkdirhier $(PREFIX)/etc/rc.d/rc4.d
- test -d $(PREFIX)/etc/rc.d/rc5.d || mkdirhier $(PREFIX)/etc/rc.d/rc5.d
- install -m755 ivyd.init $(PREFIX)/etc/rc.d/init.d/ivyd
- ln -s /etc/rc.d/init.d/ivyd $(PREFIX)/etc/rc.d/rc2.d/S97ivyd
- ln -s /etc/rc.d/init.d/ivyd $(PREFIX)/etc/rc.d/rc3.d/S97ivyd
- ln -s /etc/rc.d/init.d/ivyd $(PREFIX)/etc/rc.d/rc4.d/S97ivyd
- ln -s /etc/rc.d/init.d/ivyd $(PREFIX)/etc/rc.d/rc5.d/S97ivyd
+ test -d $(BIN) || mkdirhier $(BIN)
+ install -m 755 in.ivyd $(BIN)/in.ivyd
+ install -m 755 ivyd $(BIN)/ivyd
+ install -m 755 ivyecho $(BIN)/ivyecho
+ test -d $(MAN)/man1 || mkdirhier $(MAN)/man1
+ install -m 644 ../doc/ivyecho.1 $(MAN)/man1
+ install -m 644 ../doc/ivyd.1 $(MAN)/man1
+ test -d $(MAN)/man8 || mkdirhier $(MAN)/man8
+ install -m 644 ../doc/in.ivyd.8 $(MAN)/man8
rpm::
diff --git a/src/inivyd.c b/src/inivyd.c
index 72e6ff0..d5accda 100644
--- a/src/inivyd.c
+++ b/src/inivyd.c
@@ -55,7 +55,7 @@ const char* const dumpfilename = "/tmp/in.ivyd.db";
const int dumpfilemode = 0644;
const char* const servicename = "ivyd";
const char* const port_env_variable = "INIVYD_PORT";
-const int default_port = 3006;
+const int default_port = DEFAULT_INIVYD_PORT;
/*
* The association table managed by the super-daemon
diff --git a/src/ivyd.init b/src/ivyd.init
deleted file mode 100755
index d6e3e8b..0000000
--- a/src/ivyd.init
+++ /dev/null
@@ -1,43 +0,0 @@
-#!/bin/sh
-#
-# irbox: Starts the in.ivyd super-daemon for the ivyd Ivy relay
-#
-# Version: @(#) /etc/rc.d/init.d/irbox.init 1.1
-#
-# chkconfig: - 97 03
-# description: This is a daemon that works as a port server for ivyd, \
-# a relay to Ivy for short-lived applications
-# processname: in.ivyd
-# config:
-
-# Source function library.
-. /etc/rc.d/init.d/functions
-
-# See how we were called.
-case "$1" in
- start)
- echo -n "Ivy daemon port server... "
- daemon in.ivyd -boot
- echo
- touch /var/lock/subsys/ivyd
- ;;
- stop)
- echo -n "Shutting down Ivy daemon port server "
- killproc in.ivyd
- rm -f /var/lock/subsys/ivyd
- echo
- ;;
- status)
- status in.ivyd
- ;;
- restart)
- $0 stop
- $0 start
- ;;
- *)
- echo "*** Usage: ivyd {start|stop|status|restart}"
- exit 1
-esac
-
-exit 0
-