X-Git-Url: https://code.citadel.org/?a=blobdiff_plain;f=libcitadel%2Fdebian%2Frules;h=11d290b9cba6fa94cce44cfaefd5f5bd329b1619;hb=373b01806f2c2949b86b0ef83b28e15d38af5ee6;hp=b7664d47f41fb21fb7433b9f7167172dff8c8cc0;hpb=d904fa6ae9df4c50e189d52996eca7206c5dfa33;p=citadel.git diff --git a/libcitadel/debian/rules b/libcitadel/debian/rules index b7664d47f..11d290b9c 100755 --- a/libcitadel/debian/rules +++ b/libcitadel/debian/rules @@ -9,13 +9,16 @@ export DH_COMPAT = 5 DEB_HOST_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_HOST_GNU_TYPE) DEB_BUILD_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_BUILD_GNU_TYPE) -CFLAGS = -Wall -g -LDFALGS = +CFLAGS = -Wall -g -Wformat -Werror=format-security +#-finline-functions +LDFALGS = +# -finline-functions ifneq (,$(findstring debug,$(DEB_BUILD_OPTIONS))) CFLAGS += -O0 -ggdb -rdynamic -MD -MP -D DEBUG -D VALGRIND EXTRA_ARGS = --with-backtrace else - CFLAGS += -O2 +# CFLAGS += -O2 -fPIC + CFLAGS += -O0 -ggdb -rdynamic -MD -MP -D DEBUG -D VALGRIND endif ifneq (,$(findstring profiling,$(DEB_BUILD_OPTIONS))) @@ -27,12 +30,17 @@ ifneq (,$(findstring sprofiling,$(DEB_BUILD_OPTIONS))) CFLAGS += -D SIZE_DEBUG endif +ifneq (,$(findstring gcov,$(DEB_BUILD_OPTIONS))) + CFLAGS += -fprofile-arcs -ftest-coverage + LDFLAGS += -fprofile-arcs -ftest-coverage +endif + build: build-stamp build-stamp: dh_testdir - CFLAGS="$(CFLAGS)"; LDFLAGS="$(LDFLAGS)"; ./configure --host=$(DEB_HOST_GNU_TYPE) --build=$(DEB_BUILD_GNU_TYPE) \ + export CFLAGS="$(CFLAGS)"; export LDFLAGS="$(LDFLAGS)"; ./configure --host=$(DEB_HOST_GNU_TYPE) --build=$(DEB_BUILD_GNU_TYPE) \ $(EXTRA_ARGS) \ --prefix=/usr @@ -82,11 +90,11 @@ binary-indep: build install binary-arch: build install dh_testdir -a dh_testroot -a - dh_installchangelogs -a -plibcitadel2 + dh_installchangelogs -a -plibcitadel4 dh_installdocs -a dh_install -a --sourcedir=debian/tmp dh_link -a - dh_strip -a --dbg-package=libcitadel2-dbg + dh_strip -a --dbg-package=libcitadel4-dbg dh_compress -a dh_fixperms -a dh_makeshlibs -a -V