t3x/t3x9-book/Makefile

24 lines
455 B
Makefile

all: t0 t.elf
t0: t.c t.t
cc -static -o t0 t.c
t.elf: test
cp t3 t.elf
test: t0
touch t1 t2 t3; chmod +x t1 t2 t3
./t0 <t.t >t1 && ./t1 <t.t >t2 && ./t2 <t.t >t3 && cmp t2 t3
mksums: clean
ls | grep -v t3x9.tgz | grep -v _csums | csum -m >_csums
csums:
csum -u <_csums >_csums.new && mv -f _csums.new _csums
clean:
rm -f t0 t1 t2 t3 a.out dump *.o *.core t3x9.tgz
arc: clean
(cd ..; tar cvf - t3x9 | gzip -9 >t3x9.tgz); mv -f ../t3x9.tgz .