aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPascal Terjan <pterjan@gmail.com>2013-09-10 13:10:04 +0000
committerPascal Terjan <pterjan@gmail.com>2013-09-10 13:10:04 +0000
commitdaca30569be507005ad22264dd11e542a2d22de7 (patch)
tree909625d2e9d86bea1be6afa403653fe783e31eff
parentd2ddca93fb0f5d1daaef3b414a93338208c252fc (diff)
downloadrpm-setup-daca30569be507005ad22264dd11e542a2d22de7.tar
rpm-setup-daca30569be507005ad22264dd11e542a2d22de7.tar.gz
rpm-setup-daca30569be507005ad22264dd11e542a2d22de7.tar.bz2
rpm-setup-daca30569be507005ad22264dd11e542a2d22de7.tar.xz
rpm-setup-daca30569be507005ad22264dd11e542a2d22de7.zip
Create a gem_setup macro fixing most common problems1.180
-rw-r--r--NEWS3
-rw-r--r--build.macros.in11
-rw-r--r--configure.ac2
3 files changed, 15 insertions, 1 deletions
diff --git a/NEWS b/NEWS
index a52d862..724a036 100644
--- a/NEWS
+++ b/NEWS
@@ -1,3 +1,6 @@
+Version 1.180 - 10 Sep 2013, by Pascal Terjan
+- Create a %gem_setup fixing most common problems
+
Version 1.179 - 8 Sep 2013, by Pascal Terjan
- Remove extra space in __ruby_module_name when oname is not defined
diff --git a/build.macros.in b/build.macros.in
index d21e9e1..cec3683 100644
--- a/build.macros.in
+++ b/build.macros.in
@@ -482,6 +482,17 @@ popd
%__ruby_module_name %{?oname}%{!?oname:%(echo %{name}|cut -d\- -f2-)}
+%gem_setup \
+%setup -q \
+tar xmf data.tar.gz \
+if [ ! -f %{__ruby_module_name}.gemspec ]; then \
+ %{_bindir}/gem specification -l --ruby %{SOURCE0} > %{__ruby_module_name}.gemspec \
+fi \
+sed -i -e 's/`git ls-files`/`find -type f`/' \\\
+ -e 's/`git ls-files -- \\\(.*\\\)`/`find \\\1 -type f`/' \\\
+ -e 's/ s.version = .*/ s.version = "%{version}"/' \\\
+ %{__ruby_module_name}.gemspec
+
%gem_build \
if [ ! -f %{__ruby_module_name}.gemspec ]; then \
%{_bindir}/gem specification -l --ruby %{SOURCE0} > %{__ruby_module_name}.gemspec \
diff --git a/configure.ac b/configure.ac
index e8860d9..2a13073 100644
--- a/configure.ac
+++ b/configure.ac
@@ -4,7 +4,7 @@
# $Id: configure.ac 271266 2010-11-04 10:43:28Z fwang $
AC_PREREQ(2.59)
-AC_INIT(rpm-mageia-setup, 1.179, pterjan@mageia.org)
+AC_INIT(rpm-mageia-setup, 1.180, pterjan@mageia.org)
AC_CANONICAL_TARGET
AM_INIT_AUTOMAKE(1.9 -Wno-portability no-dist-gzip dist-xz)
AC_CONFIG_SRCDIR