summaryrefslogtreecommitdiffstats
path: root/meta/packages/cpio/cpio_v2.inc
diff options
context:
space:
mode:
Diffstat (limited to 'meta/packages/cpio/cpio_v2.inc')
-rw-r--r--meta/packages/cpio/cpio_v2.inc39
1 files changed, 39 insertions, 0 deletions
diff --git a/meta/packages/cpio/cpio_v2.inc b/meta/packages/cpio/cpio_v2.inc
new file mode 100644
index 0000000000..b571986ef7
--- /dev/null
+++ b/meta/packages/cpio/cpio_v2.inc
@@ -0,0 +1,39 @@
1DESCRIPTION = "GNU cpio is a program to manage archives of files"
2HOMEPAGE = "http://www.gnu.org/software/cpio/"
3SECTION = "base"
4
5DEPENDS = "texinfo-native"
6
7SRC_URI = "${GNU_MIRROR}/cpio/cpio-${PV}.tar.gz \
8 file://statdef.patch \
9 "
10
11inherit autotools gettext
12
13S = "${WORKDIR}/cpio-${PV}"
14
15do_install () {
16 autotools_do_install
17 install -d ${D}${base_bindir}/
18 mv "${D}${bindir}/cpio" "${D}${base_bindir}/cpio.${PN}"
19 case ${TARGET_OS} in
20 *-uclibc*) ;;
21 *) mv "${D}${libexecdir}/rmt" "${D}${libexecdir}/rmt.${PN}" ;;
22 esac
23}
24
25pkg_postinst_${PN} () {
26 update-alternatives --install ${base_bindir}/cpio cpio cpio.${PN} 100
27 if [ -f ${libexecdir}/rmt.${PN} ]
28 then
29 update-alternatives --install ${libexecdir}/rmt rmt rmt.${PN} 50
30 fi
31}
32
33pkg_prerm_${PN} () {
34 update-alternatives --remove cpio cpio.${PN}
35 if [ -f ${libexecdir}/rmt.${PN} ]
36 then
37 update-alternatives --remove rmt rmt.${PN}
38 fi
39}