do not make the default mirror for the native arch only. The sane expectation is, that the default mirror is for any architecture.

This commit is contained in:
Johannes 'josch' Schauer 2018-11-04 20:38:55 +01:00
parent cc7dddb1b3
commit 1890e22b14
Signed by: josch
GPG key ID: F2CBA5C78FBD83E1

View file

@ -1531,10 +1531,6 @@ sub main() {
# come from standard input # come from standard input
$sourceslist .= $stdindata; $sourceslist .= $stdindata;
} else { } else {
my $archopt = '';
if (scalar @{$options->{foreignarchs}} > 0) {
$archopt = " [arch=$options->{nativearch}]";
}
if (scalar @ARGV > 0) { if (scalar @ARGV > 0) {
for my $arg (@ARGV) { for my $arg (@ARGV) {
if ($arg eq '-') { if ($arg eq '-') {
@ -1542,7 +1538,7 @@ sub main() {
} elsif ($arg =~ /^deb(-src)? /) { } elsif ($arg =~ /^deb(-src)? /) {
$sourceslist .= "$arg\n"; $sourceslist .= "$arg\n";
} elsif ($arg =~ /:\/\//) { } elsif ($arg =~ /:\/\//) {
$sourceslist .= "deb$archopt $arg $suite $options->{components}\n"; $sourceslist .= "deb $arg $suite $options->{components}\n";
} elsif (-f $arg) { } elsif (-f $arg) {
open my $fh, '<', $arg or die "cannot open $arg: $!"; open my $fh, '<', $arg or die "cannot open $arg: $!";
while (my $line = <$fh>) { while (my $line = <$fh>) {
@ -1563,10 +1559,10 @@ sub main() {
} elsif ($stdindata ne '') { } elsif ($stdindata ne '') {
$sourceslist .= $stdindata; $sourceslist .= $stdindata;
} else { } else {
$sourceslist .= "deb$archopt http://deb.debian.org/debian $suite $options->{components}\n"; $sourceslist .= "deb http://deb.debian.org/debian $suite $options->{components}\n";
if (any { $_ eq $suite } ('stable', 'oldstable', 'stretch') ) { if (any { $_ eq $suite } ('stable', 'oldstable', 'stretch') ) {
$sourceslist .= "deb$archopt http://deb.debian.org/debian $suite-updates $options->{components}\n"; $sourceslist .= "deb http://deb.debian.org/debian $suite-updates $options->{components}\n";
$sourceslist .= "deb$archopt http://security.debian.org/debian-security $suite/updates $options->{components}\n"; $sourceslist .= "deb http://security.debian.org/debian-security $suite/updates $options->{components}\n";
} }
} }
} }