]> git.pld-linux.org Git - packages/xpm.git/commitdiff
add templates dir
authorElan Ruusamäe <glen@delfi.ee>
Mon, 10 Aug 2015 11:36:55 +0000 (14:36 +0300)
committerElan Ruusamäe <glen@delfi.ee>
Mon, 10 Aug 2015 11:36:55 +0000 (14:36 +0300)
templates.patch [new file with mode: 0644]
xpm.spec

diff --git a/templates.patch b/templates.patch
new file mode 100644 (file)
index 0000000..1b6d558
--- /dev/null
@@ -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)
index a546d661ba8cde57576662f6f04fb0b2aced39b4..f591a2501bd1d62ce607fe4074b73761af307432 100644 (file)
--- a/xpm.spec
+++ b/xpm.spec
@@ -5,11 +5,12 @@
 Summary:       Cross package maker. DEB/RPM generation or conversion
 Name:          xpm
 Version:       1.3.3.6
-Release:       0.1
+Release:       0.2
 License:       MIT-like
 Group:         Development/Languages
 Source0:       http://fossil.include-once.org/xpm/tarball/%{name}-%{version}.tar.gz?uuid=v%{version}&/%{name}-%{version}.tar.gz
 # Source0-md5: f73ececfa6725965fc41d4e11ea85992
+Patch0:        templates.patch
 URL:           http://fossil.include-once.org/xpm/
 BuildRequires: rpm-rubyprov
 BuildRequires: rpmbuild(macros) >= 1.656
@@ -48,12 +49,17 @@ It creates or converts between:
 
 %prep
 %setup -q
+%patch0 -p1
 %{__sed} -i -e '1 s,#!.*ruby,#!%{__ruby},' bin/*
 
+# cleanup backups after patching
+find '(' -name '*~' -o -name '*.orig' ')' -print0 | xargs -0 -r -l512 rm -f
+
 %install
 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 templates $RPM_BUILD_ROOT%{ruby_vendorlibdir}/fpm
 cp -a bin/* $RPM_BUILD_ROOT%{_bindir}
 
 %clean
This page took 0.220974 seconds and 4 git commands to generate.