Fix a Makefile typo.
[fjl] / Makefile
1 CC=gcc
2 CFLAGS=-std=gnu99 -O2 -msse4.1 -g -Wall -Wextra
3 LDFLAGS=-lm -lrt
4
5 all: tests driver
6
7 UNSTUFF_TEST_OBJS=unstuff.o unstuff_test.o benchmark.o
8 unstuff_test: $(UNSTUFF_TEST_OBJS)
9         $(CC) $(LDFLAGS) -o $@ $(UNSTUFF_TEST_OBJS)
10
11 BITSOURCE_TEST_OBJS=bitsource.o bitsource_test.o
12 bitsource_test: $(BITSOURCE_TEST_OBJS)
13         $(CC) $(LDFLAGS) -o $@ $(BITSOURCE_TEST_OBJS)
14
15 DEHUFF_TEST_OBJS=dehuff.o input.o bitsource.o dehuff_test.o
16 dehuff_test: $(DEHUFF_TEST_OBJS)
17         $(CC) $(LDFLAGS) -o $@ $(DEHUFF_TEST_OBJS)
18
19 BYTESOURCE_TEST_OBJS=bytesource.o choice.o unstuff.o bytesource_test.o idct_float.o
20 bytesource_test: $(BYTESOURCE_TEST_OBJS)
21         $(CC) $(LDFLAGS) -o $@ $(BYTESOURCE_TEST_OBJS)
22
23 IDCT_TEST_OBJS=idct_float.o idct_imprecise_int.o idct_reference.o idct_test.o benchmark.o
24 idct_test: $(IDCT_TEST_OBJS)
25         $(CC) $(LDFLAGS) -o $@ $(IDCT_TEST_OBJS)
26
27 DRIVER_OBJS=driver.o idct_float.o unstuff.o bytesource.o bitsource.o choice.o dehuff.o input.o
28 driver: $(DRIVER_OBJS)
29         $(CC) $(LDFLAGS) -o $@ $(DRIVER_OBJS)
30
31 tests: unstuff_test bitsource_test dehuff_test bytesource_test idct_test
32 clean:
33         $(RM) $(UNSTUFF_TEST_OBJS) unstuff_test
34         $(RM) $(BITSOURCE_TEST_OBJS) bitsource_test
35         $(RM) $(DEHUFF_TEST_OBJS) dehuff_test
36         $(RM) $(BYTESOURCE_TEST_OBJS) bytesource_test
37         $(RM) $(IDCT_TEST_OBJS) idct_test
38         $(RM) $(DRIVER_TEST_OBJS) driver
39
40 test: tests
41         ./unstuff_test
42         ./bitsource_test
43         ./dehuff_test
44         ./bytesource_test
45         ./idct_test