On Fri, May 29, 2015 at 02:52:10AM +0200, Guillem Jover wrote: > Hi! > > On Thu, 2015-05-28 at 20:14:29 -0300, Antonio Terceiro wrote: > > From 14e2a91d48397546d2cc303082322e49f41c57f8 Mon Sep 17 00:00:00 2001 > > From: Antonio Terceiro <terce...@debian.org> > > Date: Thu, 28 May 2015 20:10:23 -0300 > > Subject: [PATCH] Reduce build profiles when installing dependencies > > > Build-Depends: lines using build profiles cannot be transformed as-is to > > Depends: lines. Luckily Dpkg::Deps already knows how to process build > > profiles so we just need to tell it to do that. > > > diff --git a/runner/adt-run b/runner/adt-run > > index 71255d0..b97e6c5 100755 > > --- a/runner/adt-run > > +++ b/runner/adt-run > > @@ -971,7 +971,8 @@ fi > > perl = subprocess.Popen(['perl', '-'], stdin=subprocess.PIPE, > > stdout=subprocess.PIPE) > > code = '''use Dpkg::Deps; > > - $dep = deps_parse('%s', reduce_arch => 1, host_arch => > > '%s'); > > + $dep = deps_parse('%s', reduce_arch => 1, host_arch => > > '%s', > > + reduce_profiles => 1); > > print $dep->output(), "\\n"; > > ''' % (deps, self.dpkg_arch) > > If this is indeed parsing Build-Depends, you probably also want > “build_dep => 1” there.
Indeed, thanks. I am attaching an updated patch. -- Antonio Terceiro <terce...@debian.org>
From a6299236d8374653440f2693a095c549486d91eb Mon Sep 17 00:00:00 2001 From: Antonio Terceiro <terce...@debian.org> Date: Thu, 28 May 2015 20:10:23 -0300 Subject: [PATCH] Reduce build profiles when installing dependencies Build-Depends: lines using build profiles cannot be transformed as-is to Depends: lines. Luckily Dpkg::Deps already knows how to process build profiles so we just need to tell it to do that (`reduce_profiles => 1`). Also tell Dpkg::Deps to process extensions specific to build dependencies (such as :native) with `build_dep => 1` --- runner/adt-run | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/runner/adt-run b/runner/adt-run index 71255d0..955a05a 100755 --- a/runner/adt-run +++ b/runner/adt-run @@ -971,7 +971,8 @@ fi perl = subprocess.Popen(['perl', '-'], stdin=subprocess.PIPE, stdout=subprocess.PIPE) code = '''use Dpkg::Deps; - $dep = deps_parse('%s', reduce_arch => 1, host_arch => '%s'); + $dep = deps_parse('%s', reduce_arch => 1, host_arch => '%s', + reduce_profiles => 1, build_deps => 1); print $dep->output(), "\\n"; ''' % (deps, self.dpkg_arch) deps = perl.communicate(code.encode('UTF-8'))[0].decode('UTF-8').strip() -- 2.1.4
signature.asc
Description: Digital signature