Load greatest submodule. Fixed loop that occurred during build process.

This commit is contained in:
Ari Lemmetti 2014-10-30 14:00:54 +02:00
parent 9c6995f618
commit 6a12bc406d

View file

@ -140,16 +140,22 @@ PROGS = $(PROG)
TESTS = ./kvazaar_tests
DEPS = $(OBJS:.o=.d) $(TEST_OBJS:.o=.d)
DEPS = $(OBJS:.o=.d)
GREATEST = ../greatest/greatest.h
all: $(PROGS)
.PHONY: all clean build_tests tests
build_tests: $(TESTS)
build_tests: $(GREATEST) $(TESTS)
tests: build_tests
$(TESTS)
$(GREATEST):
git submodule init
git submodule update
# Compile files in strategy directories with appropriate flags.
EXTRA_FLAGS =
ifeq ($(ARCH), ppc64)
@ -186,10 +192,15 @@ $(TESTS): $(TEST_OBJS) $(ASMOBJS)
$(CC) $(CFLAGS) $(EXTRA_FLAGS) -c $< -o $@
%.d: %.c Makefile
$(CC) $(CFLAGS) -MF"$@" -MG -MM -MP -MT"$@" -MT"$(<:.c=.o)" "$<"
$(CC) $(CFLAGS) -MF"$@" -MM -MP -MT"$@" -MT"$(<:.c=.o)" "$<"
../tests/%.c: ../tests/%.h Makefile
touch $@
clean:
rm -f $(OBJS) $(PROGS) $(TESTS) $(ASMOBJS) $(TEST_OBJS) $(DEPS) $(TEST_DEPS)
rm -f $(OBJS) $(PROGS) $(TESTS) $(ASMOBJS) $(TEST_OBJS) $(DEPS)
-include $(DEPS)
ifneq ($(MAKECMDGOALS),clean)
-include $(DEPS)
endif