#
# makefile for PGPSendmail (SAS/C)
#
# created by Peter Simons <simons@peti.GUN.de>
#

# Labels:
# =======
#
SRC    = pgpsendmail.c rfcstuff.c expandalias.c system.c
OBJS   = pgpsendmail.o rfcstuff.o expandalias.o system.o


# Compiler flags:
# ===============
#
CFLAGS = PARAMETERS=REGISTERS DEBUG=FF STRINGMERGE NOCHECKABORT
#        NOSTKCHK OPTIMIZE OPTIMIZERINLINELOCAL OPTIMIZERSIZE


# Linker flags:
# =============
#
LFLAGS  = SMALLCODE SMALLDATA


#
# Targets
#
all:            PGPSendmail PGPSendmail.guide
        # default target

PGPSendmail.guide:      PGPSendmail.texinfo
        makeinfo --amiga-39 --fill-column 75 $*.texinfo

genproto:
        Delete protos.h
        sc $(SRC) GENPROTO NOGPTDEF GST LIB:Includes.gst
        Type \#?_protos.h >protos.h
        Delete \#?_protos.h

bump:
        SetEnv rev `Type PGPSendmail_rev.rev`
        MakeLogEntry \#?.c v2_$$rev
        bumprev 2 PGPSendmail
        @Delete PGPSendmail_rev.i QUIET
        SetEnv rev `Type PGPSendmail_rev.rev`
        Echo >>History "*n*n"
        Echo >>History "v2.$$rev:                  " NOLINE
        Date >>History
        UnSetEnv rev

install:        PGPSendmail
        slink PGPSendmail TO UUCPC:PGPSendmail NODEBUG


#
# Actions
#
.c.o:
        sc $(CFLAGS) $*.c GST LIB:Includes.gst


PGPSendmail:       $(OBJS)
        sc $(OBJS) TO PGPSendmail $(LFLAGS) LINK
        @Delete PGPSendmail.lnk


#
# Dependencies
#
cookie.o: cookie.c
expandalias.o: expandalias.c protos.h
pgpsendmail.o: pgpsendmail.c pgpsendmail.h protos.h pgpsendmail_rev.h
rfcstuff.o: rfcstuff.c protos.h pgpsendmail.h
system.o: system.c protos.h pgpsendmail.h

