From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with archive (Exim 4.43) id 1MZnD1-00017B-Ru for mharc-grub-devel@gnu.org; Sat, 08 Aug 2009 10:47:47 -0400 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1MZnD0-00016p-AA for grub-devel@gnu.org; Sat, 08 Aug 2009 10:47:46 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1MZnCv-00016Y-Pf for grub-devel@gnu.org; Sat, 08 Aug 2009 10:47:45 -0400 Received: from [199.232.76.173] (port=49653 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1MZnCv-00016V-JZ for grub-devel@gnu.org; Sat, 08 Aug 2009 10:47:41 -0400 Received: from mail-fx0-f205.google.com ([209.85.220.205]:54753) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1MZnCv-0005jA-79 for grub-devel@gnu.org; Sat, 08 Aug 2009 10:47:41 -0400 Received: by fxm1 with SMTP id 1so1587283fxm.31 for ; Sat, 08 Aug 2009 07:47:40 -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=kR23njkrFdEFgkTBq8lSLKm/JRHJDQ2vA4W5DBMvQRs=; b=LqV5RQ4UovmWhtZJksovNmoa+qurrMTynScGveZbEJL7sOPv8csmkwhevqujl7k9pm NkWJntRGhRMPpaUkAvneaHC8CCefy8CdCcy5hulUZVrtqddihhFyWnPQNPSA8LYB1H8V X2n0mOKsCNE4gdn0/xc+wo/qxSfrud2ksLUdo= 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=FXwxCqRqal3e0IJ+geLp9K5fG93BNwtprUDZQhTDDEzETSb1zRH5LPehj8ha7TFZdJ FePtCR87Ekn8jvLzcZJ+CqUNFne5irfGG83q0yp+DRBavv51PIRC6w4kha//F/8hd+ks DWQI3COY5/bnU1BOuUfMunU2AoBfdQA0py1JQ= MIME-Version: 1.0 Received: by 10.204.52.135 with SMTP id i7mr4224621bkg.154.1249742860375; Sat, 08 Aug 2009 07:47:40 -0700 (PDT) In-Reply-To: References: Date: Sat, 8 Aug 2009 16:47:40 +0200 Message-ID: From: "Vladimir 'phcoder' Serbinenko" To: The development of GRUB 2 Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: quoted-printable X-detected-operating-system: by monty-python.gnu.org: GNU/Linux 2.6 (newer, 2) Subject: Re: Report: compil error on OSX for target=i386 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: Sat, 08 Aug 2009 14:47:46 -0000 On Sat, Aug 8, 2009 at 4:44 PM, Bean wrote: > Hi, > > I also encounter this problem with apple gcc 4.0, the fix is to replace: > > asm volatile ("jmp *%2" : : "b" (0), "S" (real_mode_mem), "g" > (params->code32_start)); > > With: > =A0asm volatile ("movl %0, %%ecx" : : "m" (params->code32_start)); > =A0asm volatile ("movl %0, %%esi" : : "m" (real_mode_mem)); > > =A0asm volatile ("xorl %%ebx, %%ebx" : : ); > =A0asm volatile ("jmp *%%ecx" : : ); This code has absolutely no guaranty to work since C can change registers between asm parts. In long term I was planning to replace this code with use of relocator framework > > On Sat, Aug 8, 2009 at 10:34 PM, Yves Blusseau wrote: >> Hi, >> >> can't compil grub2 on OSX with target=3Di386: >> >> ./configure --prefix=3D/opt --target=3Di386 >> >> ******************************************************* >> GRUB2 will be compiled with following components: >> Platform: i386-pc >> grub-emu: Yes >> USB support for grub-emu: No (need libusb library) >> With memory debugging: No >> grub-pe2elf will not be built >> efiemu runtime: No (cannot compile with -m64 -mcmodel=3Dlarge -mno-red-z= one >> -nostdlib) >> grub-fstest: Yes >> grub-mkfont: Yes >> ******************************************************* >> >> make >> >> loader/i386/linux.c: In function =91grub_linux_boot=92: >> loader/i386/linux.c:563: error: can't find a register in class =91BREG= =92 while >> reloading =91asm=92 >> make: *** [linux_mod-loader_i386_linux.o] Error 1 >> >> Yves Blusseau >> >> _______________________________________________ >> Grub-devel mailing list >> Grub-devel@gnu.org >> http://lists.gnu.org/mailman/listinfo/grub-devel >> > > > > -- > Bean > > > _______________________________________________ > Grub-devel mailing list > Grub-devel@gnu.org > http://lists.gnu.org/mailman/listinfo/grub-devel > --=20 Regards Vladimir 'phcoder' Serbinenko Personal git repository: http://repo.or.cz/w/grub2/phcoder.git