aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorEric S. Raymond <esr@thyrsus.com>1996-09-13 19:07:38 +0000
committerEric S. Raymond <esr@thyrsus.com>1996-09-13 19:07:38 +0000
commit538023278d853b2f310954e0b220be25ccea6330 (patch)
tree12b9ab819fdf7f30127c60156072acb62f177a48
parent0df439b3a15fac408f8273c22e4a94b7b70d166f (diff)
downloadfetchmail-538023278d853b2f310954e0b220be25ccea6330.tar.gz
fetchmail-538023278d853b2f310954e0b220be25ccea6330.tar.bz2
fetchmail-538023278d853b2f310954e0b220be25ccea6330.zip
QNX port.
svn path=/trunk/; revision=96
-rw-r--r--Makefile.in7
-rw-r--r--NEWS6
-rw-r--r--README4
-rw-r--r--daemon.c8
-rw-r--r--socket.c14
-rw-r--r--strcasecmp.c6
6 files changed, 44 insertions, 1 deletions
diff --git a/Makefile.in b/Makefile.in
index 1b21e6fc..b8643751 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -1,5 +1,8 @@
# Makefile for popclient
+# If you're running QNX, we can't assume a working autoconf.
+# So just uncomment all the lines marked QNX.
+
# Ultrix 2.2 make doesn't expand the value of VPATH.
srcdir = @srcdir@
VPATH = @srcdir@
@@ -7,7 +10,9 @@ VPATH = @srcdir@
CC = @CC@
CFLAGS = @CFLAGS@
+# CFLAGS = -g2 -5 # QNX
LDFLAGS = @LDFLAGS@
+# LDLAGS = -g2 -5 # QNX
LEX = @LEX@
LEXFLAGS=
YACC = @YACC@
@@ -19,9 +24,11 @@ RANLIB = @RANLIB@
# NeXT 1.0a uses an old version of GCC, which required -D__inline=inline.
# See also `config.h'.
defines = @DEFS@
+# defines = -DHAVE_CONFIG_H -DQNX -DHAVE_UNISTD_H -DSTDC_HEADERS # QNX
# If your system needs extra libraries loaded in, define them here.
LOADLIBS = @LIBS@ @LEXLIB@
+# LOADLIBS = -lsocket3r -lunix3r # QNX
# Any extra object files your system needs.
extras = @LIBOBJS@
diff --git a/NEWS b/NEWS
index c6393294..fcdc8653 100644
--- a/NEWS
+++ b/NEWS
@@ -10,6 +10,12 @@ Recode POP2 to use the same driver/method strategy as POP3/IMAP, so
all three protocols will be able to forward messages through the generic
driver to SMTP. (This requires that we find a POP2 server to test with.)
+3.2:
+
+* RPOP support.
+
+* Ported to QNX (see the Makefile).
+
3.1:
* MDA arguments are now dumped when using the -V option.
diff --git a/README b/README
index c66e2891..42c0cd6d 100644
--- a/README
+++ b/README
@@ -4,6 +4,10 @@ popclient is a full-featured, robust, well-documented POP2, POP3, APOP,
and IMAP client originally developed by Carl Harris <ceharris@mal.com> and
now maintained by Eric S. Raymond <esr@thyrsus.com>.
+popclient was developed under Linux and should be readily portable to other
+UNIX systems (it uses GNU autoconf). It has also been ported to QNX; to build
+under QNX, see the header commets in the Makefile.
+
You can find the latest version of popclient from Eric's home page
http://www.ccil.org/~esr
diff --git a/daemon.c b/daemon.c
index 087f051f..b08f31e9 100644
--- a/daemon.c
+++ b/daemon.c
@@ -31,6 +31,10 @@
# include <unistd.h>
#endif
+#if defined(QNX)
+# include <unix.h>
+#endif
+
/* BSD portability hack */
#if !defined(SIGCLD) && defined(SIGCHLD)
#define SIGCLD SIGCHLD
@@ -203,5 +207,7 @@ nottyDetach:
/* set up to catch child process termination signals */
signal(SIGCLD, sigchld_handler);
-
+#if defined(QNX)
+ signal(SIGPWR, sigchld_handler);
+#endif
}
diff --git a/socket.c b/socket.c
index 058b3ea6..fdbd9cb1 100644
--- a/socket.c
+++ b/socket.c
@@ -27,7 +27,12 @@
#if defined(HAVE_UNISTD_H)
#include <unistd.h>
#endif
+#if defined(QNX)
+#include <stdio.h>
+#include <stdarg.h>
+#else
#include <stdlib.h>
+#endif
#include <varargs.h>
#include <errno.h>
#include "bzero.h"
@@ -181,15 +186,24 @@ int len;
else {
bcopy(bp,buf,len);
sbuflen -= len;
+#if defined(QNX)
+int SockPrintf(int socket, char* format, ...)
+{
+#else
bp += len;
}
return(len);
}
+#endif
/* SockClearHeader: call this procedure in order to kill off any
forthcoming Header info from the socket that we no longer want.
*/
+#if defined(QNX)
+ va_start(ap, format) ;
+#else
int SockClearHeader(socket)
+#endif
int socket;
{
char *bufp;
diff --git a/strcasecmp.c b/strcasecmp.c
index 33879c3c..8d9b43b9 100644
--- a/strcasecmp.c
+++ b/strcasecmp.c
@@ -19,10 +19,16 @@
static char sccsid[] = "@(#)strcasecmp.c 5.6 (Berkeley) 6/27/88";
#endif /* LIBC_SCCS and not lint */
+#if defined(QNX)
+#include <sys/types.h>
+#else
+
#ifndef(u_char)
typedef unsigned char u_char;
#endif
+#endif
+
/*
* This array is designed for mapping upper and lower case letter
* together for a case independent comparison. The mappings are