blob: fbf7753b02c2da21131fb0420edd2544071f24b0 [file] [log] [blame]
Patrick Williamsb48b7b42016-08-17 15:04:38 -05001SUMMARY = "Tools for managing AUFS mounts"
2SECTION = "base"
3HOMEPAGE = "http://aufs.sourceforge.net/"
Andrew Geissler9aee5002022-03-30 16:27:02 +00004LICENSE = "GPL-2.0-only"
Patrick Williamsb48b7b42016-08-17 15:04:38 -05005LIC_FILES_CHKSUM = "file://COPYING;md5=892f569a555ba9c07a568a7c0c4fa63a"
6
Brad Bishopd7bf8c12018-02-25 22:55:05 -05007DEPENDS = "coreutils-native aufs-util-native"
Patrick Williams213cb262021-08-07 19:21:33 -05008DEPENDS:class-native = ""
Patrick Williamsb48b7b42016-08-17 15:04:38 -05009
Brad Bishop1a4b7ee2018-12-16 17:11:34 -080010SRCREV = "8f35db59ef83078f87879ec2828e0bb45719e0ef"
11SRC_URI = "git://git.code.sf.net/p/aufs/aufs-util;protocol=git;branch=aufs4.9 \
12 https://raw.githubusercontent.com/sfjro/aufs4-linux/aufs4.9/include/uapi/linux/aufs_type.h;name=aufs_type \
Patrick Williamsb48b7b42016-08-17 15:04:38 -050013 file://aufs-util-don-t-strip-executables.patch \
14 file://aufs-util-add-tool-concept-to-Makefile-for-cross-com.patch \
Andrew Geissler517393d2023-01-13 08:55:19 -060015 file://0001-libau-Do-not-build-LFS-version-of-readdir.patch \
Patrick Williamsb48b7b42016-08-17 15:04:38 -050016"
Brad Bishop1a4b7ee2018-12-16 17:11:34 -080017SRC_URI[aufs_type.md5sum] = "b37129ef0703de72a852db7e48bdedc6"
18SRC_URI[aufs_type.sha256sum] = "7ff6566adb9c7a3b6862cdc85a690ab546f1d0bc81ddd595fd663c0a69031683"
Patrick Williamsb48b7b42016-08-17 15:04:38 -050019
Brad Bishop1a4b7ee2018-12-16 17:11:34 -080020UPSTREAM_CHECK_COMMITS = "1"
21
22PV = "4.9+git${SRCPV}"
Patrick Williamsb48b7b42016-08-17 15:04:38 -050023
24S = "${WORKDIR}/git"
25
Brad Bishop6e60e8b2018-02-01 10:27:11 -050026export HOSTCC = "${BUILD_CC}"
Patrick Williams213cb262021-08-07 19:21:33 -050027do_configure:prepend() {
Brad Bishop6e60e8b2018-02-01 10:27:11 -050028 # Replace sbin,bin paths with bitbake environment
29 sed -i -e 's;install_sbin: Tgt = ${DESTDIR}/sbin;install_sbin: Tgt = ${DESTDIR}/${base_sbindir};' \
30 -e 's;install_ubin: Tgt = ${DESTDIR}/usr/sbin;install_sbin: Tgt = ${DESTDIR}/${bindir};' \
31 ${S}/Makefile
32}
33
Patrick Williams213cb262021-08-07 19:21:33 -050034do_configure:append () {
Patrick Williamsb48b7b42016-08-17 15:04:38 -050035 install -d ${S}/include/linux/
36 cp ${WORKDIR}/aufs_type.h ${S}/include/linux/
Brad Bishopd7bf8c12018-02-25 22:55:05 -050037 sed -i -e 's;__user;;' ${S}/include/linux/aufs_type.h
Patrick Williamsb48b7b42016-08-17 15:04:38 -050038}
39
Patrick Williams213cb262021-08-07 19:21:33 -050040do_configure:append:class-target () {
Patrick Williamsb48b7b42016-08-17 15:04:38 -050041 for i in ver c2sh c2tmac; do
Brad Bishopd7bf8c12018-02-25 22:55:05 -050042 cp ${STAGING_BINDIR_NATIVE}/aufs-util-${PV}/$i ${B}
Patrick Williamsb48b7b42016-08-17 15:04:38 -050043 done
44}
45
46do_compile () {
47 oe_runmake CPPFLAGS="-I${S}/include -I${S}/libau"
48}
49
Patrick Williams213cb262021-08-07 19:21:33 -050050do_compile:class-native () {
Brad Bishop6e60e8b2018-02-01 10:27:11 -050051 oe_runmake tools CPPFLAGS="-I${S}/include -I${S}/libau" CC="${BUILD_CC}"
Patrick Williamsb48b7b42016-08-17 15:04:38 -050052}
53
54do_install () {
55 oe_runmake 'DESTDIR=${D}' install_sbin install_ubin install_etc
56}
57
Patrick Williams213cb262021-08-07 19:21:33 -050058do_install:class-native () {
Patrick Williamsb48b7b42016-08-17 15:04:38 -050059 install -d ${D}${bindir}/aufs-util-${PV}
60 for i in ver c2sh c2tmac; do
61 install -m 755 $i ${D}${bindir}/aufs-util-${PV}/$i
62 done
63}
64
Patrick Williams213cb262021-08-07 19:21:33 -050065RRECOMMENDS:${PN}:class-target += "kernel-module-aufs"
Patrick Williamsb48b7b42016-08-17 15:04:38 -050066
67BBCLASSEXTEND = "native"