From d7d246e4882d54df4fcb824b26a4f940e2bbf4bc Mon Sep 17 00:00:00 2001 From: Nathan Bryant Date: Fri, 11 Feb 2000 23:45:04 +0000 Subject: [PATCH] * Makefile.in, configure.in: add, like, some *more* code for FreeBSD * tcp_sockets.c: include --- webcit/ChangeLog | 5 +++++ webcit/Makefile.in | 3 ++- webcit/configure.in | 3 +++ webcit/tcp_sockets.c | 1 + 4 files changed, 11 insertions(+), 1 deletion(-) diff --git a/webcit/ChangeLog b/webcit/ChangeLog index 1de4e31ee..63eec9c65 100644 --- a/webcit/ChangeLog +++ b/webcit/ChangeLog @@ -1,4 +1,8 @@ $Log$ +Revision 211.3 2000/02/11 23:45:04 nbryant +* Makefile.in, configure.in: add, like, some *more* code for FreeBSD +* tcp_sockets.c: include + Revision 211.2 2000/02/11 23:30:04 nbryant configure.in: added some code for FreeBSD @@ -378,3 +382,4 @@ Sun Dec 6 19:50:55 EST 1998 Art Cancro 1998-12-03 Nathan Bryant * webserver.c: warning fix + diff --git a/webcit/Makefile.in b/webcit/Makefile.in index 2cd30c9a6..7bd92c894 100644 --- a/webcit/Makefile.in +++ b/webcit/Makefile.in @@ -6,6 +6,7 @@ CFLAGS=@CFLAGS@ DEFS=@DEFS@ LIBOBJS=@LIBOBJS@ LIBS=@LIBS@ +PTHREAD_DEFS=@PTHREAD_DEFS@ srcdir=@srcdir@ # End of configuration section @@ -34,7 +35,7 @@ webserver: webserver.o context_loop.o tools.o \ $(LIBOBJS) $(LIBS) -o webserver .c.o: - $(CC) $(CFLAGS) $(DEFS) -c -D_REENTRANT -DWEBCITDIR=\"`pwd`\" $< + $(CC) $(CFLAGS) $(DEFS) -c $(PTHREAD_DEFS) -DWEBCITDIR=\"`pwd`\" $< Makefile: $(srcdir)/Makefile.in config.status CONFIG_FILES=Makefile CONFIG_HEADERS= $(SHELL) ./config.status diff --git a/webcit/configure.in b/webcit/configure.in index d0ce46ca4..f9cd9f1a9 100644 --- a/webcit/configure.in +++ b/webcit/configure.in @@ -6,6 +6,7 @@ AC_CANONICAL_HOST dnl Set some system-specific variables which are OK to set before compiler dnl checks: +PTHREAD_DEFS=-D_REENTRANT case "$host" in dnl Tru64 Unix requires we use -pthread instead of linking the threads dnl libraries directly, and we can't build threaded programs with gcc @@ -17,8 +18,10 @@ case "$host" in dnl FreeBSD is similar: *-*-freebsd*) LIBS=-pthread + PTHREAD_DEFS=-D_THREAD_SAFE ;; esac +AC_SUBST(PTHREAD_DEFS) dnl Checks for programs. AC_PROG_CC diff --git a/webcit/tcp_sockets.c b/webcit/tcp_sockets.c index 8aa050867..45de6d70f 100644 --- a/webcit/tcp_sockets.c +++ b/webcit/tcp_sockets.c @@ -19,6 +19,7 @@ #include #include #include +#include #include #include #include -- 2.39.2