aboutsummaryrefslogtreecommitdiffstats
path: root/build.macros.in
diff options
context:
space:
mode:
authorChristophe Fergeau <cfergeau@mandriva.com>2009-02-03 09:15:57 +0000
committerChristophe Fergeau <cfergeau@mandriva.com>2009-02-03 09:15:57 +0000
commit1031292e08514fcb6e0b5271002707eb750f0eff (patch)
tree9bd8f17a32f5e8fc5ecf2cb36929b68cfe8b2a42 /build.macros.in
parent0b404041c3d71821e8c6b34c530304ab6f31fce8 (diff)
downloadrpm-setup-1031292e08514fcb6e0b5271002707eb750f0eff.tar
rpm-setup-1031292e08514fcb6e0b5271002707eb750f0eff.tar.gz
rpm-setup-1031292e08514fcb6e0b5271002707eb750f0eff.tar.bz2
rpm-setup-1031292e08514fcb6e0b5271002707eb750f0eff.tar.xz
rpm-setup-1031292e08514fcb6e0b5271002707eb750f0eff.zip
Add new perl_convert_version macro to convert cpan version to rpm version
Diffstat (limited to 'build.macros.in')
-rw-r--r--build.macros.in3
1 files changed, 3 insertions, 0 deletions
diff --git a/build.macros.in b/build.macros.in
index 500020f..da63c12 100644
--- a/build.macros.in
+++ b/build.macros.in
@@ -222,6 +222,9 @@ GCONF_CONFIG_SOURCE=`%{_gconftool_bin} --get-default-source` %{_gconftool_bin} -
# %{_mandir}/*/*
#
+
+%perl_convert_version() %(perl -Mversion -E '$v=version->new(%{1})->normal; $v=~s/^v//; say $v')
+
# kept for compatibility, but should not be used, especially the ugly perl_archlib!
%perl_sitearch %(eval "`perl -V:installsitearch`"; echo $installsitearch)
%perl_archlib %(eval "`perl -V:installarchlib`"; echo $installarchlib)