[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: dh_gencontrol and space separated list

* Mathieu Malaterre <mathieu.malaterre@gmail.com>, 2012-01-30, 17:07:
Hi all,

 I am trying to automated the list of archs from d/rules files. I am using :

include /usr/share/mono/mono-archs.make
	dh $@ --with cli
	dh_gencontrol -- -Vmono:Archs:"$(mono_archs)"

It seems like this is a bad idea, as I get:

$ dpkg-buildpackage
dpkg-buildpackage: source package gdcm
dpkg-buildpackage: source version 2.2.0-2
dpkg-buildpackage: source changed by Mathieu Malaterre
dpkg-buildpackage: host architecture amd64
dpkg-source --before-build gdcm-2.2.0
dpkg-source: error: `${mono:Archs}' is not a legal architecture string
dpkg-buildpackage: error: dpkg-source --before-build gdcm-2.2.0 gave
error exit status 255

Note that this error came from dpkg-source, before debian/rules was run. (Therefore, it has nothing to do with dh_gencontrol.)

If you're trying to use ${mono:Archs} in the Architecture field, then no, you can't do this:

"While variable substitution is done on all control fields, some of those fields are used and needed during the build when the substitution did not yet occur. That's why you can't use variables in the Package, Source and Architecture fields." (from deb-substvars manpage)

Jakub Wilk

Reply to: