mirror of
https://git.FreeBSD.org/ports.git
synced 2024-12-25 04:43:33 +00:00
- Fix build on 5.x (varargs)
- Respect ${CC} - Quiet portlint PR: ports/59973 Submitted by: Volker Stolz <stolz@i2.informatik.rwth-aachen.de> Approved by: maintainer timeout (9 days)
This commit is contained in:
parent
64a5f5ad11
commit
a509683ac7
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=95808
@ -11,26 +11,20 @@ PORTREVISION= 2
|
||||
CATEGORIES= mail
|
||||
MASTER_SITES= ftp://ftp.qualcomm.com/eudora/servers/unix/password/
|
||||
DISTNAME= pwserve-4
|
||||
EXTRACT_SUFX=
|
||||
|
||||
MAINTAINER= andrew@ugh.net.au
|
||||
COMMENT= A server to allow users to change their password from within Eudora
|
||||
|
||||
EXTRACT_CMD= /bin/cat
|
||||
EXTRACT_SUFX=
|
||||
EXTRACT_BEFORE_ARGS=
|
||||
EXTRACT_CMD= ${CAT}
|
||||
EXTRACT_BEFORE_ARGS=
|
||||
EXTRACT_AFTER_ARGS= | ${SED} -e '1,16d' | ${SH}
|
||||
WRKSRC= ${WRKDIR}/poppassd
|
||||
ALL_TARGET= poppassd
|
||||
MAN8= poppassd.8
|
||||
|
||||
.include <bsd.port.pre.mk>
|
||||
|
||||
.if ${OSVERSION} >= 501000
|
||||
BROKEN= "Does not compile"
|
||||
.endif
|
||||
|
||||
post-install:
|
||||
@ ${STRIP_CMD} ${PREFIX}/libexec/poppassd
|
||||
do-install:
|
||||
@ ${INSTALL_PROGRAM} ${WRKSRC}/poppassd ${PREFIX}/libexec
|
||||
@ ${INSTALL_MAN} ${FILESDIR}/poppassd.8 ${PREFIX}/man/man8/
|
||||
|
||||
.include <bsd.port.post.mk>
|
||||
.include <bsd.port.mk>
|
||||
|
@ -1,18 +1,29 @@
|
||||
--- Makefile.orig Mon Jul 7 15:20:49 2003
|
||||
+++ Makefile Mon Jul 7 15:23:01 2003
|
||||
@@ -1,11 +1,11 @@
|
||||
--- Makefile.orig Fri Dec 5 13:12:35 2003
|
||||
+++ Makefile Fri Dec 5 13:13:13 2003
|
||||
@@ -1,14 +1,14 @@
|
||||
-BINDIR = /usr/etc
|
||||
+BINDIR = ${PREFIX}/libexec
|
||||
LIBDIR =
|
||||
-CFLAGS = -g
|
||||
-LFLAGS = -g
|
||||
-CCM = cc -Em
|
||||
+CFLAGS?= -O
|
||||
+LFLAGS?= ${LDFLAGS}
|
||||
CCM = cc -Em
|
||||
+CCM = $(CC) -Em
|
||||
|
||||
OBJECTS = poppassd.o
|
||||
-LIBS =
|
||||
+LIBS = -lcrypt -lutil
|
||||
|
||||
poppassd: $(OBJECTS)
|
||||
cc -o poppassd $(LFLAGS) $(OBJECTS) $(LIBS)
|
||||
- cc -o poppassd $(LFLAGS) $(OBJECTS) $(LIBS)
|
||||
+ $(CC) -o poppassd $(LFLAGS) $(OBJECTS) $(LIBS)
|
||||
|
||||
install: poppassd
|
||||
install -g bin -o root -m 500 poppassd $(BINDIR)
|
||||
@@ -17,4 +17,4 @@
|
||||
rm -f *.o *~* core Makefile.new Makefile.bak poppassd
|
||||
|
||||
poppassd.o: poppassd.c
|
||||
- cc -c $(CFLAGS) poppassd.c
|
||||
+ $(CC) -c $(CFLAGS) poppassd.c
|
||||
|
@ -1,5 +1,5 @@
|
||||
--- poppassd.c.orig Mon Jul 7 15:15:03 2003
|
||||
+++ poppassd.c Mon Jul 7 15:17:46 2003
|
||||
--- poppassd.c.orig Fri Dec 5 13:14:06 2003
|
||||
+++ poppassd.c Fri Dec 5 13:15:49 2003
|
||||
@@ -13,11 +13,11 @@
|
||||
*
|
||||
* Doesn't actually change any passwords itself. It simply listens for
|
||||
@ -32,6 +32,15 @@
|
||||
* back to the client in the final 500 response, and a new version of the
|
||||
* code to find the next free pty, is by Norstad.
|
||||
*
|
||||
@@ -125,7 +125,7 @@
|
||||
#include <ctype.h>
|
||||
#include <strings.h>
|
||||
#include <errno.h>
|
||||
-#include <varargs.h>
|
||||
+#include <stdarg.h>
|
||||
#include <pwd.h>
|
||||
#include <string.h>
|
||||
#include <termios.h>
|
||||
@@ -145,8 +145,11 @@
|
||||
static char *P1[] =
|
||||
{"Old password:",
|
||||
@ -384,15 +393,32 @@
|
||||
/*
|
||||
* writestring()
|
||||
*
|
||||
@@ -485,8 +398,10 @@
|
||||
@@ -485,9 +398,11 @@
|
||||
}
|
||||
|
||||
writestring(master, pswd);
|
||||
-
|
||||
+ sleep(2);
|
||||
if (!expect(master, P4, buf)) return FAILURE;
|
||||
+
|
||||
+ close(master);
|
||||
|
||||
+ close(master);
|
||||
+
|
||||
return SUCCESS;
|
||||
}
|
||||
|
||||
@@ -630,13 +545,11 @@
|
||||
}
|
||||
}
|
||||
|
||||
-WriteToClient (fmt, va_alist)
|
||||
-char *fmt;
|
||||
-va_dcl
|
||||
+WriteToClient (char *fmt, ...)
|
||||
{
|
||||
va_list ap;
|
||||
|
||||
- va_start (ap);
|
||||
+ va_start (ap, fmt);
|
||||
vfprintf (stdout, fmt, ap);
|
||||
fputs ("\r\n", stdout );
|
||||
fflush (stdout);
|
||||
|
Loading…
Reference in New Issue
Block a user