1 |
commit: 9fe92e88ca28ae64afd09611e92f6a21700a1ac8 |
2 |
Author: Marty E. Plummer <hanetzer <AT> startmail <DOT> com> |
3 |
AuthorDate: Sun Jan 20 19:52:51 2019 +0000 |
4 |
Commit: Anthony G. Basile <blueness <AT> gentoo <DOT> org> |
5 |
CommitDate: Sun Jan 20 21:02:37 2019 +0000 |
6 |
URL: https://gitweb.gentoo.org/proj/musl.git/commit/?id=9fe92e88 |
7 |
|
8 |
sys-kernel/dracut: version bump to 048 |
9 |
|
10 |
Package-Manager: Portage-2.3.56, Repoman-2.3.12 |
11 |
Signed-off-by: Anthony G. Basile <blueness <AT> gentoo.org> |
12 |
|
13 |
sys-kernel/dracut/Manifest | 1 + |
14 |
sys-kernel/dracut/dracut-048-r1.ebuild | 154 +++++++++++++++++++++ |
15 |
...dracut-install-simplify-ldd-parsing-logic.patch | 41 ++++++ |
16 |
3 files changed, 196 insertions(+) |
17 |
|
18 |
diff --git a/sys-kernel/dracut/Manifest b/sys-kernel/dracut/Manifest |
19 |
index 71ff6ad..4de5b6f 100644 |
20 |
--- a/sys-kernel/dracut/Manifest |
21 |
+++ b/sys-kernel/dracut/Manifest |
22 |
@@ -1,3 +1,4 @@ |
23 |
DIST dracut-045.tar.xz 292652 BLAKE2B 0e7c57ddca6757d59823afdc4ff23dcb06cc9cec317ece8cca14c5b6dfd2a7984fb8e857f5f48ad61922ba11b4b68944b366bddb02552efb52375f6e12802de7 SHA512 b57aab1f6fbdd5ad52a13a0eb99937b1abcd11507a2a3e6ec9bcb94e578cc32edc01a814ea2cef93158c27c17e3e40bcdd32a66457a20363f8136b8b546bbb4a |
24 |
DIST dracut-046.tar.xz 299520 BLAKE2B 1e2d848aa0db0e90734d8c60610a60b1f0ff67f8c4d4f9933bec0bc1290071b1b1ee3cdb6c3da5b82d8f6d4cc7561ee17d38685659a4a6ee48a9085e388dfced SHA512 75cefc184960024ef32f7bb5a0fe060e9c7d82dbfd0fe247d54b585e2ebbf0f8af5d5dc1be7e5e8cf2c3bc27b3293842c6361ae62d047289d0c59d7d40b09122 |
25 |
DIST dracut-047.tar.xz 305836 BLAKE2B 18333ae1e24cfbbb6a152bf9ba2c48884821f6a506344259ba56c581a9f3efac7b4c88e8ca149ef1f83347a5e4d59acba61e42b8e0ab3a9e9beb8684d5db28b0 SHA512 03369726b6c2b682d0c9dead7b7dbd1c3989aaf2b4a561015634d33a94e5230d03cb634c3890191b19dd8c1c83389533ae1a46d45d2024ba885e0d2d46c5d035 |
26 |
+DIST dracut-048.tar.xz 308484 BLAKE2B b19c8122034a8b40cbc9d09245730900b59691c336f1d231e768786ad64068e0a8daf57ae9a4182ab50d9e1c683c9b7dcac354eb26d8a60f061db78121bc11c7 SHA512 97fcfd5d314ef40687c245d95d2f1d0f3f9ff0472e66b6e6324bf9bd6b98186104f9d71fd9af344126d6ea9fa47b744d52831a374225633225f6f17fb15c04e0 |
27 |
|
28 |
diff --git a/sys-kernel/dracut/dracut-048-r1.ebuild b/sys-kernel/dracut/dracut-048-r1.ebuild |
29 |
new file mode 100644 |
30 |
index 0000000..b3796a7 |
31 |
--- /dev/null |
32 |
+++ b/sys-kernel/dracut/dracut-048-r1.ebuild |
33 |
@@ -0,0 +1,154 @@ |
34 |
+# Copyright 1999-2019 Gentoo Authors |
35 |
+# Distributed under the terms of the GNU General Public License v2 |
36 |
+ |
37 |
+EAPI=6 |
38 |
+ |
39 |
+inherit bash-completion-r1 eutils linux-info systemd toolchain-funcs |
40 |
+ |
41 |
+DESCRIPTION="Generic initramfs generation tool" |
42 |
+HOMEPAGE="https://dracut.wiki.kernel.org" |
43 |
+SRC_URI="mirror://kernel/linux/utils/boot/${PN}/${P}.tar.xz" |
44 |
+ |
45 |
+LICENSE="GPL-2" |
46 |
+SLOT="0" |
47 |
+KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~ia64 ~mips ~ppc ~ppc64 ~sparc ~x86" |
48 |
+IUSE="debug selinux" |
49 |
+ |
50 |
+# Tests need root privileges, bug #298014 |
51 |
+RESTRICT="test" |
52 |
+ |
53 |
+COMMON_DEPEND=">=sys-apps/kmod-23[tools] |
54 |
+ virtual/pkgconfig |
55 |
+ virtual/udev |
56 |
+ " |
57 |
+RDEPEND="${COMMON_DEPEND} |
58 |
+ app-arch/cpio |
59 |
+ >=app-shells/bash-4.0:0 |
60 |
+ sys-apps/coreutils[xattr(-)] |
61 |
+ || ( |
62 |
+ >=sys-apps/sysvinit-2.87-r3 |
63 |
+ sys-apps/systemd[sysv-utils] |
64 |
+ ) |
65 |
+ >=sys-apps/util-linux-2.21 |
66 |
+ |
67 |
+ debug? ( dev-util/strace ) |
68 |
+ elibc_musl? ( sys-libs/fts-standalone ) |
69 |
+ selinux? ( |
70 |
+ sec-policy/selinux-dracut |
71 |
+ sys-libs/libselinux |
72 |
+ sys-libs/libsepol |
73 |
+ ) |
74 |
+ " |
75 |
+DEPEND="${COMMON_DEPEND} |
76 |
+ app-text/asciidoc |
77 |
+ app-text/docbook-xml-dtd:4.5 |
78 |
+ >=app-text/docbook-xsl-stylesheets-1.75.2 |
79 |
+ >=dev-libs/libxslt-1.1.26 |
80 |
+ " |
81 |
+ |
82 |
+DOCS=( AUTHORS HACKING NEWS README README.generic README.kernel README.modules |
83 |
+ README.testsuite TODO ) |
84 |
+ |
85 |
+QA_MULTILIB_PATHS="usr/lib/dracut/.*" |
86 |
+ |
87 |
+PATCHES=( |
88 |
+ "${FILESDIR}"/048-dracut-install-simplify-ldd-parsing-logic.patch |
89 |
+ "${FILESDIR}"/${PN}-047-libfts.patch |
90 |
+) |
91 |
+ |
92 |
+src_configure() { |
93 |
+ local myconf=( |
94 |
+ --prefix="${EPREFIX}/usr" |
95 |
+ --sysconfdir="${EPREFIX}/etc" |
96 |
+ --bashcompletiondir="$(get_bashcompdir)" |
97 |
+ --systemdsystemunitdir="$(systemd_get_systemunitdir)" |
98 |
+ ) |
99 |
+ |
100 |
+ tc-export CC PKG_CONFIG |
101 |
+ |
102 |
+ echo ./configure "${myconf[@]}" |
103 |
+ ./configure "${myconf[@]}" || die |
104 |
+} |
105 |
+ |
106 |
+src_install() { |
107 |
+ default |
108 |
+ |
109 |
+ local libdirs=( /$(get_libdir) /usr/$(get_libdir) ) |
110 |
+ if [[ ${SYMLINK_LIB} = yes && $(get_libdir) != lib ]]; then |
111 |
+ # Preserve lib -> lib64 symlinks in initramfs |
112 |
+ libdirs+=( /lib /usr/lib ) |
113 |
+ fi |
114 |
+ |
115 |
+ einfo "Setting libdirs to \"${libdirs[*]}\" ..." |
116 |
+ echo "libdirs=\"${libdirs[*]}\"" > "${T}/gentoo.conf" || die |
117 |
+ insinto "/usr/lib/dracut/dracut.conf.d" |
118 |
+ doins "${T}/gentoo.conf" |
119 |
+ |
120 |
+ insinto /etc/logrotate.d |
121 |
+ newins dracut.logrotate dracut |
122 |
+ |
123 |
+ docinto html |
124 |
+ dodoc dracut.html |
125 |
+} |
126 |
+ |
127 |
+pkg_postinst() { |
128 |
+ if linux-info_get_any_version && linux_config_exists; then |
129 |
+ ewarn "" |
130 |
+ ewarn "If the following test report contains a missing kernel" |
131 |
+ ewarn "configuration option, you should reconfigure and rebuild your" |
132 |
+ ewarn "kernel before booting image generated with this Dracut version." |
133 |
+ ewarn "" |
134 |
+ |
135 |
+ local CONFIG_CHECK="~BLK_DEV_INITRD ~DEVTMPFS" |
136 |
+ |
137 |
+ # Kernel configuration options descriptions: |
138 |
+ local ERROR_DEVTMPFS='CONFIG_DEVTMPFS: "Maintain a devtmpfs filesystem to mount at /dev" ' |
139 |
+ ERROR_DEVTMPFS+='is missing and REQUIRED' |
140 |
+ local ERROR_BLK_DEV_INITRD='CONFIG_BLK_DEV_INITRD: "Initial RAM filesystem and RAM disk ' |
141 |
+ ERROR_BLK_DEV_INITRD+='(initramfs/initrd) support" is missing and REQUIRED' |
142 |
+ |
143 |
+ check_extra_config |
144 |
+ echo |
145 |
+ else |
146 |
+ ewarn "" |
147 |
+ ewarn "Your kernel configuration couldn't be checked." |
148 |
+ ewarn "Please check manually if following options are enabled:" |
149 |
+ ewarn "" |
150 |
+ ewarn " CONFIG_BLK_DEV_INITRD" |
151 |
+ ewarn " CONFIG_DEVTMPFS" |
152 |
+ ewarn "" |
153 |
+ fi |
154 |
+ |
155 |
+ elog "To get additional features, a number of optional runtime" |
156 |
+ elog "dependencies may be installed:" |
157 |
+ elog "" |
158 |
+ optfeature "Networking support" net-misc/curl "net-misc/dhcp[client]" \ |
159 |
+ sys-apps/iproute2 "net-misc/iputils[arping]" |
160 |
+ optfeature \ |
161 |
+ "Measure performance of the boot process for later visualisation" \ |
162 |
+ app-benchmarks/bootchart2 app-admin/killproc sys-process/acct |
163 |
+ optfeature "Scan for Btrfs on block devices" sys-fs/btrfs-progs |
164 |
+ optfeature "Load kernel modules and drop this privilege for real init" \ |
165 |
+ sys-libs/libcap |
166 |
+ optfeature "Support CIFS" net-fs/cifs-utils |
167 |
+ optfeature "Decrypt devices encrypted with cryptsetup/LUKS" \ |
168 |
+ "sys-fs/cryptsetup[-static-libs]" |
169 |
+ optfeature "Support for GPG-encrypted keys for crypt module" \ |
170 |
+ app-crypt/gnupg |
171 |
+ optfeature \ |
172 |
+ "Allows use of dash instead of default bash (on your own risk)" \ |
173 |
+ app-shells/dash |
174 |
+ optfeature "Support iSCSI" sys-block/open-iscsi |
175 |
+ optfeature "Support Logical Volume Manager" sys-fs/lvm2 |
176 |
+ optfeature "Support MD devices, also known as software RAID devices" \ |
177 |
+ sys-fs/mdadm |
178 |
+ optfeature "Support Device Mapper multipathing" sys-fs/multipath-tools |
179 |
+ optfeature "Plymouth boot splash" '>=sys-boot/plymouth-0.8.5-r5' |
180 |
+ optfeature "Support network block devices" sys-block/nbd |
181 |
+ optfeature "Support NFS" net-fs/nfs-utils net-nds/rpcbind |
182 |
+ optfeature \ |
183 |
+ "Install ssh and scp along with config files and specified keys" \ |
184 |
+ net-misc/openssh |
185 |
+ optfeature "Enable logging with syslog-ng or rsyslog" app-admin/syslog-ng \ |
186 |
+ app-admin/rsyslog |
187 |
+} |
188 |
|
189 |
diff --git a/sys-kernel/dracut/files/048-dracut-install-simplify-ldd-parsing-logic.patch b/sys-kernel/dracut/files/048-dracut-install-simplify-ldd-parsing-logic.patch |
190 |
new file mode 100644 |
191 |
index 0000000..aa9c543 |
192 |
--- /dev/null |
193 |
+++ b/sys-kernel/dracut/files/048-dracut-install-simplify-ldd-parsing-logic.patch |
194 |
@@ -0,0 +1,41 @@ |
195 |
+From 6d886bb74d1608e4565d926aa259ea5afc9df7b9 Mon Sep 17 00:00:00 2001 |
196 |
+From: Mike Gilbert <floppym@g.o> |
197 |
+Date: Thu, 4 Oct 2018 16:45:47 -0400 |
198 |
+Subject: [PATCH] dracut-install: simplify ldd parsing logic |
199 |
+ |
200 |
+The previous logic would not handle absolute paths on the left side of |
201 |
+the "=>" properly. For example, on Gentoo ARM64, ldd outputs this: |
202 |
+ |
203 |
+ /lib/ld-linux-aarch64.so.1 => /lib64/ld-linux-aarch64.so.1 |
204 |
+ |
205 |
+At runtime, the kernel tries to load the file from /lib, and fails if we |
206 |
+only provide it in /lib64. |
207 |
+ |
208 |
+Instead of looking for the first slash after the "=>", just look for the |
209 |
+first slash, period. This would fail if we somehow had a relative path |
210 |
+on the left side (foo/libbar.so), but I'm not aware of any binaries that |
211 |
+would contain such an entry in DT_NEEDED. |
212 |
+ |
213 |
+Bug: https://bugs.gentoo.org/667752 |
214 |
+Signed-off-by: Mike Gilbert <floppym@g.o> |
215 |
+--- |
216 |
+ install/dracut-install.c | 6 +----- |
217 |
+ 1 file changed, 1 insertion(+), 5 deletions(-) |
218 |
+ |
219 |
+diff --git a/install/dracut-install.c b/install/dracut-install.c |
220 |
+index 88bca1d44..5f352b360 100644 |
221 |
+--- a/install/dracut-install.c |
222 |
++++ b/install/dracut-install.c |
223 |
+@@ -479,11 +479,7 @@ static int resolve_deps(const char *src) |
224 |
+ if (strstr(buf, destrootdir)) |
225 |
+ break; |
226 |
+ |
227 |
+- p = strstr(buf, "=>"); |
228 |
+- if (!p) |
229 |
+- p = buf; |
230 |
+- |
231 |
+- p = strchr(p, '/'); |
232 |
++ p = strchr(buf, '/'); |
233 |
+ if (p) { |
234 |
+ char *q; |
235 |
+ |