Commit | Line | Data |
---|---|---|
64d06f2f | 1 | # |
568afd31 KB |
2 | # Copyright (c) 1987 Regents of the University of California. |
3 | # All rights reserved. The Berkeley software License Agreement | |
4 | # specifies the terms and conditions for redistribution. | |
64d06f2f | 5 | # |
c4aa80ff | 6 | # @(#)Makefile 5.8 (Berkeley) %G% |
568afd31 | 7 | # |
c4aa80ff | 8 | CFLAGS= -O -DBSD4_2 -DSACREDMEM=256000 -DUSERMEM=`cat USERMEM` |
568afd31 KB |
9 | LIBC= /lib/libc.a |
10 | SRCS= compress.c | |
11 | OBJS= compress.o | |
12 | ||
13 | all: compress | |
64d06f2f | 14 | |
568afd31 | 15 | compress: USERMEM ${OBJS} ${LIBC} |
c4aa80ff | 16 | ${CC} ${CFLAGS} -o $@ ${OBJS} |
64d06f2f KM |
17 | |
18 | # USERMEM may have to be set by hand. It should contain the amount of | |
19 | # available user memory in bytes. Set it to zero, for physical memory | |
20 | # less than 1 Meg. | |
21 | USERMEM: | |
22 | sh usermem.sh > USERMEM | |
23 | ||
8b71f68d JL |
24 | # Temporarily don't delete USERMEM. When chroot'ed to /nbsd, usermem.sh |
25 | # fails totally. | |
568afd31 KB |
26 | clean: FRC |
27 | rm -f ${OBJS} core compress | |
28 | # rm -f ${OBJS} core compress USERMEM | |
29 | ||
30 | depend: FRC | |
31 | mkdep ${CFLAGS} ${SRCS} | |
32 | ||
33 | install: FRC | |
34 | install -s -o bin -g bin -m 755 compress ${DESTDIR}/usr/ucb/compress | |
35 | rm -f ${DESTDIR}/usr/ucb/uncompress ${DESTDIR}/usr/ucb/zcat | |
36 | ln ${DESTDIR}/usr/ucb/compress ${DESTDIR}/usr/ucb/uncompress | |
37 | ln ${DESTDIR}/usr/ucb/compress ${DESTDIR}/usr/ucb/zcat | |
38 | ||
39 | lint: FRC | |
40 | lint ${CFLAGS} ${SRCS} | |
41 | ||
42 | tags: FRC | |
43 | ctags ${SRCS} | |
44 | ||
45 | FRC: | |
46 | ||
47 | # DO NOT DELETE THIS LINE -- mkdep uses it. | |
48 | # DO NOT PUT ANYTHING AFTER THIS LINE, IT WILL GO AWAY. | |
49 | ||
50 | compress.o: compress.c /usr/include/stdio.h /usr/include/ctype.h | |
51 | compress.o: /usr/include/signal.h /usr/include/sys/types.h | |
52 | compress.o: /usr/include/sys/stat.h | |
4a9d7fdf | 53 | |
568afd31 | 54 | # IF YOU PUT ANYTHING HERE IT WILL GO AWAY |