1 # Copyright 1999-2015 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
8 K_WANT_GENPATCHES="base extras experimental"
10 K_DEBLOB_AVAILABLE="1"
11 UNIPATCH_STRICTORDER=1
12 inherit kernel-2 eutils readme.gentoo
16 AUFS_VERSION=4.0_p20150629
17 AUFS_TARBALL="aufs-sources-${AUFS_VERSION}.tar.xz"
18 # git archive -v --remote=git://git.code.sf.net/p/aufs/aufs4-standalone aufs${AUFS_VERSION/_p*} > aufs-sources-${AUFS_VERSION}.tar
19 AUFS_URI="https://dev.gentoo.org/~jlec/distfiles/${AUFS_TARBALL}"
21 KEYWORDS="~amd64 ~x86"
22 HOMEPAGE="https://dev.gentoo.org/~mpagano/genpatches http://aufs.sourceforge.net/"
23 IUSE="deblob experimental module vanilla"
25 DESCRIPTION="Full sources including the Gentoo patchset for the ${KV_MAJOR}.${KV_MINOR} kernel tree and aufs4 support"
30 !vanilla? ( ${GENPATCHES_URI} )
33 PDEPEND="=sys-fs/aufs-util-4*"
35 README_GENTOO_SUFFIX="-r1"
39 unset UNIPATCH_LIST_GENPATCHES UNIPATCH_LIST_DEFAULT
40 ewarn "You are using USE=vanilla"
41 ewarn "This will drop all support from the gentoo kernel security team"
45 "${WORKDIR}"/aufs4-kbuild.patch
46 "${WORKDIR}"/aufs4-base.patch
47 "${WORKDIR}"/aufs4-mmap.patch"
49 use module && UNIPATCH_LIST+=" "${WORKDIR}"/aufs4-standalone.patch"
51 unpack ${AUFS_TARBALL}
53 einfo "Using aufs4 version: ${AUFS_VERSION}"
60 sed -e 's:tristate:bool:g' -i "${WORKDIR}"/fs/aufs/Kconfig || die
62 cp -f "${WORKDIR}"/include/uapi/linux/aufs_type.h include/uapi/linux/aufs_type.h || die
63 cp -rf "${WORKDIR}"/{Documentation,fs} . || die
68 dodoc "${WORKDIR}"/{aufs4-loopback,vfs-ino,tmpfs-idr}.patch
69 docompress -x /usr/share/doc/${PF}/{aufs4-loopback,vfs-ino,tmpfs-idr}.patch
70 readme.gentoo_create_doc
75 einfo "For more info on this patchset, and how to report problems, see:"
77 has_version sys-fs/aufs-util || \
78 elog "In order to use aufs FS you need to install sys-fs/aufs-util"
80 readme.gentoo_pkg_postinst