From 931e7a7b26ef44d7d06e1c05046073f472bdc5e2 Mon Sep 17 00:00:00 2001 From: dfs Date: Sat, 17 Jan 1998 03:58:26 +0000 Subject: [PATCH] -- Made source compatible with autoconf script. --- src/Makefile | 199 ------------------------------------------------ src/Makefile.in | 18 ++++- src/calendar.c | 7 +- src/config.h.in | 29 ++++++- src/dorem.c | 5 +- src/dosubst.c | 5 +- src/expr.c | 7 +- src/files.c | 24 +++--- src/funcs.c | 21 +++-- src/init.c | 25 +++--- src/main.c | 61 ++++++++------- src/moon.c | 3 +- src/omit.c | 5 +- src/protos.h | 10 +-- src/queue.c | 7 +- src/rem2ps.c | 12 ++- src/sort.c | 7 +- src/token.c | 5 +- src/trigger.c | 5 +- src/userfns.c | 7 +- src/utils.c | 9 ++- src/var.c | 7 +- 22 files changed, 188 insertions(+), 290 deletions(-) delete mode 100644 src/Makefile diff --git a/src/Makefile b/src/Makefile deleted file mode 100644 index 7b150cc3..00000000 --- a/src/Makefile +++ /dev/null @@ -1,199 +0,0 @@ -# Makefile for REMIND -# $Id: Makefile,v 1.1 1998-01-15 02:50:24 dfs Exp $ - -#----------------------------------------------------------------------------- -# THINGS FOR YOU TO EDIT START BELOW -#----------------------------------------------------------------------------- - -# Uncomment the next line if you are running on a SYSV system -SYSV= -DSYSV - -# Uncomment the next line if you are running under UNIX (including SYSV!) -UNIX= -DUNIX - -# Uncomment the next lines if you want to use gcc instead of default compiler -# NOTE: Tempting as it may be, if you use 'cc' for the C compiler, do not -# use 'ld' for the linker. It will probably work much better if you use -# LD= cc rather than LD= ld. -CC= gcc -LD= gcc - -# Put any additional flags for the C compiler or linker here - if you -# are not using gcc, you probably want to remove '-ansi -pedantic -Wall'. -CFLAGS= -O -ansi -pedantic -Wall -CDEFS= -LDFLAGS= - -#### INSTALLATION LOCATIONS #### -# Note that I use 'cp' rather than 'install' for improved portability. -# -# BINDIR: Where should the Remind executable be installed? -BINDIR= /usr/local/bin - -# SCRIPTDIR: Where should the kall and rem shell scripts be installed? -SCRIPTDIR= /usr/local/bin - -# MANDIR: Where should the man pages be installed? -MANDIR= /usr/local/man - -# MANSECT: Which man section should the man pages go into? -MANSECT= 1 - -# EXEMODE: What file protection mode should be used for the executables? -EXEMODE= 755 - -# MANMODE: What file protection mode should be used for the man pages? -MANMODE= 644 - -# OWNER, GROUP: What owner and group to use for executables, -# scripts and man pages? -OWNER=bin -GROUP=bin - -#----------------------------------------------------------------------------- -# YOU SHOULDN'T EDIT ANYTHING BELOW HERE. You may want to change some things -# in config.h; then, you should be able to type 'make'. -#----------------------------------------------------------------------------- -VERSION= 03.00.18 -MATHLIB= -lm - -HDRS= config.h err.h expr.h globals.h protos.h types.h version.h \ -lang.h english.h german.h dutch.h finnish.h french.h norwgian.h \ -danish.h polish.h romanian.h - -STDHDRS= config.h types.h protos.h globals.h err.h lang.h - -LANGHDRS= english.h german.h dutch.h finnish.h french.h norwgian.h danish.h \ -polish.h portbr.h italian.h romanian.h - -SRCS= calendar.c dorem.c dosubst.c expr.c files.c funcs.c globals.c hbcal.c \ -init.c main.c moon.c omit.c sort.c queue.c token.c trigger.c userfns.c \ -utils.c var.c - -MANIFEST=COPYRIGHT Makefile Makefile_QDOS README.AMIGA README.BCC \ -README.DOS README.OS2 README.UNIX README_QDOS WHATSNEW.30 \ -amiga-SCOPTIONS amiga.c calendar.c config.h danish.h defs.rem dorem.c \ -dosubst.c dutch.h english.h err.h expr.c expr.h files.c finnish.h \ -french.h funcs.c german.h globals.c globals.h hbcal.c init.c italian.h kall \ -kall.1 lang.h lnk.bcc lnk.msc lnk.tc main.c makefile.bcc makefile.msc \ -makefile.os2 makefile.tc moon.c norwgian.h omit.c os2func.c polish.h \ -protos.h queue.c rem rem.1 rem2ps.1 rem2ps.c rem2ps.h remind-all.csh \ -remind-all.sh remind.1 remind.def smakefile sort.c test-rem \ -test-rem.ami test-rem.bat test-rem.cmd test-rem.rexx test.cmp test.rem \ -test1.cmp test2.cmp tkremind tkremind.1 token.c trigger.c tstlang.rem \ -types.h userfns.c utils.c var.c version.h remind.LSM portbr.h romanian.h - -OBJS= $(SRCS:.c=.o) - -all: remind rem2ps - -.c.o: - $(CC) $(UNIX) $(SYSV) -c $(CFLAGS) $(CDEFS) $*.c - -rem2ps: rem2ps.o - $(LD) $(LDFLAGS) -o rem2ps rem2ps.o - -remind: $(OBJS) - $(LD) $(LDFLAGS) -o remind $(OBJS) $(MATHLIB) - -clean: - rm -f *.o *~ core *.bak - -clobber: - rm -f *.o *~ remind rem2ps test.out core *.bak - -test: remind - sh test-rem - -rem2ps.o: rem2ps.c rem2ps.h lang.h config.h -calendar.o: calendar.c $(STDHDRS) expr.h -dorem.o: dorem.c $(STDHDRS) expr.h -dosubst.o: dosubst.c $(STDHDRS) $(LANGHDRS) -expr.o: expr.c $(STDHDRS) expr.h -files.o: files.c $(STDHDRS) -funcs.o: funcs.c $(STDHDRS) expr.h version.h -globals.o: globals.c config.h types.h globals.h err.h lang.h $(LANGHDRS) -hbcal.o: hbcal.c $(STDHDRS) -init.o: init.c $(STDHDRS) expr.h version.h lang.h $(LANGHDRS) -main.o: main.c $(STDHDRS) expr.h -moon.o: moon.c $(STDHDRS) -omit.o: omit.c $(STDHDRS) -sort.o: sort.c $(STDHDRS) -queue.o: queue.c $(STDHDRS) -token.o: token.c $(STDHDRS) -trigger.o: trigger.c $(STDHDRS) expr.h -userfns.o: userfns.c $(STDHDRS) expr.h -utils.o: utils.c $(STDHDRS) -var.o: var.c $(STDHDRS) expr.h - -# Some of these targets are just for my convenience and -# probably won't be too useful to you! -- dfs - -tgz: - -rm -rf remind-$(VERSION) - -mkdir remind-$(VERSION) - cd remind-$(VERSION); for i in www $(MANIFEST) ;do ln -s ../$$i .; done; cd .. - tar --exclude CVS -c -h -v -f remind-3.0.18.tar remind-$(VERSION) - gzip -v -9 remind-3.0.18.tar - mv remind-3.0.18.tar.gz remind-3.0.18.tgz - rm -rf remind-$(VERSION) - -shar: - shar -o./Shar -sdfs@doe.carleton.ca -a -c -n"Remind $(VERSION)" -m -l58 -o./Shar www $(MANIFEST) - -backup: - tar cvzf ../rbackup.tgz www $(MANIFEST) - -zip: - zip ../rbackup.zip www $(MANIFEST) - -transmit: - sz -a -e $(MANIFEST) www/* - -install: install-bin install-scripts install-man - -install-bin: remind rem2ps - cp remind $(BINDIR)/remind - -chmod $(EXEMODE) $(BINDIR)/remind - -chown $(OWNER) $(BINDIR)/remind - -chgrp $(GROUP) $(BINDIR)/remind - cp rem2ps $(BINDIR)/rem2ps - -chmod $(EXEMODE) $(BINDIR)/rem2ps - -chown $(OWNER) $(BINDIR)/rem2ps - -chgrp $(GROUP) $(BINDIR)/rem2ps - -install-scripts: - cp kall $(SCRIPTDIR)/kall - -chmod $(EXEMODE) $(SCRIPTDIR)/kall - -chown $(OWNER) $(SCRIPTDIR)/kall - -chgrp $(GROUP) $(SCRIPTDIR)/kall - cp rem $(SCRIPTDIR)/rem - -chmod $(EXEMODE) $(SCRIPTDIR)/rem - -chown $(OWNER) $(SCRIPTDIR)/rem - -chgrp $(GROUP) $(SCRIPTDIR)/rem - cp tkremind $(SCRIPTDIR)/tkremind - -chmod $(EXEMODE) $(SCRIPTDIR)/tkremind - -chown $(OWNER) $(SCRIPTDIR)/tkremind - -chgrp $(GROUP) $(SCRIPTDIR)/tkremind - -install-man: - cp remind.1 $(MANDIR)/man$(MANSECT)/remind.$(MANSECT) - -chmod $(MANMODE) $(MANDIR)/man$(MANSECT)/remind.$(MANSECT) - -chown $(OWNER) $(MANDIR)/man$(MANSECT)/remind.$(MANSECT) - -chgrp $(GROUP) $(MANDIR)/man$(MANSECT)/remind.$(MANSECT) - cp tkremind.1 $(MANDIR)/man$(MANSECT)/tkremind.$(MANSECT) - -chmod $(MANMODE) $(MANDIR)/man$(MANSECT)/tkremind.$(MANSECT) - -chown $(OWNER) $(MANDIR)/man$(MANSECT)/tkremind.$(MANSECT) - -chgrp $(GROUP) $(MANDIR)/man$(MANSECT)/tkremind.$(MANSECT) - cp rem.1 $(MANDIR)/man$(MANSECT)/rem.$(MANSECT) - -chmod $(MANMODE) $(MANDIR)/man$(MANSECT)/rem.$(MANSECT) - -chown $(OWNER) $(MANDIR)/man$(MANSECT)/rem.$(MANSECT) - -chgrp $(GROUP) $(MANDIR)/man$(MANSECT)/rem.$(MANSECT) - cp kall.1 $(MANDIR)/man$(MANSECT)/kall.$(MANSECT) - -chmod $(MANMODE) $(MANDIR)/man$(MANSECT)/kall.$(MANSECT) - -chown $(OWNER) $(MANDIR)/man$(MANSECT)/kall.$(MANSECT) - -chgrp $(GROUP) $(MANDIR)/man$(MANSECT)/kall.$(MANSECT) - cp rem2ps.1 $(MANDIR)/man$(MANSECT)/rem2ps.$(MANSECT) - -chmod $(MANMODE) $(MANDIR)/man$(MANSECT)/rem2ps.$(MANSECT) - -chown $(OWNER) $(MANDIR)/man$(MANSECT)/rem2ps.$(MANSECT) - -chgrp $(GROUP) $(MANDIR)/man$(MANSECT)/rem2ps.$(MANSECT) diff --git a/src/Makefile.in b/src/Makefile.in index c682719b..6c631cd8 100644 --- a/src/Makefile.in +++ b/src/Makefile.in @@ -1,10 +1,16 @@ # Makefile.in for REMIND # -# $Id: Makefile.in,v 1.1 1998-01-15 03:28:39 dfs Exp $ +# $Id: Makefile.in,v 1.2 1998-01-17 03:58:26 dfs Exp $ VERSION= 03.00.18 SHELL= /bin/sh +prefix=@prefix@ +exec_prefix=@exec_prefix@ +mandir=@mandir@ +bindir=@bindir@ +datadir=@datadir@ + .SUFFIXES: .SUFFIXES: .c .o @@ -34,6 +40,16 @@ clobber: depend: gccmakedep @DEFS@ -DUNIX $(REMINDSRCS) rem2ps.c +# The next targets are not very useful to you. I use them to build +# distributions, etc. + +# Build a tar file based on all files checked into CVS. +tgz: + ln -s .. remind-$(VERSION) + peekentry `find remind-$(VERSION) -depth -follow -name 'Entries' -print` | xargs tar cvf remind-$(VERSION).tar + gzip -v -9 remind-$(VERSION).tar + mv remind-$(VERSION).tar.gz remind-$(VERSION).tgz + rm -f remind-$(VERSION) #---------------- Stuff after this added by "make depend" ----------------- diff --git a/src/calendar.c b/src/calendar.c index d847690c..c5ac6827 100644 --- a/src/calendar.c +++ b/src/calendar.c @@ -10,17 +10,20 @@ /***************************************************************/ #include "config.h" -static char const RCSID[] = "$Id: calendar.c,v 1.1 1998-01-15 02:50:25 dfs Exp $"; +static char const RCSID[] = "$Id: calendar.c,v 1.2 1998-01-17 03:58:27 dfs Exp $"; #include #include +#include + #ifdef HAVE_STDLIB_H #include #endif + #ifdef HAVE_MALLOC_H #include #endif -#include + #include "types.h" #include "protos.h" #include "expr.h" diff --git a/src/config.h.in b/src/config.h.in index 0efa3fde..a88d9417 100644 --- a/src/config.h.in +++ b/src/config.h.in @@ -1,11 +1,13 @@ -/* config.h.in. Generated automatically from configure.in by autoheader. */ -/* Edited by running "configure" to create config.h automagically */ +/* src/config.h.in. Generated automatically from configure.in by autoheader. */ -/* $Id: config.h.in,v 1.1 1998-01-15 02:50:25 dfs Exp $ */ +/* $Id: config.h.in,v 1.2 1998-01-17 03:58:27 dfs Exp $ */ /* Define to empty if the keyword does not work. */ #undef const +/* Define to `int' if doesn't define. */ +#undef gid_t + /* Define if you don't have vprintf but do have _doprnt. */ #undef HAVE_DOPRNT @@ -15,15 +17,24 @@ /* Define if you have the vprintf function. */ #undef HAVE_VPRINTF +/* Define to `int' if doesn't define. */ +#undef pid_t + /* Define as the return type of signal handlers (int or void). */ #undef RETSIGTYPE /* Define if you have the ANSI C header files. */ #undef STDC_HEADERS +/* Define if you can safely include both and . */ +#undef TIME_WITH_SYS_TIME + /* Define if your declares struct tm. */ #undef TM_IN_SYS_TIME +/* Define to `int' if doesn't define. */ +#undef uid_t + /* Define if you have the mktime function. */ #undef HAVE_MKTIME @@ -33,18 +44,30 @@ /* Define if you have the strstr function. */ #undef HAVE_STRSTR +/* Define if you have the timegm function. */ +#undef HAVE_TIMEGM + +/* Define if you have the header file. */ +#undef HAVE_PWD_H + /* Define if you have the header file. */ #undef HAVE_MALLOC_H /* Define if you have the header file. */ #undef HAVE_STDARG_H +/* Define if you have the header file. */ +#undef HAVE_STDLIB_H + /* Define if you have the header file. */ #undef HAVE_SYS_FILE_H /* Define if you have the header file. */ #undef HAVE_SYS_TIME_H +/* Define if you have the header file. */ +#undef HAVE_SYS_TYPES_H + /* Define if you have the header file. */ #undef HAVE_UNISTD_H diff --git a/src/dorem.c b/src/dorem.c index e81c4037..0dd3ec60 100644 --- a/src/dorem.c +++ b/src/dorem.c @@ -12,17 +12,20 @@ /***************************************************************/ #include "config.h" -static char const RCSID[] = "$Id: dorem.c,v 1.1 1998-01-15 02:50:26 dfs Exp $"; +static char const RCSID[] = "$Id: dorem.c,v 1.2 1998-01-17 03:58:27 dfs Exp $"; #include #include #include + #ifdef HAVE_STDLIB_H #include #endif + #ifdef HAVE_MALLOC_H #include #endif + #include "globals.h" #include "err.h" #include "types.h" diff --git a/src/dosubst.c b/src/dosubst.c index cffa5996..eb956f1d 100644 --- a/src/dosubst.c +++ b/src/dosubst.c @@ -11,18 +11,21 @@ /***************************************************************/ #include "config.h" -static char const RCSID[] = "$Id: dosubst.c,v 1.1 1998-01-15 02:50:26 dfs Exp $"; +static char const RCSID[] = "$Id: dosubst.c,v 1.2 1998-01-17 03:58:28 dfs Exp $"; #define L_IN_DOSUBST #include #include #include + #ifdef HAVE_STDLIB_H #include #endif + #ifdef HAVE_MALLOC_H #include #endif + #include "globals.h" #include "err.h" #include "types.h" diff --git a/src/expr.c b/src/expr.c index 90931cb1..295f97dd 100644 --- a/src/expr.c +++ b/src/expr.c @@ -10,17 +10,20 @@ /***************************************************************/ #include "config.h" -static char const RCSID[] = "$Id: expr.c,v 1.1 1998-01-15 02:50:27 dfs Exp $"; +static char const RCSID[] = "$Id: expr.c,v 1.2 1998-01-17 03:58:28 dfs Exp $"; #include #include #include + #ifdef HAVE_STDLIB_H #include #endif + #ifdef HAVE_MALLOC_H #include #endif + #include "err.h" #include "types.h" #include "expr.h" @@ -265,7 +268,7 @@ char **in; /* Put the result into value pointed to by v. */ /* */ /***************************************************************/ -#ifdef HaveProtos +#ifdef HAVE_PROTOS PUBLIC int EvalExpr(char **e, Value *v) #else int EvalExpr(e, v) diff --git a/src/files.c b/src/files.c index 40db59c9..1f65bd0d 100644 --- a/src/files.c +++ b/src/files.c @@ -12,22 +12,28 @@ /***************************************************************/ #include "config.h" -static char const RCSID[] = "$Id: files.c,v 1.1 1998-01-15 02:50:27 dfs Exp $"; +static char const RCSID[] = "$Id: files.c,v 1.2 1998-01-17 03:58:28 dfs Exp $"; #include -#ifdef HAVE_STDLIB_H -#include -#endif -#ifdef HAVE_MALLOC_H -#include -#endif + #include #include -#include #include #include -#ifdef HAVE_UNISTD +#ifdef HAVE_SYS_TYPES_H +#include +#endif + +#ifdef HAVE_STDLIB_H +#include +#endif + +#ifdef HAVE_MALLOC_H +#include +#endif + +#ifdef HAVE_UNISTD_H #include #endif diff --git a/src/funcs.c b/src/funcs.c index 961a0e69..ecb93ffb 100644 --- a/src/funcs.c +++ b/src/funcs.c @@ -11,39 +11,50 @@ /***************************************************************/ #include "config.h" -static char const RCSID[] = "$Id: funcs.c,v 1.1 1998-01-15 02:50:28 dfs Exp $"; +static char const RCSID[] = "$Id: funcs.c,v 1.2 1998-01-17 03:58:29 dfs Exp $"; #include + #ifdef HAVE_STDLIB_H #include #endif + #ifdef HAVE_MALLOC_H #include #endif + #include #include #include -#ifdef UNIX -#ifdef HAVE_UNISTD + +#ifdef HAVE_UNISTD_H #include -#else +#endif + +#ifdef HAVE_SYS_FILE_H #include #endif -#endif + +#ifdef HAVE_SYS_TYPES_H #include +#endif + #include #include + #if defined(__MSDOS__) || defined(__OS2__) #include #define R_OK 4 #define W_OK 2 #define X_OK 1 #endif + #ifndef R_OK #define R_OK 4 #define W_OK 2 #define X_OK 1 #endif + #include "types.h" #include "globals.h" #include "protos.h" diff --git a/src/init.c b/src/init.c index 807a1996..38a11fdd 100644 --- a/src/init.c +++ b/src/init.c @@ -12,25 +12,33 @@ /***************************************************************/ #include "config.h" -static char const RCSID[] = "$Id: init.c,v 1.1 1998-01-15 02:50:30 dfs Exp $"; +static char const RCSID[] = "$Id: init.c,v 1.2 1998-01-17 03:58:29 dfs Exp $"; #define L_IN_INIT 1 #include #include +#include + #ifdef HAVE_STDLIB_H #include #endif + #ifdef HAVE_MALLOC_H #include #endif -#ifdef UNIX + +#ifdef HAVE_SYS_TYPES_H #include +#endif + +#ifdef HAVE_PWD_H #include -#ifdef HAVE_UNISTD +#endif + +#ifdef HAVE_UNISTD_H #include #endif -#endif -#include + #include "types.h" #include "protos.h" #include "expr.h" @@ -517,12 +525,7 @@ static void ChgUser(user) char *user; #endif /* HAVE_PROTOS */ { -#ifdef SYSV - /* uid_t myuid; This seems to mess up on XENIX, so forget it... */ - int myuid; -#else - int myuid; -#endif + uid_t myuid; struct passwd *pwent; static char *home, *shell, *username, *logname; diff --git a/src/main.c b/src/main.c index a851dbae..4d6da570 100644 --- a/src/main.c +++ b/src/main.c @@ -11,44 +11,54 @@ /***************************************************************/ #include "config.h" -static char const RCSID[] = "$Id: main.c,v 1.1 1998-01-15 02:50:31 dfs Exp $"; +static char const RCSID[] = "$Id: main.c,v 1.2 1998-01-17 03:58:30 dfs Exp $"; #ifdef HAVE_STDLIB_H #include #endif + #ifdef HAVE_MALLOC_H #include #endif -#ifdef HAVE_UNISTD + +#ifdef HAVE_UNISTD_H #include #endif + #include #include #include -#ifdef HAVE_STDARG + +#ifdef HAVE_STDARG_H #include #else #include #endif + #include +#ifdef TIME_WITH_SYS_TIME #include +#include +#else +#ifdef HAVE_SYS_TIME_H +#include +#else +#include +#endif +#endif #ifdef AMIGA #include -#else +#endif + #if defined(__MSDOS__) || defined(__OS2__) #include -#else +#endif + +#ifdef HAVE_SYS_TYPES_H #include -#ifndef SYSV -#ifdef QDOS -#include -#else -#include -#endif /* QDOS */ -#endif /* ndef SYSV */ -#endif /* if defined(__MSDOS__)... */ -#endif /* AMIGA */ +#endif + #include "types.h" #include "protos.h" #include "expr.h" @@ -57,7 +67,7 @@ static char const RCSID[] = "$Id: main.c,v 1.1 1998-01-15 02:50:31 dfs Exp $"; PRIVATE void DoReminders ARGS ((void)); -#if defined(NEED_TIMEGM) && !defined(HAVE_MKTIME) +#if !defined(HAVE_TIMEGM) && !defined(HAVE_MKTIME) PRIVATE long time_cheat ARGS ((int year, int month)); long timegm ARGS((struct tm *tm)); long timelocal ARGS((struct tm *tm)); @@ -598,7 +608,7 @@ Value *v; /* Eprint - print an error message. */ /* */ /***************************************************************/ -#ifdef HAVE_STDARG +#ifdef HAVE_STDARG_H #ifdef HAVE_PROTOS PUBLIC void Eprint(const char *fmt, ...) #else @@ -612,7 +622,7 @@ va_dcl #endif { va_list argptr; -#ifndef HAVE_STDARG +#ifndef HAVE_STDARG_H char *fmt; #endif @@ -628,7 +638,7 @@ va_dcl if (DebugFlag & DB_PRTLINE) OutputLine(ErrFp); } else fprintf(ErrFp, " "); -#ifdef HAVE_STDARG +#ifdef HAVE_STDARG_H va_start(argptr, fmt); #else va_start(argptr); @@ -636,7 +646,7 @@ va_dcl #endif (void) vfprintf(ErrFp, fmt, argptr); (void) fputc('\n', ErrFp); -#ifndef HAVE_STDARG +#ifndef HAVE_STDARG_H va_end(argptr); #endif return; @@ -1380,7 +1390,7 @@ char *s; } } -#if defined(NEED_TIMEGM) && !defined(HAVE_MKTIME) +#if !defined(HAVE_TIMEGM) && !defined(HAVE_MKTIME) #define TGM_SEC (1) #define TGM_MIN (60 * TGM_SEC) #define TGM_HR (60 * TGM_MIN) @@ -1537,26 +1547,19 @@ int utcdate, utctime, *locdate, *loctime; void __cdecl SigIntHandler(int d) #else #ifdef HAVE_PROTOS -#ifdef SIGHANDLER_INT_ARG -void SigIntHandler(int d) +RETSIGTYPE SigIntHandler(int d) #else -void SigIntHandler(void) -#endif -#else -void SigIntHandler() +RETSIGTYPE SigIntHandler() #endif #endif { -#ifdef SYSV signal(SIGINT, SigIntHandler); -#else #ifdef __BORLANDC__ signal(SIGINT, SIG_DFL); #else #ifdef __OS2__ signal(SIGINT, SIG_ACK); #endif -#endif #endif GotSigInt(); diff --git a/src/moon.c b/src/moon.c index 1d83ef31..9fee22ff 100644 --- a/src/moon.c +++ b/src/moon.c @@ -10,7 +10,7 @@ /***************************************************************/ #include "config.h" -static char const RCSID[] = "$Id: moon.c,v 1.1 1998-01-15 02:50:33 dfs Exp $"; +static char const RCSID[] = "$Id: moon.c,v 1.2 1998-01-17 03:58:30 dfs Exp $"; /* All of these routines were adapted from the program "moontool" by John Walker, February 1988. Here's the blurb from moontool: @@ -63,6 +63,7 @@ static char const RCSID[] = "$Id: moon.c,v 1.1 1998-01-15 02:50:33 dfs Exp $"; #ifdef HAVE_STDLIB_H #include #endif + #include #include #include diff --git a/src/omit.c b/src/omit.c index 3091753d..92da0199 100644 --- a/src/omit.c +++ b/src/omit.c @@ -11,15 +11,18 @@ /***************************************************************/ #include "config.h" -static char const RCSID[] = "$Id: omit.c,v 1.1 1998-01-15 02:50:34 dfs Exp $"; +static char const RCSID[] = "$Id: omit.c,v 1.2 1998-01-17 03:58:31 dfs Exp $"; #include + #ifdef HAVE_STDLIB_H #include #endif + #ifdef HAVE_MALLOC_H #include #endif + #include "types.h" #include "protos.h" #include "globals.h" diff --git a/src/protos.h b/src/protos.h index 41fcc355..cf496a31 100644 --- a/src/protos.h +++ b/src/protos.h @@ -9,7 +9,7 @@ /* */ /***************************************************************/ -/* $Id: protos.h,v 1.1 1998-01-15 02:50:34 dfs Exp $ */ +/* $Id: protos.h,v 1.2 1998-01-17 03:58:31 dfs Exp $ */ #ifdef HAVE_PROTOS #define ARGS(x) x @@ -23,7 +23,7 @@ /* Define a general malloc routine for creating pointers to objects */ #define NEW(type) ((type *) malloc(sizeof(type))) -#ifdef NO_STRSTR +#ifndef HAVE_STRSTR char *strstr ARGS ((char *s1, char *s2)); #endif @@ -151,11 +151,7 @@ int CompareRems ARGS ((int dat1, int tim1, int prio1, int dat2, int tim2, int pr #ifdef __BORLANDC__ void __cdecl SigIntHandler ARGS ((int d)); #else -#ifdef SIGHANDLER_INT_ARG -void SigIntHandler ARGS ((int d)); -#else -void SigIntHandler ARGS ((void)); -#endif +RETSIGTYPE SigIntHandler ARGS ((int d)); #endif void GotSigInt ARGS ((void)); diff --git a/src/queue.c b/src/queue.c index e7e5f05b..b12918fd 100644 --- a/src/queue.c +++ b/src/queue.c @@ -10,7 +10,7 @@ /***************************************************************/ #include "config.h" -static char const RCSID[] = "$Id: queue.c,v 1.1 1998-01-15 02:50:34 dfs Exp $"; +static char const RCSID[] = "$Id: queue.c,v 1.2 1998-01-17 03:58:31 dfs Exp $"; /* We only want object code generated if we have queued reminders */ #ifdef HAVE_QUEUED @@ -19,13 +19,16 @@ static char const RCSID[] = "$Id: queue.c,v 1.1 1998-01-15 02:50:34 dfs Exp $"; #include #include #include + #ifdef HAVE_STDLIB_H #include #endif + #ifdef HAVE_MALLOC_H #include #endif -#ifdef HAVE_UNISTD + +#ifdef HAVE_UNISTD_H #include #endif diff --git a/src/rem2ps.c b/src/rem2ps.c index 005d0fc8..3259e4cf 100644 --- a/src/rem2ps.c +++ b/src/rem2ps.c @@ -10,20 +10,21 @@ /***************************************************************/ #include "config.h" -static char const RCSID[] = "$Id: rem2ps.c,v 1.1 1998-01-15 02:50:35 dfs Exp $"; +static char const RCSID[] = "$Id: rem2ps.c,v 1.2 1998-01-17 03:58:32 dfs Exp $"; #include "lang.h" #include #include #include -#ifdef HAVE_UNISTD + +#ifdef HAVE_UNISTD_H #include #endif -#include "rem2ps.h" -#include "version.h" + #ifdef HAVE_MALLOC_H #include #endif + #ifdef HAVE_STDLIB_H #include #endif @@ -32,6 +33,9 @@ static char const RCSID[] = "$Id: rem2ps.c,v 1.1 1998-01-15 02:50:35 dfs Exp $"; #include #endif +#include "rem2ps.h" +#include "version.h" + #ifdef HAVE_PROTOS #define ARGS(x) x #else diff --git a/src/sort.c b/src/sort.c index 36882416..84684022 100644 --- a/src/sort.c +++ b/src/sort.c @@ -10,7 +10,10 @@ /***************************************************************/ #include "config.h" -static char const RCSID[] = "$Id: sort.c,v 1.1 1998-01-15 02:50:36 dfs Exp $"; +static char const RCSID[] = "$Id: sort.c,v 1.2 1998-01-17 03:58:33 dfs Exp $"; + +#include +#include #ifdef HAVE_STDLIB_H #include @@ -20,8 +23,6 @@ static char const RCSID[] = "$Id: sort.c,v 1.1 1998-01-15 02:50:36 dfs Exp $"; #include #endif -#include -#include #include "types.h" #include "protos.h" #include "expr.h" diff --git a/src/token.c b/src/token.c index 7e6a5169..3dc6e866 100644 --- a/src/token.c +++ b/src/token.c @@ -11,17 +11,20 @@ /***************************************************************/ #include "config.h" -static char const RCSID[] = "$Id: token.c,v 1.1 1998-01-15 02:50:36 dfs Exp $"; +static char const RCSID[] = "$Id: token.c,v 1.2 1998-01-17 03:58:33 dfs Exp $"; #include #include #include + #ifdef HAVE_STDLIB_H #include #endif + #ifdef HAVE_MALLOC_H #include #endif + #include "types.h" #include "globals.h" #include "protos.h" diff --git a/src/trigger.c b/src/trigger.c index f1254415..f5ca642e 100644 --- a/src/trigger.c +++ b/src/trigger.c @@ -10,15 +10,18 @@ /***************************************************************/ #include "config.h" -static char const RCSID[] = "$Id: trigger.c,v 1.1 1998-01-15 02:50:37 dfs Exp $"; +static char const RCSID[] = "$Id: trigger.c,v 1.2 1998-01-17 03:58:33 dfs Exp $"; #include + #ifdef HAVE_STDLIB_H #include #endif + #ifdef HAVE_MALLOC_H #include #endif + #include "types.h" #include "expr.h" #include "protos.h" diff --git a/src/userfns.c b/src/userfns.c index 535800a3..b24b8064 100644 --- a/src/userfns.c +++ b/src/userfns.c @@ -11,16 +11,19 @@ /***************************************************************/ #include "config.h" -static char const RCSID[] = "$Id: userfns.c,v 1.1 1998-01-15 02:50:37 dfs Exp $"; +static char const RCSID[] = "$Id: userfns.c,v 1.2 1998-01-17 03:58:34 dfs Exp $"; #include +#include + #ifdef HAVE_STDLIB_H #include #endif + #ifdef HAVE_MALLOC_H #include #endif -#include + #include "types.h" #include "globals.h" #include "protos.h" diff --git a/src/utils.c b/src/utils.c index fd7c68cd..c097f80f 100644 --- a/src/utils.c +++ b/src/utils.c @@ -10,17 +10,20 @@ /***************************************************************/ #include "config.h" -static char const RCSID[] = "$Id: utils.c,v 1.1 1998-01-15 02:50:37 dfs Exp $"; +static char const RCSID[] = "$Id: utils.c,v 1.2 1998-01-17 03:58:34 dfs Exp $"; #include #include +#include + #ifdef HAVE_STDLIB_H #include #endif + #ifdef HAVE_MALLOC_H #include #endif -#include + #include "types.h" #include "globals.h" #include "protos.h" @@ -139,7 +142,7 @@ char *s1, *s2; return UPPER(*s1) - UPPER(*s2); } -#ifdef NO_STRSTR +#ifndef HAVE_STRSTR #ifdef HAVE_PROTOS PUBLIC char *strstr(char *s1, char *s2) #else diff --git a/src/var.c b/src/var.c index 9251b5f5..1aaa276c 100644 --- a/src/var.c +++ b/src/var.c @@ -11,17 +11,20 @@ /***************************************************************/ #include "config.h" -static char const RCSID[] = "$Id: var.c,v 1.1 1998-01-15 02:50:38 dfs Exp $"; +static char const RCSID[] = "$Id: var.c,v 1.2 1998-01-17 03:58:34 dfs Exp $"; #include #include +#include + #ifdef HAVE_STDLIB_H #include #endif + #ifdef HAVE_MALLOC_H #include #endif -#include + #include "types.h" #include "expr.h" #include "globals.h"