Received: from mailman by lists.gnu.org with archive (Exim 4.43) id 1M3YOH-0002BY-E4 for mharc-grub-devel@gnu.org; Mon, 11 May 2009 12:30:09 -0400 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1M3YOE-0002Ag-Pb for grub-devel@gnu.org; Mon, 11 May 2009 12:30:06 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1M3YOD-0002AQ-HD for grub-devel@gnu.org; Mon, 11 May 2009 12:30:05 -0400 Received: from [199.232.76.173] (port=50059 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1M3YOD-0002AN-C8 for grub-devel@gnu.org; Mon, 11 May 2009 12:30:05 -0400 Received: from ey-out-1920.google.com ([74.125.78.150]:28272) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1M3YOB-0008EX-Nv for grub-devel@gnu.org; Mon, 11 May 2009 12:30:04 -0400 Received: by ey-out-1920.google.com with SMTP id 13so709007eye.24 for ; Mon, 11 May 2009 09:30:02 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:in-reply-to:references :date:message-id:subject:from:to:content-type :content-transfer-encoding; bh=U+xXWB1CzOBBhP/MULj/0VVskNg5Rv2OMyBsJ20WX5o=; b=E0JNkjMnKqh9U5MbuBOhp1DvBKS+zcLEOhDifxiG0rjrVFNGEB6qv11ZJ76Mgqe1AM CrDYj279bbUgSWEEA7crFxonaiWqlvx1fHunnkRZocvm1STp6kCas0mTMY3LingID4d0 xYBWKduRJ907i8DAMbtlaskCl0iLxmN/v+LsE= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type:content-transfer-encoding; b=uighCCnEGx/vEKAQIxJnnE4OrmdyyKcP0s839uTvoOP5tf6/ox4mgpwXv1/ioJ9e/I 9xnsqaRc2Kt+GcnQ9Big3DdqlI3SvZ6A3KN0JML+gNFQX78SjZibBN/Uf2A+XyH383nM ChXySNmTBC2HbZhnpKJ8LycyaiB7WJmijkyk8= MIME-Version: 1.0 Received: by 10.211.199.13 with SMTP id b13mr3408442ebq.88.1242059402531; Mon, 11 May 2009 09:30:02 -0700 (PDT) In-Reply-To: <48f46e890905110348u23ca548bh68b068cb4cc9008@mail.gmail.com> References: <48f46e890905110348u23ca548bh68b068cb4cc9008@mail.gmail.com> Date: Mon, 11 May 2009 18:30:02 +0200 Message-ID: From: "Vladimir 'phcoder' Serbinenko" To: The development of GRUB 2 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-detected-operating-system: by monty-python.gnu.org: GNU/Linux 2.6 (newer, 2) Subject: Re: [PATCH] Make grub2 compile with Apple's gcc X-BeenThere: grub-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: The development of GRUB 2 List-Id: The development of GRUB 2 List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 11 May 2009 16:30:06 -0000 On Mon, May 11, 2009 at 12:48 PM, Peter Cros wrote: > > Hi, > patches were applied with grub2 rev 2202, compiles and builds grub.efi in= Mac OSX 10.5.6 , i686-apple-darwin9-gcc-4.0.1, with no errors, but fails t= o run grub.efi. > ./configure =A0--with-platform=3Defi --target=3Dx86_64 > ./grub-mkimage -d . -o grubosx.efi appleldr boot cat cmp chain configfile= crc date echo ext2 fixvideo fat fs_uuid gpt gptsync halt help hexdump hfs = =A0hfsplus iso9660 linux loopback loadbios lspci ls minicmd memrw ntfs pc p= ci reboot reiserfs read scsi sleep search sh video videotest xfs > rEFIt then gives - > =A0=A0 =A0Starting grubosx.efi > and hangs there (i.e. before the Welcome to GRUB). It's a bug in grub-mkimage - it inappropriately assumes that text is a first segment. I'll fix it. Temporarily you can just comment out the following line: util/i386/efi/grub-mkimage.c: line 104: strcpy (kernel_image + sizeof (Elf_Ehdr) + GRUB_KERNEL_MACHINE_PREFIX, prefix); > > Attempt to compile macho2img.c gave error, but is this needed for x86_64? > > On Mon, May 11, 2009 at 2:46 AM, Vladimir 'phcoder' Serbinenko wrote: >> >> Hello. With this patch you can compile grub2 using Apple's gcc. Only par= tially tested. You need objconv available from http://www.agner.org/optimiz= e/ licensed under GPL and additionally patched with attached patch >> Then you need to patch grub2 with attached patch. If you compile for i38= 6-pcbefore you begin you need to compile execute: >> gcc -o macho2img util/macho2img.c -Iinclude >> Then just compile grub2 normally. I will look how to automatise the comp= ilation of macho2img >> -- >> Regards >> Vladimir 'phcoder' Serbinenko >> >> _______________________________________________ >> Grub-devel mailing list >> Grub-devel@gnu.org >> http://lists.gnu.org/mailman/listinfo/grub-devel >> > > > > -- > Cros (pxw) > > > > _______________________________________________ > Grub-devel mailing list > Grub-devel@gnu.org > http://lists.gnu.org/mailman/listinfo/grub-devel > -- Regards Vladimir 'phcoder' Serbinenko