El ds 21 de 05 de 2016 a les 06:15 +0000, Niels Thykier va escriure:
>  * Can you clarify why this should be done?

For instance, in https://bugs.debian.org/823264 , wine32-tools depends
on perl (perl:i386) on amd64, but perl:amd64 would work. The dependency
is "perl", it should be "perl:any", but this comes from ${perl:Depends}.
There should be a way for dh_perl to output "perl:any".

>  * Can you clarify why the version constraint matters for adding :any?
> 
>  * A quick look at the patch suggests that the behaviour is
>    "unconditional" and will also be added to packages containing XS
>    modules etc.
>    - However, your text above suggest this was unintended.

In packages with XS modules, the version is set, thus :any would not be
added.
However, looking again at the code, I see that I forgot ARCHDEP_MODULE.
I submit a new patch. I am not sure what should happen with the -V
option.
--- a/dh_perl	2016-04-03 10:17:54.000000000 +0000
+++ b/dh_perl	2016-05-21 16:46:07.000000000 +0000
@@ -126,10 +126,15 @@
 				unless $version;
 			$version = ">= $version";
 		}
-		
+
+		my $perlarch = $perl;
+		$perlarch .= ':any'
+			unless $deps & ( XS_MODULE | ARCHDEP_MODULE )
+				or $dh{V_FLAG_SET};
+
 		# no need to depend on an un-versioned perl-base -- it's
 		# essential
-		addsubstvar($package, "perl:Depends", $perl, $version)
+		addsubstvar($package, "perl:Depends", $perlarch, $version)
 			unless $perl eq 'perl-base' && ! length($version);
 
 		# add perlapi-<ver> for XS modules and other modules

Attachment: smime.p7s
Description: S/MIME cryptographic signature

Reply via email to