diff options
Diffstat (limited to 'Makefile')
| -rw-r--r-- | Makefile | 30 |
1 files changed, 30 insertions, 0 deletions
diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..d124743 --- /dev/null +++ b/Makefile | |||
| @@ -0,0 +1,30 @@ | |||
| 1 | |||
| 2 | CC = gcc | ||
| 3 | SH = /bin/sh | ||
| 4 | |||
| 5 | CFLAGS = -O3 -fomit-frame-pointer -funroll-loops -Wall -Winline -W | ||
| 6 | |||
| 7 | |||
| 8 | |||
| 9 | all: | ||
| 10 | cat words0 | ||
| 11 | $(CC) $(CFLAGS) -o bzip2 bzip2.c | ||
| 12 | $(CC) $(CFLAGS) -o bzip2recover bzip2recover.c | ||
| 13 | rm -f bunzip2 | ||
| 14 | ln -s ./bzip2 ./bunzip2 | ||
| 15 | cat words1 | ||
| 16 | ./bzip2 -1 < sample1.ref > sample1.rb2 | ||
| 17 | ./bzip2 -2 < sample2.ref > sample2.rb2 | ||
| 18 | ./bunzip2 < sample1.bz2 > sample1.tst | ||
| 19 | ./bunzip2 < sample2.bz2 > sample2.tst | ||
| 20 | cat words2 | ||
| 21 | cmp sample1.bz2 sample1.rb2 | ||
| 22 | cmp sample2.bz2 sample2.rb2 | ||
| 23 | cmp sample1.tst sample1.ref | ||
| 24 | cmp sample2.tst sample2.ref | ||
| 25 | cat words3 | ||
| 26 | |||
| 27 | |||
| 28 | clean: | ||
| 29 | rm -f bzip2 bunzip2 bzip2recover sample*.tst sample*.rb2 | ||
| 30 | |||
