From 7b5300da25d036273a4b83a8857b72f1d4534e87 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Elan=20Ruusam=C3=A4e?= Date: Thu, 20 Jun 2013 23:49:59 +0300 Subject: [PATCH] 1.665: added ruby_specdir, memoize ruby_gemdir ruby_gemdir is defined also in macros.d/ruby in case of rpm5 which we override --- rpm-build-macros.spec | 2 +- rpm.macros | 4 ++++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/rpm-build-macros.spec b/rpm-build-macros.spec index 2c34b91..3f37d3f 100644 --- a/rpm-build-macros.spec +++ b/rpm-build-macros.spec @@ -5,7 +5,7 @@ %if "%{pld_release}" == "ac" %define with_rpm4 1 %endif -%define rpm_macros_rev 1.664 +%define rpm_macros_rev 1.665 %define find_lang_rev 1.36 Summary: PLD Linux RPM build macros Summary(pl.UTF-8): Makra do budowania pakietów RPM dla Linuksa PLD diff --git a/rpm.macros b/rpm.macros index 3ccc0e2..e435d6d 100644 --- a/rpm.macros +++ b/rpm.macros @@ -917,6 +917,10 @@ fi; \ %ruby_vendordir %{expand:%%global ruby_vendordir %(%{__ruby} -r rbconfig -e 'print RbConfig::CONFIG["vendordir"]' 2>/dev/null || echo ERROR)}%ruby_vendordir %ruby_version %{expand:%%global ruby_version %(%{__ruby} -r rbconfig -e 'print RbConfig::CONFIG["ruby_version"]' 2>/dev/null || echo ERROR)}%ruby_version +%ruby_gemdir %{expand:%%global ruby_gemdir %(%{__ruby} -r rbconfig -e 'print RbConfig::CONFIG["rubylibdir"].sub(RbConfig::CONFIG["ruby_version"], "gems/#{RbConfig::CONFIG["ruby_version"]}")' 2>/dev/null || echo ERROR)}%{ruby_gemdir} +%ruby_specdir %{ruby_gemdir}/specifications + +# deprecated, similar functionality autogenerated with rpm5 %ruby_ver_requires_eq Requires: ruby(ver) = %ruby_version %ruby_mod_ver_requires_eq Requires: ruby-modules(ver) = %ruby_version -- 2.44.0