1 |
commit: b7d663b659bc77d0cd576ed82e80bfffedbfcd74 |
2 |
Author: Georgy Yakovlev <gyakovlev <AT> gentoo <DOT> org> |
3 |
AuthorDate: Fri Jan 24 05:29:01 2020 +0000 |
4 |
Commit: Georgy Yakovlev <gyakovlev <AT> gentoo <DOT> org> |
5 |
CommitDate: Fri Jan 24 07:03:51 2020 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=b7d663b6 |
7 |
|
8 |
sys-fs/zfs-kmod: bump to 0.8.3 |
9 |
|
10 |
Package-Manager: Portage-2.3.85, Repoman-2.3.20 |
11 |
Signed-off-by: Georgy Yakovlev <gyakovlev <AT> gentoo.org> |
12 |
|
13 |
sys-fs/zfs-kmod/Manifest | 1 + |
14 |
sys-fs/zfs-kmod/zfs-kmod-0.8.3.ebuild | 171 ++++++++++++++++++++++++++++++++++ |
15 |
2 files changed, 172 insertions(+) |
16 |
|
17 |
diff --git a/sys-fs/zfs-kmod/Manifest b/sys-fs/zfs-kmod/Manifest |
18 |
index b0e4dc7805b..84cfb1d2a3e 100644 |
19 |
--- a/sys-fs/zfs-kmod/Manifest |
20 |
+++ b/sys-fs/zfs-kmod/Manifest |
21 |
@@ -1,2 +1,3 @@ |
22 |
DIST zfs-0.7.13.tar.gz 6614047 BLAKE2B c59c46287715779eb04d69333b0a417fa9865eb0d61c642b043188c4c97d4eed369f76a48327326ed1d4dd608ff95d91d20d26c80ed0b120a8fcd5f83cea638f SHA512 457d8f110b68c9656194cd3738b216d5d807d680e5cfc6ed1f3cf5ebde67860476387c6b862ba3ba7f972d8945075963e6c325543ab84468e3eff5dbce68476e |
23 |
DIST zfs-0.8.2.tar.gz 8738111 BLAKE2B 5c15f6664ca70f0deeb5b9e32f2bcff68f9821529e5203ff18612ce88473fee9af369354c442f3db7882d301cf17c805c9635b05bfd3460833ed8e5ff8004dd0 SHA512 1424b1a030b814f812b5da422100669db5b8c3ccae14c2fdd62a5e0df28e7255247fe5ca99c95a14f08c92cc1574c22dd132093e4a1dd81e38c95b10cc5e2496 |
24 |
+DIST zfs-0.8.3.tar.gz 8779385 BLAKE2B 8b51b9d5b61543566bc7839d8452fdf9358442155e95f93a011531338824bbd4fc8879500e276b02d5d49d504a046728ecc0c6154f69eb7b47180b9bb0e46958 SHA512 aded632e6b04180560d4f2ff283260016e883dadae4e7fda9070b7113dee948099cb7a7b183f1c8139654389a2610fb9cc6f997acdc846040e605125cf016010 |
25 |
|
26 |
diff --git a/sys-fs/zfs-kmod/zfs-kmod-0.8.3.ebuild b/sys-fs/zfs-kmod/zfs-kmod-0.8.3.ebuild |
27 |
new file mode 100644 |
28 |
index 00000000000..87090d4d5e0 |
29 |
--- /dev/null |
30 |
+++ b/sys-fs/zfs-kmod/zfs-kmod-0.8.3.ebuild |
31 |
@@ -0,0 +1,171 @@ |
32 |
+# Copyright 1999-2020 Gentoo Authors |
33 |
+# Distributed under the terms of the GNU General Public License v2 |
34 |
+ |
35 |
+EAPI=7 |
36 |
+ |
37 |
+inherit flag-o-matic linux-mod toolchain-funcs |
38 |
+ |
39 |
+DESCRIPTION="Linux ZFS kernel module for sys-fs/zfs" |
40 |
+HOMEPAGE="https://zfsonlinux.org/" |
41 |
+ |
42 |
+if [[ ${PV} == "9999" ]]; then |
43 |
+ inherit autotools git-r3 |
44 |
+ EGIT_REPO_URI="https://github.com/zfsonlinux/zfs.git" |
45 |
+else |
46 |
+ SRC_URI="https://github.com/zfsonlinux/zfs/releases/download/zfs-${PV}/zfs-${PV}.tar.gz" |
47 |
+ KEYWORDS="~amd64 ~arm64 ~ppc64" |
48 |
+ S="${WORKDIR}/zfs-${PV}" |
49 |
+ ZFS_KERNEL_COMPAT="5.4" |
50 |
+fi |
51 |
+ |
52 |
+LICENSE="CDDL debug? ( GPL-2+ )" |
53 |
+SLOT="0" |
54 |
+IUSE="custom-cflags debug +rootfs" |
55 |
+ |
56 |
+DEPEND="" |
57 |
+ |
58 |
+RDEPEND="${DEPEND} |
59 |
+ !sys-kernel/spl |
60 |
+" |
61 |
+ |
62 |
+BDEPEND=" |
63 |
+ dev-lang/perl |
64 |
+ virtual/awk |
65 |
+" |
66 |
+ |
67 |
+RESTRICT="debug? ( strip ) test" |
68 |
+ |
69 |
+DOCS=( AUTHORS COPYRIGHT META README.md ) |
70 |
+ |
71 |
+pkg_setup() { |
72 |
+ CONFIG_CHECK=" |
73 |
+ !DEBUG_LOCK_ALLOC |
74 |
+ EFI_PARTITION |
75 |
+ MODULES |
76 |
+ !PAX_KERNEXEC_PLUGIN_METHOD_OR |
77 |
+ !TRIM_UNUSED_KSYMS |
78 |
+ ZLIB_DEFLATE |
79 |
+ ZLIB_INFLATE |
80 |
+ " |
81 |
+ |
82 |
+ use debug && CONFIG_CHECK="${CONFIG_CHECK} |
83 |
+ FRAME_POINTER |
84 |
+ DEBUG_INFO |
85 |
+ !DEBUG_INFO_REDUCED |
86 |
+ " |
87 |
+ |
88 |
+ use rootfs && \ |
89 |
+ CONFIG_CHECK="${CONFIG_CHECK} |
90 |
+ BLK_DEV_INITRD |
91 |
+ DEVTMPFS |
92 |
+ " |
93 |
+ |
94 |
+ if use arm64; then |
95 |
+ kernel_is -ge 5 && CONFIG_CHECK="${CONFIG_CHECK} !PREEMPT" |
96 |
+ fi |
97 |
+ |
98 |
+ kernel_is -lt 5 && CONFIG_CHECK="${CONFIG_CHECK} IOSCHED_NOOP" |
99 |
+ |
100 |
+ kernel_is -ge 3 10 || die "Linux 3.10 or newer required" |
101 |
+ |
102 |
+ if [[ ${PV} != "9999" ]]; then |
103 |
+ local kv_major_max kv_minor_max zcompat |
104 |
+ zcompat="${ZFS_KERNEL_COMPAT_OVERRIDE:-${ZFS_KERNEL_COMPAT}}" |
105 |
+ kv_major_max="${zcompat%%.*}" |
106 |
+ zcompat="${zcompat#*.}" |
107 |
+ kv_minor_max="${zcompat%%.*}" |
108 |
+ kernel_is -le "${kv_major_max}" "${kv_minor_max}" || die \ |
109 |
+ "Linux ${kv_major_max}.${kv_minor_max} is the latest supported version" |
110 |
+ fi |
111 |
+ |
112 |
+ linux-mod_pkg_setup |
113 |
+} |
114 |
+ |
115 |
+src_prepare() { |
116 |
+ default |
117 |
+ |
118 |
+ if [[ ${PV} == "9999" ]]; then |
119 |
+ eautoreconf |
120 |
+ else |
121 |
+ # Set module revision number |
122 |
+ sed -i "s/\(Release:\)\(.*\)1/\1\2${PR}-gentoo/" META || die "Could not set Gentoo release" |
123 |
+ fi |
124 |
+} |
125 |
+ |
126 |
+src_configure() { |
127 |
+ set_arch_to_kernel |
128 |
+ |
129 |
+ use custom-cflags || strip-flags |
130 |
+ |
131 |
+ filter-ldflags -Wl,* |
132 |
+ |
133 |
+ local myconf=( |
134 |
+ --bindir="${EPREFIX}/bin" |
135 |
+ --sbindir="${EPREFIX}/sbin" |
136 |
+ --with-config=kernel |
137 |
+ --with-linux="${KV_DIR}" |
138 |
+ --with-linux-obj="${KV_OUT_DIR}" |
139 |
+ $(use_enable debug) |
140 |
+ ) |
141 |
+ |
142 |
+ econf "${myconf[@]}" |
143 |
+} |
144 |
+ |
145 |
+src_compile() { |
146 |
+ set_arch_to_kernel |
147 |
+ |
148 |
+ myemakeargs=( V=1 ) |
149 |
+ |
150 |
+ emake "${myemakeargs[@]}" |
151 |
+} |
152 |
+ |
153 |
+src_install() { |
154 |
+ set_arch_to_kernel |
155 |
+ |
156 |
+ myemakeargs+=( |
157 |
+ DEPMOD="/bin/true" |
158 |
+ DESTDIR="${D}" |
159 |
+ INSTALL_MOD_PATH="${INSTALL_MOD_PATH:-$EROOT}" |
160 |
+ ) |
161 |
+ |
162 |
+ emake "${myemakeargs[@]}" install |
163 |
+ |
164 |
+ einstalldocs |
165 |
+} |
166 |
+ |
167 |
+pkg_postinst() { |
168 |
+ linux-mod_pkg_postinst |
169 |
+ |
170 |
+ # Remove old modules |
171 |
+ if [[ -d "${EROOT}/lib/modules/${KV_FULL}/addon/zfs" ]]; then |
172 |
+ ewarn "${PN} now installs modules in ${EROOT}/lib/modules/${KV_FULL}/extra/zfs" |
173 |
+ ewarn "Old modules were detected in ${EROOT}/lib/modules/${KV_FULL}/addon/zfs" |
174 |
+ ewarn "Automatically removing old modules to avoid problems." |
175 |
+ rm -r "${EROOT}/lib/modules/${KV_FULL}/addon/zfs" || die "Cannot remove modules" |
176 |
+ rmdir --ignore-fail-on-non-empty "${EROOT}/lib/modules/${KV_FULL}/addon" |
177 |
+ fi |
178 |
+ |
179 |
+ if use x86 || use arm; then |
180 |
+ ewarn "32-bit kernels will likely require increasing vmalloc to" |
181 |
+ ewarn "at least 256M and decreasing zfs_arc_max to some value less than that." |
182 |
+ fi |
183 |
+ |
184 |
+ ewarn "This version of ZFSOnLinux includes support for new feature flags" |
185 |
+ ewarn "that are incompatible with previous versions. GRUB2 support for" |
186 |
+ ewarn "/boot with the new feature flags is not yet available." |
187 |
+ ewarn "Do *NOT* upgrade root pools to use the new feature flags." |
188 |
+ ewarn "Any new pools will be created with the new feature flags by default" |
189 |
+ ewarn "and will not be compatible with older versions of ZFSOnLinux. To" |
190 |
+ ewarn "create a newpool that is backward compatible wih GRUB2, use " |
191 |
+ ewarn |
192 |
+ ewarn "zpool create -d -o feature@async_destroy=enabled " |
193 |
+ ewarn " -o feature@empty_bpobj=enabled -o feature@lz4_compress=enabled" |
194 |
+ ewarn " -o feature@spacemap_histogram=enabled" |
195 |
+ ewarn " -o feature@enabled_txg=enabled " |
196 |
+ ewarn " -o feature@extensible_dataset=enabled -o feature@bookmarks=enabled" |
197 |
+ ewarn " ..." |
198 |
+ ewarn |
199 |
+ ewarn "GRUB2 support will be updated as soon as either the GRUB2" |
200 |
+ ewarn "developers do a tag or the Gentoo developers find time to backport" |
201 |
+ ewarn "support from GRUB2 HEAD." |
202 |
+} |