From 2243d8f2992cee440fc0b3f8bbccbbeb39cb2822 Mon Sep 17 00:00:00 2001 From: Nathan Bryant Date: Tue, 16 Oct 2001 01:48:55 +0000 Subject: [PATCH] - configury tweaks for a /usr/include/db3 goof and Digital/Tru64 Unix - #ifdef out inline on non-GCC compilers --- citadel/ChangeLog | 5 +++++ citadel/configure.ac | 7 +++---- citadel/server.h | 6 ++++++ citadel/sysdep.c | 2 +- citadel/sysdep_decls.h | 2 +- 5 files changed, 16 insertions(+), 6 deletions(-) diff --git a/citadel/ChangeLog b/citadel/ChangeLog index 2d494e41d..b545abbf1 100644 --- a/citadel/ChangeLog +++ b/citadel/ChangeLog @@ -1,4 +1,8 @@ $Log$ + Revision 580.58 2001/10/16 01:48:55 nbryant + - configury tweaks for a /usr/include/db3 goof and Digital/Tru64 Unix + - #ifdef out inline on non-GCC compilers + Revision 580.57 2001/10/15 19:50:50 ajc * Fixed a bug in the loopzapper that was corrupting the use table saved copy. * Post notification in Aide> when the loopzapper catches a message. @@ -2795,3 +2799,4 @@ Sat Jul 11 00:20:48 EDT 1998 Nathan Bryant Fri Jul 10 1998 Art Cancro * Initial CVS import + diff --git a/citadel/configure.ac b/citadel/configure.ac index fd622c3ce..41b853d20 100644 --- a/citadel/configure.ac +++ b/citadel/configure.ac @@ -63,11 +63,10 @@ case "$host" in dnl build pthreads programs with gcc due to header problems. alpha*-dec-osf*) test -z "$CC" && CC=cc - PTHREAD_DEFS=-pthread - PTHREAD_LIBS=-pthread + PTHREAD_LIBS="-lpthread -lexc" check_pthread=no ;; - dnl FreeBSD is similar to Digital UNIX: + dnl FreeBSD is similar to Digital UNIX with DEC C, which has a -pthread flag: *-*-freebsd*) if test "$with_kthread" = yes; then PTHREAD_LIBS=-kthread @@ -218,7 +217,7 @@ dnl Checks for header files. AC_HEADER_DIRENT AC_HEADER_STDC AC_HEADER_SYS_WAIT -test "$db_dir" && CPPFLAGS="$CPPFLAGS -I$db_dir/include" || test -d /usr/include/db3 && CPPFLAGS="$CPPFLAGS -I/usr/include/db3" +test "$db_dir" && CPPFLAGS="$CPPFLAGS -I$db_dir/include" || ( test -d /usr/include/db3 && CPPFLAGS="$CPPFLAGS -I/usr/include/db3" ) AC_CHECK_HEADERS(curses.h dl.h fcntl.h limits.h termios.h sys/ioctl.h sys/select.h sys/time.h syslog.h unistd.h utmp.h utmpx.h paths.h) AC_CHECK_HEADER(resolv.h, [SMTP=modules/libsmtp.la; DOMAIN=domain.c]) diff --git a/citadel/server.h b/citadel/server.h index c30b95254..f31ed063c 100644 --- a/citadel/server.h +++ b/citadel/server.h @@ -12,6 +12,12 @@ #ifndef SERVER_H #define SERVER_H +#ifdef __GNUC__ +#define INLINE inline +#else +#define INLINE +#endif + #ifdef __CYGWIN__ #ifdef IN_LIBCIT diff --git a/citadel/sysdep.c b/citadel/sysdep.c index 6a7722291..f1c933f8e 100644 --- a/citadel/sysdep.c +++ b/citadel/sysdep.c @@ -939,7 +939,7 @@ void init_master_fdset(void) { /* * Bind a thread to a context. (It's inline merely to speed things up.) */ -inline void become_session(struct CitContext *which_con) { +INLINE void become_session(struct CitContext *which_con) { pthread_setspecific(MyConKey, (void *)which_con ); } diff --git a/citadel/sysdep_decls.h b/citadel/sysdep_decls.h index f5c0febc5..fc977fe04 100644 --- a/citadel/sysdep_decls.h +++ b/citadel/sysdep_decls.h @@ -25,7 +25,7 @@ void start_daemon (int do_close_stdio); void cmd_nset (char *cmdbuf); int convert_login (char *NameToConvert); void *worker_thread (void *arg); -inline void become_session(struct CitContext *which_con); +void become_session(struct CitContext *which_con); void CtdlRedirectOutput(FILE *fp, int sock); void InitializeMasterCC(void); void init_master_fdset(void); -- 2.39.2