aboutsummaryrefslogtreecommitdiffstats
path: root/rpmbuildupdate
diff options
context:
space:
mode:
Diffstat (limited to 'rpmbuildupdate')
-rwxr-xr-xrpmbuildupdate9
1 files changed, 7 insertions, 2 deletions
diff --git a/rpmbuildupdate b/rpmbuildupdate
index 2563fea..3d0fdc8 100755
--- a/rpmbuildupdate
+++ b/rpmbuildupdate
@@ -235,8 +235,13 @@ sub build
if(!$url[0])
{
- print "URL of sources was not found ! Trying to guess it with url tag ...\n";
- push(@url, $specvars{'url'}.'/'.$tar_ball)
+ print "URL of sources was not found ! Trying to guess it with url tag ...\n";
+ my $url=$specvars{'url'};
+ if ($url =~ m!http://(.*)\.((?:sourceforge|sf)\.net)/(.*)!)
+ {
+ $url="http://prdownloads.$2/$1/$3" unless $1 eq 'prdownloads';
+ }
+ push(@url, $url.'/'.$tar_ball)
}
$found = 0;