tags 691449 + patch quit Matthias Klose wrote:
> is there a reason not to escape the whitespace by default for > --export=configure? --export=configure is designed to be used like this: conf_opts := $(shell dpkg-buildflags --export=configure) conf_opts += --prefix=/usr etc override_dh_auto_configure: ./configure $(conf_opts) or like this: eval "./configure `dpkg-buildflags --export=configure` --prefix=/usr etc" or like this: eval "set -- $(dpkg-buildflags --export=configure)" ./configure "$@" --prefix=/usr etc Therefore it uses double quotes ('"') around arguments that might contain spaces. Any additional escaping (e.g., '\' before spaces) would be passed through to configure and break the build. How about this patch? Signed-off-by: Jonathan Nieder <jrnie...@gmail.com> --- man/dpkg-buildflags.1 | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git i/man/dpkg-buildflags.1 w/man/dpkg-buildflags.1 index ea61306b..29fc38aa 100644 --- i/man/dpkg-buildflags.1 +++ w/man/dpkg-buildflags.1 @@ -207,6 +207,24 @@ This variable can be used to disable/enable various hardening build flags through the \fBhardening\fP option. See the \fBHARDENING\fP section for details. . +.SH QUOTING +If \fIformat\fP is either \fBsh\fP or \fBconfigure\fP then output +is quoted. In a makefile, the simplest way to consume this output is +to use the \fBshell\fP function: +.P +.nf + build: + ./configure $(shell dpkg-buildflags --export=configure) + set -e; $(shell dpkg-buildflags --export=sh); $(MAKE) +.fi +.P +In a shell script, "eval" will interpret the output. +.P +.nf + eval "./configure $(dpkg-buildflags --export=configure)" + eval "$(dpkg-buildflags --export=sh)" + make +.fi .SH HARDENING Several compile-time options (detailed below) can be used to help harden a resulting binary against memory corruption attacks, or provide -- To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org