Gentoo Archives: gentoo-commits

From: "Justin Lecher (jlec)" <jlec@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] gentoo-x86 commit in sys-fs/aufs4: aufs4-0_pre20150629.ebuild ChangeLog
Date: Mon, 29 Jun 2015 07:10:38
Message-Id: 20150629071016.CD991739@oystercatcher.gentoo.org
1 jlec 15/06/29 07:10:16
2
3 Modified: ChangeLog
4 Added: aufs4-0_pre20150629.ebuild
5 Log:
6 Bump to latest aufs release
7
8 (Portage version: 2.2.20/cvs/Linux x86_64, signed Manifest commit with key E9402A79B03529A2!)
9
10 Revision Changes Path
11 1.8 sys-fs/aufs4/ChangeLog
12
13 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/sys-fs/aufs4/ChangeLog?rev=1.8&view=markup
14 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/sys-fs/aufs4/ChangeLog?rev=1.8&content-type=text/plain
15 diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/sys-fs/aufs4/ChangeLog?r1=1.7&r2=1.8
16
17 Index: ChangeLog
18 ===================================================================
19 RCS file: /var/cvsroot/gentoo-x86/sys-fs/aufs4/ChangeLog,v
20 retrieving revision 1.7
21 retrieving revision 1.8
22 diff -u -r1.7 -r1.8
23 --- ChangeLog 22 Jun 2015 08:07:15 -0000 1.7
24 +++ ChangeLog 29 Jun 2015 07:10:16 -0000 1.8
25 @@ -1,6 +1,11 @@
26 # ChangeLog for sys-fs/aufs4
27 # Copyright 1999-2015 Gentoo Foundation; Distributed under the GPL v2
28 -# $Header: /var/cvsroot/gentoo-x86/sys-fs/aufs4/ChangeLog,v 1.7 2015/06/22 08:07:15 jlec Exp $
29 +# $Header: /var/cvsroot/gentoo-x86/sys-fs/aufs4/ChangeLog,v 1.8 2015/06/29 07:10:16 jlec Exp $
30 +
31 +*aufs4-0_pre20150629 (29 Jun 2015)
32 +
33 + 29 Jun 2015; Justin Lecher <jlec@g.o> +aufs4-0_pre20150629.ebuild:
34 + Bump to latest aufs release
35
36 *aufs4-0_pre20150622 (22 Jun 2015)
37
38
39
40
41 1.1 sys-fs/aufs4/aufs4-0_pre20150629.ebuild
42
43 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/sys-fs/aufs4/aufs4-0_pre20150629.ebuild?rev=1.1&view=markup
44 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/sys-fs/aufs4/aufs4-0_pre20150629.ebuild?rev=1.1&content-type=text/plain
45
46 Index: aufs4-0_pre20150629.ebuild
47 ===================================================================
48 # Copyright 1999-2015 Gentoo Foundation
49 # Distributed under the terms of the GNU General Public License v2
50 # $Header: /var/cvsroot/gentoo-x86/sys-fs/aufs4/aufs4-0_pre20150629.ebuild,v 1.1 2015/06/29 07:10:16 jlec Exp $
51
52 EAPI=5
53
54 inherit eutils flag-o-matic linux-info linux-mod multilib readme.gentoo toolchain-funcs
55
56 AUFS_VERSION="${PV%%_p*}"
57 # highest branch version
58 PATCH_MAX_VER=1
59 # highest supported version
60 KERN_MAX_VER=2
61 # lowest supported version
62 KERN_MIN_VER=0
63
64 DESCRIPTION="An entirely re-designed and re-implemented Unionfs"
65 HOMEPAGE="http://aufs.sourceforge.net/"
66 SRC_URI="http://dev.gentoo.org/~jlec/distfiles/aufs4-standalone-${PV}.tar.xz"
67
68 LICENSE="GPL-2"
69 SLOT="0"
70 KEYWORDS="~amd64 ~x86"
71 IUSE="debug doc fuse hfs inotify kernel-patch nfs pax_kernel ramfs"
72
73 DEPEND="
74 dev-util/patchutils
75 dev-vcs/git"
76 RDEPEND="
77 sys-fs/aufs-util
78 !sys-fs/aufs
79 !sys-fs/aufs2
80 !sys-fs/aufs3"
81
82 S="${WORKDIR}"/${PN}-standalone
83
84 MODULE_NAMES="aufs(misc:${S})"
85
86 pkg_setup() {
87 CONFIG_CHECK+=" !AUFS_FS"
88 use inotify && CONFIG_CHECK+=" ~FSNOTIFY"
89 use nfs && CONFIG_CHECK+=" EXPORTFS"
90 use fuse && CONFIG_CHECK+=" ~FUSE_FS"
91 use hfs && CONFIG_CHECK+=" ~HFSPLUS_FS"
92 use pax_kernel && CONFIG_CHECK+=" PAX" && ERROR_PAX="Please use hardened sources"
93
94 # this is needed so merging a binpkg ${PN} is possible w/out a kernel unpacked on the system
95 [ -n "$PKG_SETUP_HAS_BEEN_RAN" ] && return
96
97 get_version
98 kernel_is lt 4 ${KERN_MIN_VER} 0 && die "the kernel version isn't supported by upstream anymore. Please upgrade."
99 kernel_is gt 4 ${KERN_MAX_VER} 99 && die "kernel too new"
100
101 linux-mod_pkg_setup
102
103 if [[ "${KV_MINOR}" -gt "${PATCH_MAX_VER}" ]]; then
104 PATCH_BRANCH="x-rcN"
105 else
106 PATCH_BRANCH="${KV_MINOR}"
107 fi
108
109 case ${KV_EXTRA} in
110 "")
111 elog "It seems you are using vanilla-sources with aufs4"
112 elog "Please use sys-kernel/aufs-sources with USE=vanilla"
113 elog "This will save you the nasty reemerge of sys-fs/aufs4 on every kernel upgrade"
114 ;;
115 "-gentoo")
116 elog "It seems you are using gentoo-sources with aufs4"
117 elog "Please use sys-kernel/aufs-sources"
118 elog "This will save you the nasty reemerge of sys-fs/aufs4 on every kernel upgrade"
119 ;;
120 esac
121
122 pushd "${T}" &> /dev/null
123 unpack ${A}
124 cd ${PN}-standalone || die
125 local module_branch=origin/${PN}.${PATCH_BRANCH}
126 einfo "Using ${module_branch} as patch source"
127 git checkout -q -b local-${PN}.${PATCH_BRANCH} ${module_branch} || die
128 combinediff ${PN}-base.patch ${PN}-standalone.patch > "${T}"/combined-1.patch
129 combinediff "${T}"/combined-1.patch ${PN}-mmap.patch > ${PN}-standalone-base-mmap-combined.patch
130 if ! ( patch -p1 --dry-run --force -R -d ${KV_DIR} < ${PN}-standalone-base-mmap-combined.patch > /dev/null ); then
131 if use kernel-patch; then
132 cd ${KV_DIR}
133 ewarn "Patching your kernel..."
134 patch --no-backup-if-mismatch --force -p1 -R -d ${KV_DIR} < "${T}"/${PN}-standalone/${PN}-standalone-base-mmap-combined.patch >/dev/null
135 epatch "${T}"/${PN}-standalone/${PN}-standalone-base-mmap-combined.patch
136 ewarn "You need to compile your kernel with the applied patch"
137 ewarn "to be able to load and use the aufs kernel module"
138 else
139 eerror "You need to apply a patch to your kernel to compile and run the ${PN} module"
140 eerror "Either enable the kernel-patch useflag to do it with this ebuild"
141 eerror "or apply "${T}"/${PN}-standalone/${PN}-standalone-base-mmap-combined.patch by hand"
142 die "missing kernel patch, please apply it first"
143 fi
144 fi
145 popd &> /dev/null
146 export PKG_SETUP_HAS_BEEN_RAN=1
147 }
148
149 set_config() {
150 for option in $*; do
151 grep -q "^CONFIG_AUFS_${option} =" config.mk || die "${option} is not a valid config option"
152 sed "/^CONFIG_AUFS_${option}/s:=:= y:g" -i config.mk || die
153 done
154 }
155
156 src_prepare() {
157 local module_branch=origin/${PN}.${PATCH_BRANCH}
158
159 einfo "Using for module creation branch ${module_branch}"
160 git checkout -q -b local-gentoo ${module_branch} || die
161
162 # All config options to off
163 sed "s:= y:=:g" -i config.mk || die
164
165 set_config RDU BRANCH_MAX_127 SBILIST
166
167 use debug && set_config DEBUG
168 use fuse && set_config BR_FUSE POLL
169 use hfs && set_config BR_HFSPLUS
170 use inotify && set_config HNOTIFY HFSNOTIFY
171 use nfs && set_config EXPORT
172 use nfs && ( use amd64 || use ppc64 ) && set_config INO_T_64
173 use ramfs && set_config BR_RAMFS
174
175 if use pax_kernel; then
176 epatch "${FILESDIR}"/pax-4.patch
177 fi
178
179 sed -i "s:aufs.ko usr/include/linux/aufs_type.h:aufs.ko:g" Makefile || die
180 }
181
182 src_compile() {
183 local ARCH=x86
184
185 emake \
186 CC=$(tc-getCC) \
187 LD=$(tc-getLD) \
188 LDFLAGS="$(raw-ldflags)" \
189 ARCH=$(tc-arch-kernel) \
190 CONFIG_AUFS_FS=m \
191 KDIR="${KV_OUT_DIR}"
192 }
193
194 src_install() {
195 linux-mod_src_install
196
197 insinto /usr/share/doc/${PF}
198
199 use doc && doins -r Documentation
200
201 use kernel-patch || doins "${T}"/${PN}-standalone/${PN}-standalone-base-mmap-combined.patch
202
203 dodoc Documentation/filesystems/aufs/README "${T}"/${PN}-standalone/{aufs4-loopback,vfs-ino,tmpfs-idr}.patch
204
205 readme.gentoo_create_doc
206 }
207
208 pkg_postinst() {
209 readme.gentoo_pkg_postinst
210 linux-mod_pkg_postinst
211 }