diff --git a/Makefile b/Makefile index 85939e4..a5a1f9d 100644 --- a/Makefile +++ b/Makefile @@ -102,6 +102,7 @@ doc: gcov: clean $(QUIET)CFLAGS="${CFLAGS}-fprofile-arcs -ftest-coverage" LDFLAGS="${LDFLAGS} -fprofile-arcs" ${MAKE} $(PROJECT) + $(QUIET)CFLAGS="${CFLAGS}-fprofile-arcs -ftest-coverage" LDFLAGS="${LDFLAGS} -fprofile-arcs" ${MAKE} -C tests run $(QUIET)${MAKE} -C tests $(QUIET)lcov --directory . --capture --output-file $(PROJECT).info $(QUIET)genhtml --output-directory gcov $(PROJECT).info diff --git a/config.mk b/config.mk index 4a5f348..ae2e415 100644 --- a/config.mk +++ b/config.mk @@ -43,7 +43,16 @@ LIBS = ${GIRARA_LIB} ${GTK_LIB} ${DL_LIB} -lpthread -lm # flags CFLAGS += -std=c99 -pedantic -Wall -Wno-format-zero-length -Wextra $(INCS) -CPPFLAGS += -DZATHURA_PLUGINDIR=\"${PLUGINDIR}\" -DGETTEXT_PACKAGE=\"${PROJECT}\" -DLOCALEDIR=\"${LOCALEDIR}\" + +ifeq (,$(findstring -DZATHURA_PLUGINDIR,${CPPFLAGS})) +CPPFLAGS += -DZATHURA_PLUGINDIR=\"${PLUGINDIR}\" +endif +ifeq (,$(findstring -DGETTEXT_PACKAGE,${CPPFLAGS})) +CPPFLAGS += -DGETTEXT_PACKAGE=\"${PROJECT}\" +endif +ifeq (,$(findstring -DLOCALEDIR,${CPPFLAGS})) +CPPFLAGS += -DLOCALEDIR=\"${LOCALEDIR}\" +endif # debug DFLAGS ?= -g diff --git a/po/de.po b/po/de.po index 072241f..4b588ed 100644 --- a/po/de.po +++ b/po/de.po @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: PACKAGE VERSION\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2012-03-05 08:21+0100\n" +"POT-Creation-Date: 2012-03-05 09:33+0100\n" "PO-Revision-Date: 2012-03-04 17:77+0100\n" "Last-Translator: Sebastian Ramacher \n" "Language-Team: LANGUAGE \n" diff --git a/po/zathura.pot b/po/zathura.pot index 653f68b..530e1f9 100644 --- a/po/zathura.pot +++ b/po/zathura.pot @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: PACKAGE VERSION\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2012-03-05 08:21+0100\n" +"POT-Creation-Date: 2012-03-05 09:33+0100\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" diff --git a/tests/Makefile b/tests/Makefile index fbc93d9..693605e 100644 --- a/tests/Makefile +++ b/tests/Makefile @@ -8,16 +8,15 @@ PROJECT = tests SOURCE = tests.c $(wildcard test_*.c) OBJECTS = ${SOURCE:.c=.o} -ZSOURCE = $(shell find ../ -maxdepth 1 -iname "*.c" -a ! -iname "database-*" ! -iname "main.c") +ZSOURCE = $(shell find ../ -maxdepth 1 -iname "*.c" -a ! -iname "database-sqlite.c" ! -iname "main.c") ZOBJECTS = ${ZSOURCE:.c=.o} -ifeq (${DATABASE}, sqlite) +ifneq (${WITH_SQLITE},0) INCS += $(SQLITE_INC) LIBS += $(SQLITE_LIB) ZSOURCE += ../database-sqlite.c -else -ifeq (${DATABASE}, plain) -ZSOURCE += ../database-plain.c +ifeq (,$(findstring -DWITH_SQLITE,${CPPFLAGS})) +CPPFLAGS += -DWITH_SQLITE endif endif diff --git a/tests/config.mk b/tests/config.mk index 00e774d..12780b6 100644 --- a/tests/config.mk +++ b/tests/config.mk @@ -4,6 +4,3 @@ CHECK_INC ?= $(shell pkg-config --cflags check) CHECK_LIB ?= $(shell pkg-config --libs check) LIBS += ${CHECK_LIB} - -CFLAGS += -fprofile-arcs -ftest-coverage -LDFLAGS += -fprofile-arcs