summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 5dad73f)
raw | patch | inline | side by side (parent: 5dad73f)
author | Moritz Muehlenhoff <jmm@debian.org> | |
Tue, 17 Jan 2012 22:52:20 +0000 (23:52 +0100) | ||
committer | Sebastian Harl <sh@tokkee.org> | |
Tue, 14 Feb 2012 07:04:51 +0000 (08:04 +0100) |
This also enables hardening build flags.
debian/rules | patch | blob | history |
diff --git a/debian/rules b/debian/rules
index 5e7add1b4b6aa78f2f5e34b0a53e7cfb761c4965..b506e2d650b9d13a4674b8cafb3d186adc407b35 100755 (executable)
--- a/debian/rules
+++ b/debian/rules
DEB_BUILD_ARCH ?= $(shell dpkg-architecture -qDEB_BUILD_ARCH)
DEB_BUILD_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_BUILD_GNU_TYPE)
-CPPFLAGS = -I$(CURDIR)/debian/include
-CFLAGS = -Wall -g
+CPPFLAGS = `dpkg-buildflags --get CPPFLAGS`
+CPPFLAGS += -I$(CURDIR)/debian/include
+CFLAGS = `dpkg-buildflags --get CFLAGS`
+CFLAGS += -Wall
# There is no way to tell lt_dlopen() to use the RTLD_GLOBAL flag which is
# however required by the perl plugin (which would otherwise be unable to find
CPPFLAGS += -UCONFIGFILE
CPPFLAGS += -DCONFIGFILE='\"/etc/collectd/collectd.conf\"'
-ifneq (,$(filter noopt,$(DEB_BUILD_OPTIONS)))
- CFLAGS += -O0
-else
- CFLAGS += -O2
-endif
+LDFLAGS = `dpkg-buildflags --get LDFLAGS`
# The archdir map has been copied from openjdk-6's debian/rules.
JAVA_ARCHDIR_MAP = armel=arm hppa=parisc lpia=i386 powerpc=ppc powerpcspe=ppc sh4=sh
> debian/pkgconfig/OpenIPMIpthread.pc
PKG_CONFIG_PATH="$(CURDIR)/debian/pkgconfig:$$PKG_CONFIG_PATH" \
- ./configure $(confflags) CPPFLAGS="$(CPPFLAGS)" CFLAGS="$(CFLAGS)" \
+ ./configure $(confflags) CPPFLAGS="$(CPPFLAGS)" CFLAGS="$(CFLAGS)" LDFLAGS="$(LDFLAGS)" \
JAVAC="$(JAVAC)" JAR="$(JAR)" JAVA_CPPFLAGS="$(JAVA_CPPFLAGS)" \
JAVA_LDFLAGS="$(JAVA_LDFLAGS)" \
|| ( status=$$?; cat config.log; exit $$status )