From: Christian Ehrhardt Date: Thu, 23 Jun 2016 12:42:52 +0000 (+0200) Subject: d/rules: strip -Wl, from dpkg-buildflags output X-Git-Tag: debian/16.07-1~111 X-Git-Url: https://gerrit.fd.io/r/gitweb?a=commitdiff_plain;h=13238a66181156b55aa3015dfca690a5f590c5e7;p=deb_dpdk.git d/rules: strip -Wl, from dpkg-buildflags output The DPKG build system adds a -Wl, to and EXTRA_LDFLAGS, by that the flags provided by dpkg-buildflags become -Wl,-Wl,option which fails to build. Fix by filtering the -Wl, prefix before exporting. Note: filtering with make text functions is hard if the pattern contains a comma, so sed was chosen. Change-Id: I9b91b86c80529855dfb1c5a52725c0d07a95e5c8 Signed-off-by: Christian Ehrhardt --- diff --git a/debian/rules b/debian/rules index 8758dc66..157ce56d 100755 --- a/debian/rules +++ b/debian/rules @@ -22,7 +22,8 @@ export DEB_CFLAGS_MAINT_APPEND = -fPIC include /usr/share/dpkg/buildflags.mk export EXTRA_CFLAGS=$(CFLAGS) -export EXTRA_LDFLAGS=$(LDFLAGS) +# need to be stripped as DPDK build system adds them and it would be -Wl,-Wl,opt +export EXTRA_LDFLAGS=$(shell echo $(LDFLAGS) | sed 's/-Wl,//g') # People rebuilding this package can overwrite DPDK_CONFIG, RTE_MACHINE and # RTE_TARGET via environment variables if they like