From 1151c9922aed27b2e8ecc18630941a56b2dab44e Mon Sep 17 00:00:00 2001 From: Martin Willi Date: Fri, 27 Feb 2015 11:40:50 +0100 Subject: [PATCH] vici: Support ruby gem out-of-tree builds Referencing $(srcdir) in the gemspec is not really an option, as "gem build" includes the full path in the gem, so we need to build in $(srcdir). As there does not seem to be a way to control the output of "gem build", we manually move the gem to $(builddir) in OOT builds. --- src/libcharon/plugins/vici/ruby/Makefile.am | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/libcharon/plugins/vici/ruby/Makefile.am b/src/libcharon/plugins/vici/ruby/Makefile.am index ce38e1c3d4..c10705dc69 100644 --- a/src/libcharon/plugins/vici/ruby/Makefile.am +++ b/src/libcharon/plugins/vici/ruby/Makefile.am @@ -6,7 +6,9 @@ vici.gemspec: $(srcdir)/vici.gemspec.in $(srcdir)/vici.gemspec.in > $@ vici-$(PACKAGE_VERSION).gem: vici.gemspec - $(GEM) build vici.gemspec + (cd $(srcdir); $(GEM) build $(abs_builddir)/vici.gemspec) + [ "$(srcdir)" = "$(builddir)" ] || \ + mv $(srcdir)/vici-$(PACKAGE_VERSION).gem $(builddir) all-local: vici-$(PACKAGE_VERSION).gem -- 2.47.2