1 |
commit: c58fd356e668022d76ea78f8852faf225695fc1b |
2 |
Author: Mike Gilbert <floppym <AT> gentoo <DOT> org> |
3 |
AuthorDate: Sun Mar 1 18:05:22 2020 +0000 |
4 |
Commit: Mike Gilbert <floppym <AT> gentoo <DOT> org> |
5 |
CommitDate: Sun Mar 1 18:05:22 2020 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=c58fd356 |
7 |
|
8 |
sys-boot/grub: new snapshot |
9 |
|
10 |
Package-Manager: Portage-2.3.89_p9, Repoman-2.3.20_p79 |
11 |
Signed-off-by: Mike Gilbert <floppym <AT> gentoo.org> |
12 |
|
13 |
sys-boot/grub/Manifest | 1 + |
14 |
sys-boot/grub/grub-2.05_alpha20200228.ebuild | 290 +++++++++++++++++++++++++++ |
15 |
2 files changed, 291 insertions(+) |
16 |
|
17 |
diff --git a/sys-boot/grub/Manifest b/sys-boot/grub/Manifest |
18 |
index 4c9b21dad96..46884c72bb2 100644 |
19 |
--- a/sys-boot/grub/Manifest |
20 |
+++ b/sys-boot/grub/Manifest |
21 |
@@ -2,5 +2,6 @@ DIST dejavu-sans-ttf-2.37.zip 417746 BLAKE2B c8904f3cd5a49370a7dc10e456684c88aea |
22 |
DIST grub-2.02.tar.xz 6113260 BLAKE2B 7c5ec61a8dc5a00e9cdc91c489f0d2ee37cd7e673eef8e8e26bbc18c5ec28829f563b9298874fb96d45a5d523ce366e936649c21ebda7462afda0cc328b970ce SHA512 cc6eb0a42b5c8df2f671cc128ff725afb3ff1f8832a196022e433cf0d3b75decfca2316d0aa5fabea75747d55e88f3d021dd93508563f8ca80fd7b9e7fe1f088 |
23 |
DIST grub-2.04.tar.xz 6393864 BLAKE2B 413ffb9aaeae1ee3128032914ca426a1a5adb3737895dfe563fdde5a7e0386ac2dbc2f7ddfc4e0a67b3ad90494985d6886c20054b038701feb743e67e2eed9d0 SHA512 9c15c42d0cf5d61446b752194e3b628bb04be0fe6ea0240ab62b3d753784712744846e1f7c3651d8e0968d22012e6d713c38c44936d4004ded3ca4d4007babbb |
24 |
DIST grub-2.05_alpha20200110.tar.xz 5452588 BLAKE2B ccf95644bc76f6be8e73a25e1b5f05e052ea5bc0c61896454c211fccaec6a714dbae10f7398aa1e9d7bf864efc68655708c102ba20cc1e40fecd3fa7d3d961f7 SHA512 b6e609edc4dcee5d9348d1d6d9ecfec5a759a284a1f82970b38f8aab0c8fa6b5dc69e532a1a264815208df5dae3bf409c2f73846893a8e3cb97187d0e0c7295c |
25 |
+DIST grub-2.05_alpha20200228.tar.xz 6619176 BLAKE2B 15f45495bfffab71f9e4bccd0c60b48dcedfec7da650ceb3bc66f64ad7331e8ab1f786d04893d81b6c2e61dab6fa1ff47a29afcaa7f92bb478c4b18312311604 SHA512 28e42b0125283d0ef3d415a69699416e83e3ee32d60ffe092b0d03765d150579bd3fb218ed2bbf4877bd802012b409a502e86e825c0d22265252097d20449957 |
26 |
DIST unifont-12.1.02.pcf.gz 1335424 BLAKE2B 97080312468e3f3c8aa6f49cef08f5622641e8c9c035f3ede1e09d8d98de4e78d3b23c8aba2e8070eb46cbebd2d55e8568e467d7f15f35aa8fc8db792b7e5f14 SHA512 b280b2db7cf5f480b0668c331130dede2c0cc87d5e02e44566b77787113d0f6604d0105522858288f2ac6b8e77df7a2d9878725013a6c778dc5bfb183156e2f0 |
27 |
DIST unifont-9.0.06.pcf.gz 1360354 BLAKE2B 09b96e1711c729ef159d62e3ea7b289ca2d01dc0ea417e35a18b73dc02a23f62ce7821d9761bceee4002d9eeaabd91cfb69bbacc6fbdfdfa00445d18fe8f1d66 SHA512 dd0a1afa72f5204c62055d83f22750c74af38ffafdb8eda8e1f1cf7292e572a14969b8a9a6a2cb336d5bed4ab633f6b5a962c59117a590e4238788959cb82774 |
28 |
|
29 |
diff --git a/sys-boot/grub/grub-2.05_alpha20200228.ebuild b/sys-boot/grub/grub-2.05_alpha20200228.ebuild |
30 |
new file mode 100644 |
31 |
index 00000000000..fa6feb071bb |
32 |
--- /dev/null |
33 |
+++ b/sys-boot/grub/grub-2.05_alpha20200228.ebuild |
34 |
@@ -0,0 +1,290 @@ |
35 |
+# Copyright 1999-2020 Gentoo Authors |
36 |
+# Distributed under the terms of the GNU General Public License v2 |
37 |
+ |
38 |
+EAPI=7 |
39 |
+ |
40 |
+if [[ ${PV} == 9999 ]]; then |
41 |
+ GRUB_AUTORECONF=1 |
42 |
+ GRUB_BOOTSTRAP=1 |
43 |
+fi |
44 |
+ |
45 |
+if [[ -n ${GRUB_AUTOGEN} || -n ${GRUB_BOOTSTRAP} ]]; then |
46 |
+ PYTHON_COMPAT=( python{2_7,3_{6,7}} ) |
47 |
+ inherit python-any-r1 |
48 |
+fi |
49 |
+ |
50 |
+if [[ -n ${GRUB_AUTORECONF} ]]; then |
51 |
+ WANT_LIBTOOL=none |
52 |
+ inherit autotools |
53 |
+fi |
54 |
+ |
55 |
+inherit bash-completion-r1 eutils flag-o-matic multibuild pax-utils toolchain-funcs |
56 |
+ |
57 |
+if [[ ${PV} != 9999 ]]; then |
58 |
+ SRC_URI="https://dev.gentoo.org/~floppym/dist/${P}.tar.xz" |
59 |
+ KEYWORDS="~amd64 ~arm ~arm64 ~ia64 ~ppc ~ppc64 ~x86" |
60 |
+else |
61 |
+ inherit git-r3 |
62 |
+ EGIT_REPO_URI="https://git.savannah.gnu.org/git/grub.git" |
63 |
+fi |
64 |
+ |
65 |
+PATCHES=( |
66 |
+ "${FILESDIR}"/gfxpayload.patch |
67 |
+ "${FILESDIR}"/grub-2.02_beta2-KERNEL_GLOBS.patch |
68 |
+) |
69 |
+ |
70 |
+DEJAVU=dejavu-sans-ttf-2.37 |
71 |
+UNIFONT=unifont-12.1.02 |
72 |
+SRC_URI+=" fonts? ( mirror://gnu/unifont/${UNIFONT}/${UNIFONT}.pcf.gz ) |
73 |
+ themes? ( mirror://sourceforge/dejavu/${DEJAVU}.zip )" |
74 |
+ |
75 |
+DESCRIPTION="GNU GRUB boot loader" |
76 |
+HOMEPAGE="https://www.gnu.org/software/grub/" |
77 |
+ |
78 |
+# Includes licenses for dejavu and unifont |
79 |
+LICENSE="GPL-3+ BSD MIT fonts? ( GPL-2-with-font-exception ) themes? ( CC-BY-SA-3.0 BitstreamVera )" |
80 |
+SLOT="2/${PVR}" |
81 |
+IUSE="device-mapper doc efiemu +fonts mount nls sdl test +themes truetype libzfs" |
82 |
+ |
83 |
+GRUB_ALL_PLATFORMS=( coreboot efi-32 efi-64 emu ieee1275 loongson multiboot qemu qemu-mips pc uboot xen xen-32 xen-pvh ) |
84 |
+IUSE+=" ${GRUB_ALL_PLATFORMS[@]/#/grub_platforms_}" |
85 |
+ |
86 |
+REQUIRED_USE=" |
87 |
+ grub_platforms_coreboot? ( fonts ) |
88 |
+ grub_platforms_qemu? ( fonts ) |
89 |
+ grub_platforms_ieee1275? ( fonts ) |
90 |
+ grub_platforms_loongson? ( fonts ) |
91 |
+" |
92 |
+ |
93 |
+BDEPEND=" |
94 |
+ ${PYTHON_DEPS} |
95 |
+ app-misc/pax-utils |
96 |
+ sys-devel/flex |
97 |
+ sys-devel/bison |
98 |
+ sys-apps/help2man |
99 |
+ sys-apps/texinfo |
100 |
+ fonts? ( |
101 |
+ media-libs/freetype:2 |
102 |
+ virtual/pkgconfig |
103 |
+ ) |
104 |
+ test? ( |
105 |
+ app-admin/genromfs |
106 |
+ app-arch/cpio |
107 |
+ app-arch/lzop |
108 |
+ app-emulation/qemu |
109 |
+ dev-libs/libisoburn |
110 |
+ sys-apps/miscfiles |
111 |
+ sys-block/parted |
112 |
+ sys-fs/squashfs-tools |
113 |
+ ) |
114 |
+ themes? ( |
115 |
+ app-arch/unzip |
116 |
+ media-libs/freetype:2 |
117 |
+ virtual/pkgconfig |
118 |
+ ) |
119 |
+ truetype? ( virtual/pkgconfig ) |
120 |
+" |
121 |
+DEPEND=" |
122 |
+ app-arch/xz-utils |
123 |
+ >=sys-libs/ncurses-5.2-r5:0= |
124 |
+ sdl? ( media-libs/libsdl ) |
125 |
+ device-mapper? ( >=sys-fs/lvm2-2.02.45 ) |
126 |
+ libzfs? ( sys-fs/zfs ) |
127 |
+ mount? ( sys-fs/fuse:0 ) |
128 |
+ truetype? ( media-libs/freetype:2= ) |
129 |
+ ppc? ( >=sys-apps/ibm-powerpc-utils-1.3.5 ) |
130 |
+ ppc64? ( >=sys-apps/ibm-powerpc-utils-1.3.5 ) |
131 |
+ grub_platforms_xen? ( app-emulation/xen-tools:= ) |
132 |
+ grub_platforms_xen-32? ( app-emulation/xen-tools:= ) |
133 |
+ grub_platforms_xen-pvh? ( app-emulation/xen-tools:= ) |
134 |
+" |
135 |
+RDEPEND="${DEPEND} |
136 |
+ kernel_linux? ( |
137 |
+ grub_platforms_efi-32? ( sys-boot/efibootmgr ) |
138 |
+ grub_platforms_efi-64? ( sys-boot/efibootmgr ) |
139 |
+ ) |
140 |
+ !sys-boot/grub:0 !sys-boot/grub-static |
141 |
+ nls? ( sys-devel/gettext ) |
142 |
+" |
143 |
+ |
144 |
+RESTRICT="!test? ( test )" |
145 |
+ |
146 |
+QA_EXECSTACK="usr/bin/grub-emu* usr/lib/grub/*" |
147 |
+QA_PRESTRIPPED="usr/lib/grub/.*" |
148 |
+QA_MULTILIB_PATHS="usr/lib/grub/.*" |
149 |
+QA_WX_LOAD="usr/lib/grub/*" |
150 |
+ |
151 |
+src_unpack() { |
152 |
+ if [[ ${PV} == 9999 ]]; then |
153 |
+ git-r3_src_unpack |
154 |
+ pushd "${P}" >/dev/null || die |
155 |
+ local GNULIB_URI="https://git.savannah.gnu.org/git/gnulib.git" |
156 |
+ local GNULIB_REVISION=$(source bootstrap.conf >/dev/null; echo "${GNULIB_REVISION}") |
157 |
+ git-r3_fetch "${GNULIB_URI}" "${GNULIB_REVISION}" |
158 |
+ git-r3_checkout "${GNULIB_URI}" gnulib |
159 |
+ popd >/dev/null || die |
160 |
+ fi |
161 |
+ default |
162 |
+} |
163 |
+ |
164 |
+src_prepare() { |
165 |
+ default |
166 |
+ |
167 |
+ sed -i -e /autoreconf/d autogen.sh || die |
168 |
+ |
169 |
+ # Nothing in Gentoo packages 'american-english' in the exact path |
170 |
+ # wanted for the test, but all that is needed is a compressible text |
171 |
+ # file, and we do have 'words' from miscfiles in the same path. |
172 |
+ sed -i \ |
173 |
+ -e '/CFILESSRC.*=/s,american-english,words,' \ |
174 |
+ tests/util/grub-fs-tester.in \ |
175 |
+ || die |
176 |
+ |
177 |
+ if [[ -n ${GRUB_AUTOGEN} || -n ${GRUB_BOOTSTRAP} ]]; then |
178 |
+ python_setup |
179 |
+ fi |
180 |
+ |
181 |
+ if [[ -n ${GRUB_BOOTSTRAP} ]]; then |
182 |
+ eautopoint --force |
183 |
+ AUTOPOINT=: AUTORECONF=: ./bootstrap || die |
184 |
+ elif [[ -n ${GRUB_AUTOGEN} ]]; then |
185 |
+ ./autogen.sh || die |
186 |
+ fi |
187 |
+ |
188 |
+ if [[ -n ${GRUB_AUTORECONF} ]]; then |
189 |
+ eautoreconf |
190 |
+ fi |
191 |
+} |
192 |
+ |
193 |
+grub_do() { |
194 |
+ multibuild_foreach_variant run_in_build_dir "$@" |
195 |
+} |
196 |
+ |
197 |
+grub_do_once() { |
198 |
+ multibuild_for_best_variant run_in_build_dir "$@" |
199 |
+} |
200 |
+ |
201 |
+grub_configure() { |
202 |
+ local platform |
203 |
+ |
204 |
+ case ${MULTIBUILD_VARIANT} in |
205 |
+ efi*) platform=efi ;; |
206 |
+ xen-pvh) platform=xen_pvh ;; |
207 |
+ xen*) platform=xen ;; |
208 |
+ guessed) ;; |
209 |
+ *) platform=${MULTIBUILD_VARIANT} ;; |
210 |
+ esac |
211 |
+ |
212 |
+ case ${MULTIBUILD_VARIANT} in |
213 |
+ *-32) |
214 |
+ if [[ ${CTARGET:-${CHOST}} == x86_64* ]]; then |
215 |
+ local CTARGET=i386 |
216 |
+ fi ;; |
217 |
+ *-64) |
218 |
+ if [[ ${CTARGET:-${CHOST}} == i?86* ]]; then |
219 |
+ local CTARGET=x86_64 |
220 |
+ local -x TARGET_CFLAGS="-Os -march=x86-64 ${TARGET_CFLAGS}" |
221 |
+ local -x TARGET_CPPFLAGS="-march=x86-64 ${TARGET_CPPFLAGS}" |
222 |
+ fi ;; |
223 |
+ esac |
224 |
+ |
225 |
+ local myeconfargs=( |
226 |
+ --disable-werror |
227 |
+ --program-prefix= |
228 |
+ --libdir="${EPREFIX}"/usr/lib |
229 |
+ $(use_enable device-mapper) |
230 |
+ $(use_enable mount grub-mount) |
231 |
+ $(use_enable nls) |
232 |
+ $(use_enable themes grub-themes) |
233 |
+ $(use_enable truetype grub-mkfont) |
234 |
+ $(use_enable libzfs) |
235 |
+ $(use_enable sdl grub-emu-sdl) |
236 |
+ ${platform:+--with-platform=}${platform} |
237 |
+ |
238 |
+ # Let configure detect this where supported |
239 |
+ $(usex efiemu '' '--disable-efiemu') |
240 |
+ ) |
241 |
+ |
242 |
+ if use fonts; then |
243 |
+ ln -rs "${WORKDIR}/${UNIFONT}.pcf" unifont.pcf || die |
244 |
+ fi |
245 |
+ |
246 |
+ if use themes; then |
247 |
+ ln -rs "${WORKDIR}/${DEJAVU}/ttf/DejaVuSans.ttf" DejaVuSans.ttf || die |
248 |
+ fi |
249 |
+ |
250 |
+ local ECONF_SOURCE="${S}" |
251 |
+ econf "${myeconfargs[@]}" |
252 |
+} |
253 |
+ |
254 |
+src_configure() { |
255 |
+ # Bug 508758. |
256 |
+ replace-flags -O3 -O2 |
257 |
+ |
258 |
+ # We don't want to leak flags onto boot code. |
259 |
+ export HOST_CCASFLAGS=${CCASFLAGS} |
260 |
+ export HOST_CFLAGS=${CFLAGS} |
261 |
+ export HOST_CPPFLAGS=${CPPFLAGS} |
262 |
+ export HOST_LDFLAGS=${LDFLAGS} |
263 |
+ unset CCASFLAGS CFLAGS CPPFLAGS LDFLAGS |
264 |
+ |
265 |
+ tc-ld-disable-gold #439082 #466536 #526348 |
266 |
+ export TARGET_LDFLAGS="${TARGET_LDFLAGS} ${LDFLAGS}" |
267 |
+ unset LDFLAGS |
268 |
+ |
269 |
+ tc-export CC NM OBJCOPY RANLIB STRIP |
270 |
+ tc-export BUILD_CC # Bug 485592 |
271 |
+ |
272 |
+ MULTIBUILD_VARIANTS=() |
273 |
+ local p |
274 |
+ for p in "${GRUB_ALL_PLATFORMS[@]}"; do |
275 |
+ use "grub_platforms_${p}" && MULTIBUILD_VARIANTS+=( "${p}" ) |
276 |
+ done |
277 |
+ [[ ${#MULTIBUILD_VARIANTS[@]} -eq 0 ]] && MULTIBUILD_VARIANTS=( guessed ) |
278 |
+ grub_do grub_configure |
279 |
+} |
280 |
+ |
281 |
+src_compile() { |
282 |
+ # Sandbox bug 404013. |
283 |
+ use libzfs && addpredict /etc/dfs:/dev/zfs |
284 |
+ |
285 |
+ grub_do emake |
286 |
+ use doc && grub_do_once emake -C docs html |
287 |
+} |
288 |
+ |
289 |
+src_test() { |
290 |
+ # The qemu dependency is a bit complex. |
291 |
+ # You will need to adjust QEMU_SOFTMMU_TARGETS to match the cpu/platform. |
292 |
+ grub_do emake check |
293 |
+} |
294 |
+ |
295 |
+src_install() { |
296 |
+ grub_do emake install DESTDIR="${D}" bashcompletiondir="$(get_bashcompdir)" |
297 |
+ use doc && grub_do_once emake -C docs install-html DESTDIR="${D}" |
298 |
+ |
299 |
+ einstalldocs |
300 |
+ |
301 |
+ insinto /etc/default |
302 |
+ newins "${FILESDIR}"/grub.default-3 grub |
303 |
+ |
304 |
+ # https://bugs.gentoo.org/231935 |
305 |
+ dostrip -x /usr/lib/grub |
306 |
+} |
307 |
+ |
308 |
+pkg_postinst() { |
309 |
+ elog "For information on how to configure GRUB2 please refer to the guide:" |
310 |
+ elog " https://wiki.gentoo.org/wiki/GRUB2_Quick_Start" |
311 |
+ |
312 |
+ if has_version 'sys-boot/grub:0'; then |
313 |
+ elog "A migration guide for GRUB Legacy users is available:" |
314 |
+ elog " https://wiki.gentoo.org/wiki/GRUB2_Migration" |
315 |
+ fi |
316 |
+ |
317 |
+ if [[ -z ${REPLACING_VERSIONS} ]]; then |
318 |
+ elog |
319 |
+ elog "You may consider installing the following optional packages:" |
320 |
+ optfeature "Detect other operating systems (grub-mkconfig)" sys-boot/os-prober |
321 |
+ optfeature "Create rescue media (grub-mkrescue)" dev-libs/libisoburn |
322 |
+ optfeature "Enable RAID device detection" sys-fs/mdadm |
323 |
+ fi |
324 |
+} |