sm-archive

changeset 10:f9e8bbf33a2a

more fixes for solaris
author carl
date Tue Jan 30 16:28:16 2007 -0800 (2007-01-30)
parents 48880e61ce5e
children 61a4e8773e2e
files ChangeLog Makefile.am Makefile.cvs NEWS configure.in src/Makefile.am src/sm-archive.cpp
line diff
     1.1 --- a/ChangeLog	Wed Jan 03 22:28:27 2007 -0800
     1.2 +++ b/ChangeLog	Tue Jan 30 16:28:16 2007 -0800
     1.3 @@ -1,5 +1,9 @@
     1.4      $Id$
     1.5  
     1.6 +1.3 2007-01-30
     1.7 +    More fixes for solaris, use an autoconf macro for posix thread
     1.8 +    detection.
     1.9 +
    1.10  1.2 2007-01-03
    1.11      Add patches to enable build on solaris.
    1.12  
     2.1 --- a/Makefile.am	Wed Jan 03 22:28:27 2007 -0800
     2.2 +++ b/Makefile.am	Tue Jan 30 16:28:16 2007 -0800
     2.3 @@ -1,9 +1,11 @@
     2.4 +ACLOCAL_AMFLAGS = -I m4
     2.5 +
     2.6  SUBDIRS = src man html info
     2.7  hackdir = $(sysconfdir)/sm-archive
     2.8  hack_SCRIPTS = sm-archive
     2.9  hack_DATA = sm-archive.conf
    2.10  CLEANFILES = sm-archive xml/sm-archive xml/Makefile
    2.11 -EXTRA_DIST = sm-archive.rc $(hack_DATA) sm-archive.spec $(wildcard xml/h*) $(wildcard xml/M*) $(wildcard xml/sm*)
    2.12 +EXTRA_DIST = sm-archive.rc $(hack_DATA) sm-archive.spec $(wildcard m4/*) $(wildcard xml/h*) $(wildcard xml/M*) $(wildcard xml/sm*)
    2.13  
    2.14  sm-archive: $(srcdir)/sm-archive.rc
    2.15  	   rm -f sm-archive
     3.1 --- a/Makefile.cvs	Wed Jan 03 22:28:27 2007 -0800
     3.2 +++ b/Makefile.cvs	Tue Jan 30 16:28:16 2007 -0800
     3.3 @@ -1,7 +1,7 @@
     3.4  default: all
     3.5  
     3.6  all:
     3.7 -	aclocal
     3.8 +	aclocal -I m4
     3.9  	autoheader
    3.10  	automake
    3.11  	autoconf
     4.1 --- a/NEWS	Wed Jan 03 22:28:27 2007 -0800
     4.2 +++ b/NEWS	Tue Jan 30 16:28:16 2007 -0800
     4.3 @@ -1,5 +1,6 @@
     4.4      $Id$
     4.5  
     4.6 +1.3  2007-01-30 more fixes for solaris
     4.7  1.2  2007-01-03 patches to build on solaris
     4.8  1.1  2006-12-22 better autoconf setup for portability
     4.9  1.0  2006-03-10 initial version
     5.1 --- a/configure.in	Wed Jan 03 22:28:27 2007 -0800
     5.2 +++ b/configure.in	Tue Jan 30 16:28:16 2007 -0800
     5.3 @@ -1,5 +1,5 @@
     5.4  AC_PREREQ(2.59)
     5.5 -AC_INIT(sm-archive,1.2,carl@five-ten-sg.com)
     5.6 +AC_INIT(sm-archive,1.3,carl@five-ten-sg.com)
     5.7  AC_CONFIG_SRCDIR([config.h.in])
     5.8  AC_CONFIG_HEADER([config.h])
     5.9  
    5.10 @@ -29,6 +29,9 @@
    5.11  AC_FUNC_STAT
    5.12  AC_CHECK_FUNCS([memset socket strchr strdup strncasecmp strtol daemon])
    5.13  
    5.14 +# check for posix threads
    5.15 +ACX_PTHREAD
    5.16 +
    5.17  AC_CONFIG_FILES([Makefile
    5.18                   sm-archive.spec
    5.19                   html/Makefile
     6.1 --- a/src/Makefile.am	Wed Jan 03 22:28:27 2007 -0800
     6.2 +++ b/src/Makefile.am	Tue Jan 30 16:28:16 2007 -0800
     6.3 @@ -6,9 +6,9 @@
     6.4  INCLUDES= $(all_includes)
     6.5  
     6.6  # the library search path.
     6.7 -smarchive_LDFLAGS = -pthread
     6.8 +smarchive_LDFLAGS = $(PTHREAD_CFLAGS) $(PTHREAD_LIBS)
     6.9  smarchive_LDADD   = $(all_libraries) -lmilter
    6.10  
    6.11  # default compile flags
    6.12 -smarchive_CXXFLAGS = -pthread
    6.13 +smarchive_CXXFLAGS = $(PTHREAD_CFLAGS)
    6.14  
     7.1 --- a/src/sm-archive.cpp	Wed Jan 03 22:28:27 2007 -0800
     7.2 +++ b/src/sm-archive.cpp	Tue Jan 30 16:28:16 2007 -0800
     7.3 @@ -45,7 +45,7 @@
     7.4  	#include "daemon.c"
     7.5  #endif
     7.6  
     7.7 -static char* smarchive_version="$Id$";
     7.8 +static const char* smarchive_version="$Id$";
     7.9  
    7.10  
    7.11  extern "C" {
    7.12 @@ -273,7 +273,7 @@
    7.13  //	and reload when needed. we also cleanup old
    7.14  //	configs whose reference count has gone to zero.
    7.15  //
    7.16 -void* config_loader(void *arg);
    7.17 +extern "C" {void* config_loader(void *arg);}
    7.18  void* config_loader(void *arg) {
    7.19  	typedef set<CONFIG *> configp_set;
    7.20  	configp_set old_configs;