[packages/ruby-fpm] install templates

glen glen at pld-linux.org
Mon Aug 10 13:25:19 CEST 2015


commit 1459f1e63d631b3c12382708eee9cfde026a9255
Author: Elan Ruusamäe <glen at delfi.ee>
Date:   Mon Aug 10 13:14:20 2015 +0300

    install templates

 ruby-fpm.spec   |  3 +++
 templates.patch | 11 +++++++++++
 2 files changed, 14 insertions(+)
---
diff --git a/ruby-fpm.spec b/ruby-fpm.spec
index 6f87ad4..f518289 100644
--- a/ruby-fpm.spec
+++ b/ruby-fpm.spec
@@ -11,6 +11,7 @@ License:	MIT-like
 Group:		Development/Languages
 Source0:	http://rubygems.org/downloads/%{pkgname}-%{version}.gem
 # Source0-md5:	4d82b0484db150928330b04bb44c92a2
+Patch0:		templates.patch
 URL:		https://github.com/jordansissel/fpm
 BuildRequires:	rpm-rubyprov
 BuildRequires:	rpmbuild(macros) >= 1.665
@@ -42,6 +43,7 @@ wasting pointless hours debugging bad rpm specs!
 
 %prep
 %setup -q -n %{pkgname}-%{version}
+%patch0 -p1
 %{__sed} -i -e '1 s,#!.*ruby,#!%{__ruby},' bin/*
 
 %build
@@ -53,6 +55,7 @@ rm -rf $RPM_BUILD_ROOT
 install -d $RPM_BUILD_ROOT{%{ruby_vendorlibdir},%{ruby_specdir},%{_bindir}}
 cp -a lib/* $RPM_BUILD_ROOT%{ruby_vendorlibdir}
 cp -a bin/* $RPM_BUILD_ROOT%{_bindir}
+cp -a templates $RPM_BUILD_ROOT%{ruby_vendorlibdir}/%{pkgname}
 cp -p %{pkgname}-%{version}.gemspec $RPM_BUILD_ROOT%{ruby_specdir}
 
 %clean
diff --git a/templates.patch b/templates.patch
new file mode 100644
index 0000000..1b6d558
--- /dev/null
+++ b/templates.patch
@@ -0,0 +1,11 @@
+--- ./lib/fpm/package.rb~	2015-08-10 13:11:29.000000000 +0300
++++ ./lib/fpm/package.rb	2015-08-10 13:12:44.109522857 +0300
+@@ -319,7 +319,7 @@
+   end # def files
+ 
+   def template_dir
+-    File.expand_path(File.join(File.dirname(__FILE__), "..", "..", "templates"))
++    File.expand_path(File.join(File.dirname(__FILE__), "templates"))
+   end
+ 
+   def template(path)
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/ruby-fpm.git/commitdiff/ea9475af5eb49caf75e331cb9d5eec3c439e5364



More information about the pld-cvs-commit mailing list