diff options
-rw-r--r-- | lib/Youri/Repository/Mandriva_upload.pm | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/lib/Youri/Repository/Mandriva_upload.pm b/lib/Youri/Repository/Mandriva_upload.pm index 0f41e85..fde4d19 100644 --- a/lib/Youri/Repository/Mandriva_upload.pm +++ b/lib/Youri/Repository/Mandriva_upload.pm @@ -279,12 +279,15 @@ sub _get_section { my $section = $user_context->{section}; my $media = $self->_get_media_config($target); my $arch = $package->get_arch(); + my $file = $package->as_file(); + $file =~ s,/+,/,g; # unneeded? + # FIXME: use $self->get_arch() $arch = $self->{_noarch} if $arch eq 'noarch'; $arch = $translate_arch{$arch} || $arch; if (!$section) { - my $file = $package->as_file(); - $section = $self->{packages}{$package->as_file()}{section} + $section = $self->{packages}{$file}{section}; + print "Section undefined, repository says it is '$section' for '$file'\n" if $self->{_verbose}; } if ($section && $section !~ /debug_/ && $package->is_debug()) { $section = "debug_$section" |