From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from list by lists.gnu.org with archive (Exim 4.71) id 1TyeqC-0000Uq-Rk for mharc-grub-devel@gnu.org; Fri, 25 Jan 2013 03:40:52 -0500 Received: from eggs.gnu.org ([208.118.235.92]:48820) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Tyeq4-0000TO-Nl for grub-devel@gnu.org; Fri, 25 Jan 2013 03:40:51 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Tyepz-0006EC-61 for grub-devel@gnu.org; Fri, 25 Jan 2013 03:40:44 -0500 Received: from mail-we0-x235.google.com ([2a00:1450:400c:c03::235]:44867) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Tyepy-0006E6-SP for grub-devel@gnu.org; Fri, 25 Jan 2013 03:40:39 -0500 Received: by mail-we0-f181.google.com with SMTP id t44so56987wey.40 for ; Fri, 25 Jan 2013 00:40:37 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=x-received:message-id:date:from:user-agent:mime-version:to:subject :references:in-reply-to:x-enigmail-version:content-type; bh=FTLgnMhn70mlU6BtaL/5ohii9Qn7BzMnrO1o9bgmOWI=; b=Vjpobe+e6PHVhtzXi9lfavIOxAqBv179tK6Ak6Jr9Aq7ZpeYifjot10NwZxxP96DNW z2u5PmWWTZzPEFO2czbv94VKIa2aB3oBA/PeDVCr+C22nnT1k417qV3MTGXc+mgPVhy9 4dO2+O7hC9cKHNSGl6Y05zimsytDYtbb5cezbHCjFlTD/vwdzBKgmUcUkCBoo+Cpn0Di alv58BoITNovIvL33r582/YqF1Hn5EF5dxv3DSF+U2t53DIl7kjUJIFEHO4QM6c8x+XU BwqoSbIdTuQZcUqop6x7BmPAG3UVXwD02zIR0OuYJy7Q82WeRNT2pwrIVumQjpvn8+Ai 269g== X-Received: by 10.180.77.35 with SMTP id p3mr7325822wiw.18.1359103237251; Fri, 25 Jan 2013 00:40:37 -0800 (PST) Received: from debian.x201.phnet ([217.193.148.98]) by mx.google.com with ESMTPS id df2sm6042809wib.0.2013.01.25.00.40.35 (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Fri, 25 Jan 2013 00:40:36 -0800 (PST) Message-ID: <510244F1.4080500@gmail.com> Date: Fri, 25 Jan 2013 09:40:17 +0100 From: =?UTF-8?B?VmxhZGltaXIgJ8+GLWNvZGVyL3BoY29kZXInIFNlcmJpbmVua28=?= User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:10.0.11) Gecko/20121122 Icedove/10.0.11 MIME-Version: 1.0 To: The development of GNU GRUB Subject: Re: Mac OS X entries don't work (fail or crash), part 1 References: In-Reply-To: X-Enigmail-Version: 1.4.1 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="------------enigC4EC2BA6467A9A4B23EE9CDB" X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2a00:1450:400c:c03::235 X-BeenThere: grub-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list Reply-To: The development of GNU GRUB List-Id: The development of GNU GRUB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 25 Jan 2013 08:40:51 -0000 This is an OpenPGP/MIME signed message (RFC 2440 and 3156) --------------enigC4EC2BA6467A9A4B23EE9CDB Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable On 25.01.2013 07:00, Chris Murphy wrote: >=20 > Fedora 18, grub2-efi-2.00-13.fc18 >=20 > When I choose any Mac OS X entry I get: >=20 > error: can't find command 'xnu_uuid'=20 > error: can't find command 'xnu_kernel64'=20 > error: can't find command 'xnu_kextdir' >=20 > Press any key to continue=E2=80=A6 >=20 > I already know how I can fix this, I'm inquiring on what exactly is wro= ng and how it needs to get fixed in Fedora so it works. >=20 > 1. The Fedora installed grubx64.efi doesn't have the necessary xnu modu= les baked into it. Should it? Or is it better for it to depend on finding= the modules and loading them on demand? >=20 > 2. The grubx64.efi prefix is looking on the ESP in /EFI/fedora/x86_64-e= fi for the modules. Is this the correct location for modules on (U)EFI sy= stems? >=20 > 3. The Fedora grub2-efi package doesn't install any modules to either l= ocation (not to the ESP, not to /boot/grub2). Should it? >=20 > 4. The Fedora installer, doesn't call grub2-install, to cause the modul= es to be installed anywhere. Should it? >=20 GRUB supports only modules under $prefix/$cpu-$platform which can be on memdisk. It seems that some people start shuffling it around using custom stuff. It's not supported by upstream and if it fails like in your case we don't care. Unless you use one of official ways (grub-install, grub-mknetdir, grub-mkrescue or grub-mkstandalone) you have an unsupported config which may fail in a number of ways but it's not my problem. Using unofficial install way =3D no support. I haven't seen any valid reason to use any other install (except when preparing coreboot or loongson ROM image). If there are valid reasons a corresponding install tool can be added (like it was the case of grub-mknetdir). Use grub-install to reinstall properly. > Clearly either the grubx64.efi needs the xnu mod files baked in, OR the= modules need to be installed by the grub2 package in a location where gr= ubx64.efi can find them; OR the installer needs to call grub2-install to = get them installed to a location where grubx64.efi can find them. I'm jus= t not clear where they are supposed to go on a (U)EFI system. >=20 > The grub2-install help description for --boot-directory=3D says they sh= ould go in /boot/grub2, apparently even on (U)EFI systems, not on the ESP= =2E If I use this to direct it to /boot/efi, they still end up in the wro= ng place because a grub2 folder is created. >=20 > When I run grub2-install by itself, the modules are installed to /boot/= grub2/x86_64-efi, but I also get a message: >=20 > /boot/efi doesn't look like an EFI partition. >=20 > So grub2-install presumably wanted to do something on the ESP? What? I = see nothing written. Is the failure because Fedora is using an HFS+ volu= me as the EFI System partition, grub2-install then falls back to installi= ng modules into /boot/grub2? >=20 > Results from grub2-install --debug: >=20 >=20 > [root@f18s ~]# grub2-install --debug > + setup_verbose=3D--verbose > + efi_quiet=3D-q > + '[' -z '' ']' > + bootdir=3D/boot > + '[' -n '' ']' > ++ echo /boot/grub2 > ++ sed 's,//*,/,g' > + grubdir=3D/boot/grub2 > + device_map=3D/boot/grub2/device.map > + '[' x86_64-efi =3D i386-pc ']' > + '[' x86_64-efi =3D sparc64-ieee1275 ']' > + set /usr/bin/grub2-mkimage dummy > + test -f /usr/bin/grub2-mkimage > + : > + '[' xefi =3D xefi ']' > + test -n '' > + test -d /boot/efi > ++ /usr/sbin/grub2-probe --target=3Ddevice --device-map=3D /boot/efi > + install_device=3D/dev/sda4 > ++ /usr/sbin/grub2-probe --target=3Ddevice --device-map=3D /boot > + test x/dev/sda4 '!=3D' x/dev/sda6 > + efidir=3D/boot/efi > + test -n /boot/efi > ++ /usr/sbin/grub2-probe --target=3Dfs --device-map=3D/boot/grub2/devic= e.map /boot/efi > + efi_fs=3Dhfsplus > + test xhfsplus =3D xfat > + gettext_printf '%s doesn'\''t look like an EFI partition.\n' /boot/ef= i > + gettext_printf_format=3D'%s doesn'\''t look like an EFI partition.\n'= > + shift > ++ gettext '%s doesn'\''t look like an EFI partition.\n' > + printf '%s doesn'\''t look like an EFI partition.\n' /boot/efi > /boot/efi doesn't look like an EFI partition. > + efidir=3D > + test -n '' > + efidir=3D/boot/grub2 > + efi_distributor=3D > + efi_file=3Dgrub.efi > + mkdir -p /boot/grub2 > + mkdir -p /boot/grub2/x86_64-efi > + test no =3D yes > + test -f /boot/grub2/device.map > + device_map=3D >=20 > I have previously fixed the missing modules part of this, but then get = a kernel panic when choosing the OS X options. I'll discuss that part aft= er I resolve where everything is supposed to go so I can file an appropri= ate Fedora bug, and the work around for where things should go in the fut= ure. >=20 >=20 > Chris Murphy > _______________________________________________ > Grub-devel mailing list > Grub-devel@gnu.org > https://lists.gnu.org/mailman/listinfo/grub-devel >=20 --=20 Regards Vladimir '=CF=86-coder/phcoder' Serbinenko --------------enigC4EC2BA6467A9A4B23EE9CDB Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.12 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iF4EAREKAAYFAlECRQIACgkQNak7dOguQglbkQD/YCz4j5ulr2NwZa8HuA/snfwV Nd02idZH6KmNjqtzFdgA+gKxBmofEG7oTDsq1xIn8DLsUGuxyTogWyB1KGTfDRyw =pw3a -----END PGP SIGNATURE----- --------------enigC4EC2BA6467A9A4B23EE9CDB--