[BACK]Return to Makefile CVS log [TXT][DIR] Up to [local] / src / usr.bin / make

File: [local] / src / usr.bin / make / Makefile (download)

Revision 1.23, Thu Sep 14 13:56:14 2000 UTC (23 years, 8 months ago) by espie
Branch: MAIN
CVS Tags: OPENBSD_2_8_BASE, OPENBSD_2_8
Changes since 1.22: +2 -2 lines

This kills the last old hashing table, in arch.c

Slight optimizations: instead of storing archive members, just keep
the modification time, as we don't care for the rest of the archive
information. Lazily compute mtime, stash ascii date instead, and convert
to mtime when needed (storing an out_of_date value to mark the unconverted
values).

Archive handling is atrocious and need some clean-up.

Thanks to miod@ who took the time to review those patches.

#	$OpenBSD: Makefile,v 1.23 2000/09/14 13:56:14 espie Exp $

PROG=	make
CFLAGS+= -I${.OBJDIR} -I${.CURDIR} -Wall -Wno-char-subscripts -Wstrict-prototypes

.if (${MACHINE_ARCH} == "m88k")
CFLAGS+=-O0
.endif

SRCS=	arch.c buf.c compat.c cond.c dir.c error.c for.c job.c lowparse.c \
	main.c make.c parse.c str.c suff.c targ.c var.c varmodifiers.c #util.c 
SRCS+=	lstAppend.c lstAtEnd.c lstAtFront.c lstClose.c lstConcat.c \
	lstConcatDestroy.c lstDeQueue.c lstDestroy.c lstDupl.c lstEnQueue.c \
	lstFindFrom.c lstForEachFrom.c \
	lstInit.c lstInsert.c lstIsAtEnd.c lstIsEmpty.c \
	lstMember.c lstNext.c lstOpen.c lstRemove.c lstReplace.c lstSucc.c
.PATH:	${.CURDIR}/lst.lib


make: libohash.a
.PATH:  ${.CURDIR}/ohash
CFLAGS+=-I${.CURDIR}/ohash
LDADD=-L${.OBJDIR} -lohash

LIBOBJS= hash_create_entry.o hash_delete.o hash_do.o hash_entries.o \
    hash_enum.o hash_init.o hash_interval.o \
    hash_lookup_interval.o hash_lookup_memory.o hash_lookup_string.o \
    hash_qlookup.o hash_qlookupi.o

libohash.a: ${LIBOBJS}
	rm -f $@
	ar cq $@ `lorder ${LIBOBJS}|tsort`
	ranlib $@

CLEANFILES+=generate hashconsts.h generate.o regress.o check

CLEANFILES+=${LIBOBJS} libohash.a
CLEANFILES+= hashconsts.h generate.o generate

beforedepend: hashconsts.h
# may need tweaking if you add variable synonyms or change the hash function
MAGICSLOTS=34

hashconsts.h: generate
	${.OBJDIR}/generate ${MAGICSLOTS} >${.TARGET}

generate: generate.o error.o libohash.a
	${CC} -o ${.TARGET} ${CFLAGS} ${.ALLSRC} ${LDADD}

check: regress.o str.o error.o buf.o libohash.a
	${CC} -o ${.TARGET} ${CFLAGS} ${.ALLSRC} ${LDADD}

regress: check
	${.OBJDIR}/check 

# kludge for people who forget to make depend
var.o: hashconsts.h

.if make(install)
SUBDIR+= PSD.doc
.endif

.include <bsd.prog.mk>