Browse code

First commit

Qurban Ullah authored on 27/02/2018 17:46:58
Showing 3 changed files
1 1
new file mode 100755
... ...
@@ -0,0 +1,31 @@
1
+# $Id$
2
+# Maintainer: Qurban Ullah <qurbanullah@avouch.org>
3
+# Contributor: Qurban Ullah <qurbanullah@avouch.org>
4
+
5
+pkgname=cpio
6
+pkgver=2.12
7
+pkgrel=1
8
+pkgdesc="A tool to copy files into or out of a cpio or tar archive"
9
+arch=(i686 x86_64)
10
+license=('GPL')
11
+url="http://www.gnu.org/software/cpio"
12
+depends=('glibc')
13
+source=(ftp://ftp.gnu.org/gnu/cpio/cpio-${pkgver}.tar.gz
14
+        cpio-2.11-stdio.in.patch)
15
+install=cpio.install
16
+
17
+build() {
18
+	cd "${srcdir}/${pkgname}-${pkgver}"
19
+	./configure --prefix=/usr --mandir=/usr/share/man
20
+	make
21
+}
22
+
23
+package() {
24
+	cd "${srcdir}/${pkgname}-${pkgver}"
25
+	make DESTDIR=${pkgdir} install
26
+
27
+
28
+	rm -f ${pkgdir}/usr/bin/mt ${pkgdir}/usr/share/man/man1/mt.1
29
+	rm -rf ${pkgdir}/usr/libexec
30
+}
31
+
0 32
new file mode 100755
... ...
@@ -0,0 +1,13 @@
1
+diff -urNp cpio-2.11-orig/gnu/stdio.in.h cpio-2.11/gnu/stdio.in.h
2
+--- cpio-2.11-orig/gnu/stdio.in.h	2010-03-10 10:27:03.000000000 +0100
3
+@@ -139,7 +139,9 @@ _GL_WARN_ON_USE (fflush, "fflush is not 
4
+    so any use of gets warrants an unconditional warning.  Assume it is
5
+    always declared, since it is required by C89.  */
6
+ #undef gets
7
++#if HAVE_RAW_DECL_GETS
8
+ _GL_WARN_ON_USE (gets, "gets is a security hole - use fgets instead");
9
++#endif
10
+ 
11
+ #if @GNULIB_FOPEN@
12
+ # if @REPLACE_FOPEN@
0 13
new file mode 100755
... ...
@@ -0,0 +1,21 @@
1
+infodir=/usr/share/info
2
+filelist=(cpio.info)
3
+
4
+post_install() {
5
+ [ -x usr/bin/install-info ] || return 0
6
+ for file in ${filelist[@]}; do
7
+    usr/bin/install-info $infodir/$file $infodir/dir 2> /dev/null
8
+ done
9
+}
10
+
11
+post_upgrade() {
12
+  post_install $1
13
+}
14
+
15
+pre_remove() {
16
+ [ -x usr/bin/install-info ] || return 0
17
+  for file in ${filelist[@]}; do
18
+    usr/bin/install-info --delete $infodir/$file $infodir/dir 2> /dev/null
19
+  done
20
+}
21
+