[packages/bchunk] up to 1.2.2

atler atler at pld-linux.org
Wed Nov 25 19:22:07 CET 2020


commit ecafdc58818fb817e18bdd15427959bd94c2eac8
Author: Jan Palus <atler at pld-linux.org>
Date:   Wed Nov 25 19:21:00 2020 +0100

    up to 1.2.2
    
    - updated urls
    - upstream patch for DESTDIR installation

 bchunk.spec   | 24 ++++++++++++++++--------
 install.patch | 40 ++++++++++++++++++++++++++++++++++++++++
 2 files changed, 56 insertions(+), 8 deletions(-)
---
diff --git a/bchunk.spec b/bchunk.spec
index 9b43679..28aed91 100644
--- a/bchunk.spec
+++ b/bchunk.spec
@@ -1,13 +1,14 @@
 Summary:	A CD image format converter from .bin/.cue to .iso/.cdr
 Summary(pl.UTF-8):	Konwerter obrazów płyt CD z .bin/.cue do .iso/.cdr
 Name:		bchunk
-Version:	1.2.0
-Release:	0.1
+Version:	1.2.2
+Release:	1
 License:	GPL
 Group:		Applications/Archiving
-Source0:	http://hes.iki.fi/bchunk/%{name}-%{version}.tar.gz
-# Source0-md5:	6a613da3f34f9a303f202d2e9731d231
-URL:		http://hes.iki.fi/bchunk/
+Source0:	http://he.fi/bchunk/%{name}-%{version}.tar.gz
+# Source0-md5:	0eeb764647824062085872ddb0b28c5a
+Patch0:		install.patch
+URL:		http://he.fi/bchunk/
 BuildRoot:	%{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 
 %description
@@ -25,15 +26,21 @@ obsługiwany przez większość uniksowych programów do wypalania.
 
 %prep
 %setup -q
+%patch0 -p1
 
 %build
-%{__cc} %{rpmcflags} %{name}.c -o %{name}
+%{__make} \
+	CC="%{__cc}" \
+        LD="%{__cc}" \
+        CFLAGS="%{rpmcflags}"
 
 %install
 rm -rf $RPM_BUILD_ROOT
-install -d $RPM_BUILD_ROOT%{_bindir}
 
-install bchunk $RPM_BUILD_ROOT%{_bindir}
+%{__make} install \
+	DESTDIR=$RPM_BUILD_ROOT \
+	BIN_DIR=%{_bindir} \
+	MAN_DIR=%{_mandir}
 
 %clean
 rm -rf $RPM_BUILD_ROOT
@@ -42,3 +49,4 @@ rm -rf $RPM_BUILD_ROOT
 %defattr(644,root,root,755)
 %doc ChangeLog README
 %attr(755,root,root) %{_bindir}/bchunk
+%{_mandir}/man1/bchunk.1*
diff --git a/install.patch b/install.patch
new file mode 100644
index 0000000..b764208
--- /dev/null
+++ b/install.patch
@@ -0,0 +1,40 @@
+From 5423c2ad6839976308e3e90f89697107b9bf29f7 Mon Sep 17 00:00:00 2001
+From: Dan Church <amphetamachine at gmail.com>
+Date: Wed, 26 Feb 2020 10:12:07 -0600
+Subject: [PATCH] Allow installation into build jail
+
+Don't chown files when installing, as that's a root-only op. Uses the
+standard DESTDIR variable used all over by makefiles generated by
+autotools.
+---
+ Makefile | 9 +++++++--
+ 1 file changed, 7 insertions(+), 2 deletions(-)
+
+diff --git a/Makefile b/Makefile
+index 1124a21..49928d2 100644
+--- a/Makefile
++++ b/Makefile
+@@ -12,6 +12,9 @@ CFLAGS = -Wall -Wstrict-prototypes -O2
+ 
+ # For BSD install: Which install to use and where to put the files
+ INSTALL = install
++INSTALL_DIR = $(INSTALL) -d -m 0755
++INSTALL_DATA = $(INSTALL) -m 0644
++INSTALL_EXEC = $(INSTALL) -m 0755
+ PREFIX  = /usr/local
+ BIN_DIR = $(PREFIX)/bin
+ MAN_DIR = $(PREFIX)/man
+@@ -26,9 +29,11 @@ distclean: clean
+ 
+ install: installbin installman
+ installbin:
+-	$(INSTALL) -m 755 -s -o root -g root bchunk		$(BIN_DIR)
++	$(INSTALL_DIR) $(DESTDIR)$(BIN_DIR)
++	$(INSTALL_EXEC) -s bchunk $(DESTDIR)$(BIN_DIR)
+ installman:
+-	$(INSTALL) -m 644 -o bin -g bin bchunk.1	 	$(MAN_DIR)/man1
++	$(INSTALL_DIR) $(DESTDIR)$(MAN_DIR)/man1
++	$(INSTALL_DATA) bchunk.1 $(DESTDIR)$(MAN_DIR)/man1
+ 
+ BITS = bchunk.o
+ 
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/bchunk.git/commitdiff/ecafdc58818fb817e18bdd15427959bd94c2eac8



More information about the pld-cvs-commit mailing list