GNU finger.

Submitted by:	MIHIRA Yoshiro <sanpei@yy.cs.keio.ac.jp>
This commit is contained in:
Satoshi Asami 1996-07-10 22:33:14 +00:00
parent 26bcf55f4b
commit c86362a6ac
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=3367
12 changed files with 211 additions and 0 deletions

28
net/gnu-finger/Makefile Normal file
View file

@ -0,0 +1,28 @@
# New ports collection makefile for: GNU finger
# Version required: 1.37
# Date created: 20 June 1996
# Whom: Yoshiro MIHIRA <sanpei@yy.cs.keio.ac.jp>
#
# $Id$
#
DISTNAME= finger-1.37
PKGNAME= gnu-finger-1.37
CATEGORIES= net
MASTER_SITES= ftp://ftp.cc.keio.ac.jp/pub/mirror/GNU/
MAINTAINE= sanpei@yy.cs.keio.ac.jp
HAS_CONFIGURE= yes
INSTALL_TARGET= server
post-install:
mkdir -p ${PREFIX}/etc/fingerdir
mkdir -p ${PREFIX}/etc/rc.d
@cp ${WRKSRC}/support/ttylocs ${PREFIX}/etc/fingerdir/ttylocs.sample
@cp ${FILESDIR}/clients.sample ${PREFIX}/etc/fingerdir/clients.sample
@install -c -m 744 -o root ${FILESDIR}/start.fingerd.sh.sample ${PREFIX}/etc/rc.d/start.fingerd.sh.sample
@echo "GNU.finger.server.hotname" > ${PREFIX}/etc/fingerdir/serverhost.sample
@echo "mail.spool.server.hostname" > ${PREFIX}/etc/fingerdir/mailhost.sample
.include <bsd.port.mk>

1
net/gnu-finger/distinfo Normal file
View file

@ -0,0 +1 @@
MD5 (finger-1.37.tar.gz) = fd2804df1ee71bac580ce5539d3469d9

View file

@ -0,0 +1,3 @@
#client.list
client1.somewhere.ac.jp
client2.somewhere.ac.jp

View file

@ -0,0 +1,26 @@
--- configure.orig Fri Oct 16 06:49:05 1992
+++ configure Mon Jul 8 19:39:32 1996
@@ -1041,8 +1041,10 @@
echo checking for /proc file system
- if test -r /proc ; then DEFS="$DEFS -DHAVE_PROC_FS=1"
- fi
+# if test -r /proc ; then DEFS="$DEFS -DHAVE_PROC_FS=1"
+# fi
+
+ DEFS="$DEFS -D_ANSI_SOURCE"
@@ -1071,8 +1073,9 @@
- echo checking for /usr/mail or /usr/spool/mail
+ echo checking for /usr/mail, /var/mail or /usr/spool/mail
if test -d /usr/mail ; then MAILDIR=/usr/mail
+ elif test -d /var/mail ; then MAILDIR=/var/mail
else MAILDIR=/usr/spool/mail
fi

View file

@ -0,0 +1,14 @@
--- lib/os.c.org Sat Jul 6 14:18:18 1996
+++ lib/os.c Sat Aug 26 23:38:18 1995
@@ -70,7 +70,11 @@
/* Where the utmp file is located. */
#ifndef HAVE_GETUTENT
+#ifdef __FreeBSD__
+#define UTMP_FILE "/var/run/utmp"
+#else
#define UTMP_FILE "/etc/utmp"
+#endif
#endif
/* A non-null value is the address of the utmp entry which contains the

View file

@ -0,0 +1,44 @@
--- src/finger.c.org Sat Jul 6 14:31:03 1996
+++ src/finger.c Sat Jul 6 16:23:39 1996
@@ -107,7 +107,6 @@
char *arg, *port;
int optc;
-
default_error_handling (argv[0]);
/* Parse the arguments passed on the command line. */
@@ -192,6 +191,7 @@
long addr;
char *finger_server = NULL;
int suppress_hostname = 0;
+ int malloc_flag = 0;
username = savestring (arg);
@@ -204,7 +204,7 @@
hostname = NULL;
if ((!username || !*username)
- && (finger_server = getservhost ()))
+ && (finger_server = getservhost (stderr)))
{
hostname = finger_server;
suppress_hostname = 1;
@@ -237,6 +237,7 @@
{
host = (struct hostent *) xmalloc (sizeof (struct hostent));
host->h_name = hostname;
+ malloc_flag = 1;
}
}
else
@@ -296,6 +297,7 @@
if (finger_server)
free (finger_server);
- if (host)
+ if (malloc_flag) {
free (host);
+ }
}

View file

@ -0,0 +1,13 @@
--- Makefile.in.orig Thu Oct 22 08:59:40 1992
+++ Makefile.in Mon Jul 8 19:44:26 1996
@@ -51,8 +51,8 @@
false
server: $(AUXOBJS) $(EXECUTABLES)
- (cd $(SRC); $(MAKE) $(MFLAGS) $(CC)="$(CC)" server)
- (cd targets; $(MAKE) $(MFLAGS) $(CC)="$(CC)" server)
+ (cd $(SRC); $(MAKE) $(MFLAGS) CC="$(CC)" server)
+ (cd targets; $(MAKE) $(MFLAGS) CC="$(CC)" server)
client: $(AUXOBJS) $(EXECUTABLES)
(cd $(SRC); $(MAKE) $(MFLAGS) CC="$(CC)" client)

View file

@ -0,0 +1,28 @@
--- src/Makefile.in.org Sat Jul 6 17:57:18 1996
+++ src/Makefile.in Sat Jul 6 18:04:43 1996
@@ -85,18 +85,18 @@
server: $(EXECUTABLES) .fingerdir .etcdir .bindir
-if [ ! -r `cat .etcdir` ]; then mkdir `cat .etcdir`; fi
-if [ ! -r `cat .fingerdir` ]; then mkdir `cat .fingerdir`; fi
- cp finger `cat .bindir`; chmod a+rx `cat .bindir`/finger
- cp fingerd `cat .etcdir`; chmod a+rx `cat .etcdir`/fingerd
- cp in.fingerd `cat .etcdir`; chmod a+rx `cat .etcdir`/in.fingerd
- cp in.cfingerd `cat .etcdir`; chmod a+rx `cat .etcdir`/in.cfingerd
+ install -c -m 755 -s finger `cat .bindir`/finger
+ install -c -m 744 -o root -s fingerd `cat .etcdir`/fingerd
+ install -c -m 744 -o nobody -s in.fingerd `cat .etcdir`/in.fingerd
+ install -c -m 744 -o nobody -s in.cfingerd `cat .etcdir`/in.cfingerd
(cd ../lib/site; make install)
client: $(EXECUTABLES) .etcdir .fingerdir .bindir
-if [ ! -r `cat .etcdir` ]; then mkdir `cat .etcdir`; fi
-if [ ! -r `cat .fingerdir` ]; then mkdir `cat .fingerdir`; fi
- cp finger `cat .bindir`; chmod a+rx `cat .bindir`/finger
- cp in.fingerd `cat .etcdir`; chmod a+rx `cat .etcdir`/in.fingerd
- cp in.cfingerd `cat .etcdir`; chmod a+rx `cat .etcdir`/in.cfingerd
+ install -c -m 755 -s finger `cat .bindir`/finger
+ install -c -m 744 -o nobody -s in.fingerd `cat .etcdir`/in.fingerd
+ install -c -m 744 -o nobody -s in.cfingerd `cat .etcdir`/in.cfingerd
touch `cat .fingerdir`/ttylocs
clean:

View file

@ -0,0 +1,11 @@
--- config.h.org Mon Jul 8 19:10:59 1996
+++ config.h Mon Jul 8 19:11:16 1996
@@ -133,7 +133,7 @@
#define FingerDir /usr/local/etc/fingerdir
#define BinDir /usr/local/bin
-#define EtcDir /usr/local/etc
+#define EtcDir /usr/local/libexec
#define MugShotPath "/usr/local/lib/mugshots:/usr/local/mugshots"
/* Define USE_DATABASE if you want to keep information about users in

View file

@ -0,0 +1 @@
GNU version of finger.

31
net/gnu-finger/pkg-descr Normal file
View file

@ -0,0 +1,31 @@
* GNU finger for FreeBSD *
* CAUTION *
This ports collection is install some daemon programs,
to /usr/local/libexec, *NOT* to /usr/local/etc.
* how to quick install: *
1) Pleae rewrite collectory serverhost,clients,mailhost for your site.
Sample file is in /usr/local/etc/fingerdir.
2) Add below lines to /etc/inetd.conf
cfingerd stream tcp nowait nobody /usr/local/libexec/in.cfingerd in.cfingerd
finger stream tcp nowait nobody /usr/local/libexec/in.fingerd in.fingerd
3) Comment out old finger line in /etc/inetd.conf
#finger stream tcp nowait nobody /usr/libexec/fingerd fingerd -s
4) Restart inetd
% kill -HUP `cat /var/run/inetd.pid`
5) If this host is GNU finger server host,
move start.fingerd.sh.sample to start.fingerd.sh in /usr/local/etc/rc.d
directory.
And exec start_fingerd.sh.
- Yoshiro MIHIRA
(sanpei@yy.cs.keio.ac.jp)

11
net/gnu-finger/pkg-plist Normal file
View file

@ -0,0 +1,11 @@
bin/finger
libexec/fingerd
libexec/in.fingerd
libexec/in.cfingerd
etc/rc.d/start.fingerd.sh.sample
etc/fingerdir/ttylocs.sample
etc/fingerdir/clients.sample
etc/fingerdir/mailhost.sample
etc/fingerdir/serverhost.sample
etc/fingerdir/targets/x-.help
etc/fingerdir/targets/x-.site