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