LIBNAME=	libntp
#
# xntp routines which are used a lot of places
#
COMPILER= bsdcc
COPTS= -O
LIBDEFS=	-DBIG_ENDIAN -DRS6000
RANLIB=		ranlib # : ar does the work of ranlib under System V
#
INCL=-I../include
CFLAGS=	$(COPTS) $(LIBDEFS) $(INCL)
CC=		$(COMPILER)
#
SOURCE=	atoint.c atolfp.c atouint.c auth12crypt.c authdecrypt.c authdes.c \
	authencrypt.c authkeys.c authparity.c authreadkeys.c authusekey.c \
	buftvtots.c caljulian.c calleapwhen.c caltontp.c calyearstart.c \
	clocktime.c dofptoa.c dolfptoa.c emalloc.c fptoa.c fptoms.c getopt.c \
	gettstamp.c hextoint.c hextolfp.c humandate.c inttoa.c lfptoa.c \
	lfptoms.c lib_strbuf.c mfptoa.c mfptoms.c modetoa.c mstolfp.c \
	msutotsf.c ntoa.c ntohost.c numtoa.c numtohost.c octtoint.c \
	prettydate.c ranny.c tsftomsu.c tstotv.c tvtoa.c tvtots.c ufptoa.c \
	ufptoms.c uglydate.c uinttoa.c ulfptoa.c ulfptoms.c umfptoa.c \
	umfptoms.c utvtoa.c

OBJS=	atoint.o atolfp.o atouint.o auth12crypt.o authdecrypt.o authdes.o \
	authencrypt.o authkeys.o authparity.o authreadkeys.o authusekey.o \
	buftvtots.o caljulian.o calleapwhen.o caltontp.o calyearstart.o \
	clocktime.o dofptoa.o dolfptoa.o emalloc.o fptoa.o fptoms.o getopt.o \
	gettstamp.o hextoint.o hextolfp.o humandate.o inttoa.o lfptoa.o \
	lfptoms.o lib_strbuf.o mfptoa.o mfptoms.o modetoa.o mstolfp.o \
	msutotsf.o ntoa.o ntohost.o numtoa.o numtohost.o octtoint.o \
	prettydate.o ranny.o tsftomsu.o tstotv.o tvtoa.o tvtots.o ufptoa.o \
	ufptoms.o uglydate.o uinttoa.o ulfptoa.o ulfptoms.o umfptoa.o \
	umfptoms.o utvtoa.o

$(LIBNAME).a:	$(OBJS)
	ar rv $@ $?
	rm -f $?
	ranlib $@

lintlib:	llib-l$(LIBNAME).ln

llib-l$(LIBNAME).ln:	$(SOURCE)
	lint -C$(LIBNAME) $(INCL) *.c

lint:
	lint -u $(DEFS) $(INCL) $(SOURCE)

depend:
	mkdep $(CFLAGS) $(SOURCE)

clean:
	rm -f $(LIBNAME).a *.o *.out *.ln make.log Makefile.bak

