diff options
author | Michael Schroeder <mls@suse.de> | 2012-10-04 15:24:24 +0200 |
---|---|---|
committer | Michael Schroeder <mls@suse.de> | 2012-10-04 15:24:24 +0200 |
commit | bbec7e32b4d36faa656b9bf942c885d828496a38 (patch) | |
tree | d89413c8d09d220ae69965bed7ead78786f810e2 | |
parent | 7d1bfa52e9d2ffd60019481c1e3b96aa06d625ff (diff) | |
download | obs-build-bbec7e32b4d36faa656b9bf942c885d828496a38.tar.gz obs-build-bbec7e32b4d36faa656b9bf942c885d828496a38.tar.bz2 obs-build-bbec7e32b4d36faa656b9bf942c885d828496a38.zip |
- do not force rpm-5 packages to binary rpm, the lead type is always zero
-rw-r--r-- | Build/Rpm.pm | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/Build/Rpm.pm b/Build/Rpm.pm index 30370fb..caa339c 100644 --- a/Build/Rpm.pm +++ b/Build/Rpm.pm @@ -569,6 +569,7 @@ my %rpmstag = ( "REQUIREVERSION" => 1050, "NOSOURCE" => 1051, "NOPATCH" => 1052, + "RPMVERSION" => 1064, "PROVIDEFLAGS" => 1112, "PROVIDEVERSION" => 1113, "DIRINDEXES" => 1116, @@ -722,7 +723,10 @@ sub rpmq { } } if ($forcebinary && $stags{1044} && !$res{$stags{1044}}) { - $res{$stags{1044}} = [ '(none)' ]; # like rpm does... + # don't force for rpm-5 rpms + if (!($stags{1064} && $res{$stags{1064}} && $res{$stags{1064}}->[0] =~ /^5/)) { + $res{$stags{1044}} = [ '(none)' ]; # like rpm does... + } } if ($need_filenames) { @@ -832,7 +836,7 @@ sub verscmp { sub query { my ($handle, %opts) = @_; - my @tags = qw{NAME SOURCERPM NOSOURCE NOPATCH SIGTAG_MD5 PROVIDENAME PROVIDEFLAGS PROVIDEVERSION REQUIRENAME REQUIREFLAGS REQUIREVERSION}; + my @tags = qw{NAME SOURCERPM NOSOURCE NOPATCH SIGTAG_MD5 PROVIDENAME PROVIDEFLAGS PROVIDEVERSION REQUIRENAME REQUIREFLAGS REQUIREVERSION RPMVERSION}; push @tags, qw{EPOCH VERSION RELEASE ARCH}; push @tags, qw{FILENAMES} if $opts{'filelist'}; push @tags, qw{SUMMARY DESCRIPTION} if $opts{'description'}; |