On Thu, Apr 05, 2012 at 09:53:10AM +0200, Frederic Peters wrote:
> Hi Moritz,
> 
> Moritz Muehlenhoff wrote:
> > Source: lasso
> > Version: 2.3.6-2
> > Severity: important
> > Tags: patch
> >
> > Please enable hardened build flags through dpkg-buildflags.
> > 
> > Patch attached. (dpkg-buildflags abides "noopt" from DEB_BUILD_OPTIONS)
> 
> There's no patch attached :/

Doh! Now really attached.

Cheers,
        Moritz
diff -aur lasso-2.3.6.harden/debian/rules lasso-2.3.6/debian/rules
--- lasso-2.3.6.harden/debian/rules	2012-04-04 23:12:30.000000000 +0200
+++ lasso-2.3.6/debian/rules	2012-04-04 23:12:15.000000000 +0200
@@ -28,13 +28,11 @@
 PYVERS		:= $(shell pyversions -vr debian/control)
 OTHERPYVERS	:= $(filter-out $(PYDEF), $(PYVERS))
 
-CFLAGS = -Wall -g
+CFLAGS = `dpkg-buildflags --get CFLAGS`
+CFLAGS += -Wall
+LDFLAGS = `dpkg-buildflags --get LDFLAGS`
+CPPFLAGS = `dpkg-buildflags --get CPPFLAGS`
 
-ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS)))
-	CFLAGS += -O0
-else
-	CFLAGS += -O2
-endif
 ifeq (,$(findstring nostrip,$(DEB_BUILD_OPTIONS)))
 	INSTALL_PROGRAM += -s
 endif
@@ -66,7 +64,7 @@
 config.status: configure
 	dh_testdir
 	# Add here commands to configure the package.
-	CFLAGS="$(CFLAGS)" ./configure --host=$(DEB_HOST_GNU_TYPE) --build=$(DEB_BUILD_GNU_TYPE) $(CONFIGURE_ARGS)
+	CFLAGS="$(CFLAGS)" CPPFLAGS="$(CPPFLAGS)" LDFLAGS="$(LDFLAGS)" ./configure --host=$(DEB_HOST_GNU_TYPE) --build=$(DEB_BUILD_GNU_TYPE) $(CONFIGURE_ARGS)
 
 
 build: build-stamp
Nur in lasso-2.3.6/debian: rules~.

Reply via email to