home *** CD-ROM | disk | FTP | other *** search
Makefile | 1989-02-23 | 2.0 KB | 95 lines |
- # makefile for UNIX bplus test
-
- # Bplus routines, utility routines, and the whole library
- PLUSLIB = bplus.o find1stkey.o
- UTILLIB = filelen.o memmove.o
- LIB = $(PLUSLIB) $(UTILLIB)
- LIBSRC = bplus.c find1stkey.c filelen.c memmove.c
-
- TESTS = utest3 utest4 zoodb
- TESTOBJ = utest3.o utest4.o zoodb.o
- TESTSRC = utest3.c utest4.c s.zoodb.c
-
- DEMOSRC = ndb.c lookup.c names.c
-
- # C flags, load flags, misc (shared) flags
- CFLAGS = -O
- LFLAGS =
- MFLAGS =
- CC = cc $(CFLAGS) ${MFLAGS}
-
- # archive for distribution
- BPLUSARC = bplus11a.arc
-
- all: $(TESTS)
-
- $(TESTS): bplus.a $$@.o
- $(CC) $(LFLAGS) -o $@ $@.o bplus.a
-
- $(PLUSLIB): bplus.h
- $(TESTOBJ): bplus.h
-
- bplus.a: $(LIB)
- ar rv bplus.a $?
- ranlib bplus.a
-
- # special section to make libraries under Xenix386, for Xenix286 and MS-DOS
- extlib: $(LIBSRC) bplus.h
- @echo "Making x286 small"
- cc -c -O -M2 $(LIBSRC)
- ar rv Sbplus286.a $(LIB)
- ranlib Sbplus286.a
- @echo "Making x286 large"
- cc -c -O -M2l $(LIBSRC)
- ar rv Lbplus286.a $(LIB)
- ranlib Lbplus286.a
- @echo "Making DOS small"
- cc -c -O -M2 -dos $(LIBSRC)
- ar rv SbplusDOS.a $(LIB)
- ranlib SbplusDOS.a
- @echo "Making DOS large"
- cc -c -O -M2l -dos $(LIBSRC)
- ar rv LbplusDOS.a $(LIB)
- ranlib LbplusDOS.a
- @echo "Making 386 version"
- $(MAKE) bplus.a
- touch extlib
-
- .SUFFIXES: .exe
-
- # special inference rules, DOS and SCCS
- .o.exe:
- $(CC) -o $@ -dos $< bplus.a
- .c~.o:
- get -s $?
- $(CC) -c $*.c && rm -f $*.c
- .c.o:
- $(CC) -c $*.c
-
- MISCSAVE = bplus.h bplus.doc makefile read.me
- bplus.zoo: $(TESTSRC) $(LIBSRC) $(MISCSAVE) $(DEMOSRC)
- zoo aunPP bplus $?
-
- bplusarc: $(BPLUSARC)
-
- $(BPLUSARC): $(LIBSRC) $(MISCSAVE) $(DEMOSRC)
- rm -f $(BPLUSARC)
- arc a $(BPLUSARC) $(LIBSRC) $(MISCSAVE) $(DEMOSRC)
-
- shar: bplus.shar
- bplus.shar: $(LIBSRC) bplus.h
- $${SHAR:-shar} $(LIBSRC) bplus.h > bplus.shar
-
- # phone number database software
-
- PDBX = ndb lookup
- pdbx: $(PDBX) lookup.exe
-
- $(PDBX): bplus.a $$@.o
- cc $(MFLAGS) $(LFLAGS) -o $@ $@.o bplus.a
-
- lookup.exe: lookup.c
- $(CC) $(LFLAGS) -dos -o lookup.exe lookup.c bplus.a
-
- ndb.o lookup.o: bplus.h
-