mirror of
https://git.pwmt.org/pwmt/zathura.git
synced 2024-12-28 07:26:01 +01:00
We need to check if macros are already defined in CPPFLAGS before setting them.
This commit is contained in:
parent
1998fdcb5a
commit
9f31c38cca
6 changed files with 17 additions and 11 deletions
1
Makefile
1
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
|
||||
|
|
11
config.mk
11
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
|
||||
|
|
2
po/de.po
2
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 <s.ramacher@gmx.at>\n"
|
||||
"Language-Team: LANGUAGE <LL@li.org>\n"
|
||||
|
|
|
@ -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 <EMAIL@ADDRESS>\n"
|
||||
"Language-Team: LANGUAGE <LL@li.org>\n"
|
||||
|
|
|
@ -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
|
||||
|
||||
|
|
|
@ -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
|
||||
|
|
Loading…
Reference in a new issue