diff options
author | Anssi Hannula <anssi@mandriva.org> | 2009-08-08 10:34:27 +0000 |
---|---|---|
committer | Anssi Hannula <anssi@mandriva.org> | 2009-08-08 10:34:27 +0000 |
commit | 87f79bfd646238cbaff8ae4d449e3dfdb76e4c0c (patch) | |
tree | ea6b500931795881ec242bca15a6f651ba561a1f | |
parent | ef8e57e11fbb52f8e3f31c65b9a371d094855e5c (diff) | |
download | rpm-setup-87f79bfd646238cbaff8ae4d449e3dfdb76e4c0c.tar rpm-setup-87f79bfd646238cbaff8ae4d449e3dfdb76e4c0c.tar.gz rpm-setup-87f79bfd646238cbaff8ae4d449e3dfdb76e4c0c.tar.bz2 rpm-setup-87f79bfd646238cbaff8ae4d449e3dfdb76e4c0c.tar.xz rpm-setup-87f79bfd646238cbaff8ae4d449e3dfdb76e4c0c.zip |
Update perl_convert_version to keep alphabetic tail in version number
(Luca Berra).
-rw-r--r-- | NEWS | 3 | ||||
-rw-r--r-- | build.macros.in | 11 |
2 files changed, 13 insertions, 1 deletions
@@ -1,3 +1,6 @@ +- update perl_convert_version to keep alphabetic tail in version number + (Luca Berra) + Version 1.93 - 28 July 2009, by Christophe Fergeau - update perl_convert_version macro (Jérôme Quelin) diff --git a/build.macros.in b/build.macros.in index b7a2aeb..009a6c8 100644 --- a/build.macros.in +++ b/build.macros.in @@ -223,7 +223,16 @@ GCONF_CONFIG_SOURCE=`%{_gconftool_bin} --get-default-source` %{_gconftool_bin} - # -%perl_convert_version() %(perl -Mversion -le '$v=version->new("%{1}")->normal; $v=~s/^v//; print $v') +%perl_convert_version() %(perl -Mversion -le ' + $x = "%{1}"; + $y = $x; + $x =~ s/[[:alpha:]]*$//; + $y =~ s/^$x//; + $x =~ s/\D*$//; + $v = version->new($x)->normal; + $v =~ s/^v//; + print "$v$y"; +') # kept for compatibility, but should not be used, especially the ugly perl_archlib! %perl_sitearch %(eval "`perl -V:installsitearch`"; echo $installsitearch) |