From: Igor Kozhukhov Subject: Re: [PATCH] ld: don't hardcode "-melf_i386" Date: Tue, 15 Apr 2014 22:11:19 +0400 Message-ID: References: <1397582552-51956-1-git-send-email-roger.pau@citrix.com> Mime-Version: 1.0 (Mac OS X Mail 7.2 \(1874\)) Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Return-path: Received: from mail6.bemta3.messagelabs.com ([195.245.230.39]) by lists.xen.org with esmtp (Exim 4.72) (envelope-from ) id 1Wa7pO-0001eo-Ay for xen-devel@lists.xenproject.org; Tue, 15 Apr 2014 18:11:26 +0000 Received: by mail-la0-f48.google.com with SMTP id gf5so7212755lab.35 for ; Tue, 15 Apr 2014 11:11:23 -0700 (PDT) In-Reply-To: <1397582552-51956-1-git-send-email-roger.pau@citrix.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: Roger Pau Monne Cc: xen-devel@lists.xenproject.org, seabios@seabios.org, Ian Campbell List-Id: xen-devel@lists.xenproject.org On 15 Apr 2014, at 21:22, Roger Pau Monne wrote: > On FreeBSD, the name of the emulation is "-melf_i386_fbsd", so allow > SeaBIOS to fetch the emulation to use from the environment variables. the same with -melf_i386_sol2 on illumos based platform. LGTM from me here. -Igor > This allows SeaBIOS to compile on FreeBSD with gcc. > = > Signed-off-by: Roger Pau Monn=E9 > Cc: Ian Campbell > --- > Makefile | 5 +++-- > 1 files changed, 3 insertions(+), 2 deletions(-) > = > diff --git a/Makefile b/Makefile > index 759bbbb..6a51305 100644 > --- a/Makefile > +++ b/Makefile > @@ -67,6 +67,7 @@ STRIP=3Dstrip > PYTHON=3Dpython > CPP=3Dcpp > IASL:=3Diasl > +LD32BIT_FLAG:=3D-melf_i386 > = > # Default targets > -include $(KCONFIG_CONFIG) > @@ -143,8 +144,8 @@ $(OUT)romlayout16.lds: $(OUT)ccode32flat.o $(OUT)code= 32seg.o $(OUT)ccode16.o $(O > @echo " Building ld scripts" > $(Q)./tools/buildversion.sh $(OUT)version.c > $(Q)$(CC) $(CFLAGS32FLAT) -c $(OUT)version.c -o $(OUT)version.o > - $(Q)$(LD) -melf_i386 -r $(OUT)ccode32flat.o $(OUT)version.o -o $(OUT)co= de32flat.o > - $(Q)$(LD) -melf_i386 -r $(OUT)ccode16.o $(OUT)romlayout.o -o $(OUT)code= 16.o > + $(Q)$(LD) $(LD32BIT_FLAG) -r $(OUT)ccode32flat.o $(OUT)version.o -o $(O= UT)code32flat.o > + $(Q)$(LD) $(LD32BIT_FLAG) -r $(OUT)ccode16.o $(OUT)romlayout.o -o $(OUT= )code16.o > $(Q)$(OBJDUMP) -thr $(OUT)code32flat.o > $(OUT)code32flat.o.objdump > $(Q)$(OBJDUMP) -thr $(OUT)code32seg.o > $(OUT)code32seg.o.objdump > $(Q)$(OBJDUMP) -thr $(OUT)code16.o > $(OUT)code16.o.objdump > -- = > 1.7.7.5 (Apple Git-26) > = > = > _______________________________________________ > Xen-devel mailing list > Xen-devel@lists.xen.org > http://lists.xen.org/xen-devel