Commit 44debd80c4908e439d4a505ad7f6de367635b0eb

Ramsay Jones 2010-04-27T16:13:57

Makefile: Add source for the built-in SHA1 routines to $(SRC_C) This results in the 'sparse' and 'coverage' targets including the C source files for the built-in SHA1 routines. In addition to the sparse check, this results in the generation of the '.gcov' file and inclusion in the test coverage report. Signed-off-by: Ramsay Jones <ramsay@ramsay1.demon.co.uk>

diff --git a/Makefile b/Makefile
index 00c5bdc..96e4df3 100644
--- a/Makefile
+++ b/Makefile
@@ -56,7 +56,7 @@ endif
 
 SRC_C = $(wildcard src/*.c)
 OS_SRC = $(wildcard src/$(OS)/*.c)
-SRC_C += $(OS_SRC)
+SRC_C += $(OS_SRC) $(EXTRA_SRC)
 OBJS = $(patsubst %.c,%.o,$(SRC_C)) $(EXTRA_OBJ)
 HDRS = $(wildcard src/*.h)
 PUBLIC_HEADERS = $(wildcard src/git/*.h)
@@ -71,12 +71,11 @@ TEST_RUN = $(patsubst %.exe,%.run,$(TEST_EXE))
 TEST_VAL = $(patsubst %.exe,%.val,$(TEST_EXE))
 
 ifdef PPC_SHA1
-	EXTRA_SRC += src/ppc/sha1.c src/ppc/sha1ppc.S
-	EXTRA_OBJ += src/ppc/sha1.o src/ppc/sha1ppc.o
+	EXTRA_SRC += src/ppc/sha1.c
+	EXTRA_OBJ += src/ppc/sha1ppc.o
 	EXTRA_CFLAGS += -DPPC_SHA1
 else
 	EXTRA_SRC += src/block-sha1/sha1.c
-	EXTRA_OBJ += src/block-sha1/sha1.o
 endif
 
 BASIC_CFLAGS := -Isrc