Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 30 Jan 2013 00:40:29 +0000 (UTC)
From:      Benno Rice <benno@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-projects@freebsd.org
Subject:   svn commit: r246102 - in projects/uefi: . sys/boot/i386/gptboot sys/boot/i386/gptzfsboot sys/boot/i386/loader sys/boot/i386/zfsboot
Message-ID:  <201301300040.r0U0eT8j017440@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: benno
Date: Wed Jan 30 00:40:28 2013
New Revision: 246102
URL: http://svnweb.freebsd.org/changeset/base/246102

Log:
  Rewire non-EFI boot code to use the 32-bit libstand out of /usr/lib32.
  
  This hasn't been tested yet.
  
  Sponsored by:	FreeBSD Foundation

Modified:
  projects/uefi/UEFI-TODO.txt
  projects/uefi/sys/boot/i386/gptboot/Makefile
  projects/uefi/sys/boot/i386/gptzfsboot/Makefile
  projects/uefi/sys/boot/i386/loader/Makefile
  projects/uefi/sys/boot/i386/zfsboot/Makefile

Modified: projects/uefi/UEFI-TODO.txt
==============================================================================
--- projects/uefi/UEFI-TODO.txt	Wed Jan 30 00:16:59 2013	(r246101)
+++ projects/uefi/UEFI-TODO.txt	Wed Jan 30 00:40:28 2013	(r246102)
@@ -3,7 +3,7 @@
 Part the First: 64-bit EFI loader
 
 + Make libstand build natively as 64-bit on amd64.
-- Adjust non-EFI boot code to use /usr/lib32/libstand.a.
++ Adjust non-EFI boot code to use /usr/lib32/libstand.a.
 - Test that the other boot code still actually works.
 - Add bits to build 64-bit loader.efi.
 - Make sure that loader.efi can actually load a kernel and hand off to it.

Modified: projects/uefi/sys/boot/i386/gptboot/Makefile
==============================================================================
--- projects/uefi/sys/boot/i386/gptboot/Makefile	Wed Jan 30 00:16:59 2013	(r246101)
+++ projects/uefi/sys/boot/i386/gptboot/Makefile	Wed Jan 30 00:40:28 2013	(r246102)
@@ -37,6 +37,10 @@ CFLAGS=	-DBOOTPROG=\"gptboot\" \
 	-Winline --param max-inline-insns-single=100
 
 LDFLAGS=-static -N --gc-sections
+.if ${MACHINE_CPUARCH} == "amd64"
+LDFLAGS+=	-m elf_i386_fbsd
+LIBSTAND=	/usr/lib32/libstand.a
+.endif
 
 # Pick up ../Makefile.inc early.
 .include <bsd.init.mk>

Modified: projects/uefi/sys/boot/i386/gptzfsboot/Makefile
==============================================================================
--- projects/uefi/sys/boot/i386/gptzfsboot/Makefile	Wed Jan 30 00:16:59 2013	(r246101)
+++ projects/uefi/sys/boot/i386/gptzfsboot/Makefile	Wed Jan 30 00:40:28 2013	(r246102)
@@ -36,6 +36,11 @@ CFLAGS=	-DBOOTPROG=\"gptzfsboot\" \
 
 LDFLAGS=-static -N --gc-sections
 
+.if ${MACHINE_CPUARCH} == "amd64"
+LDFLAGS+=	-m elf_i386_fbsd
+LIBSTAND=	/usr/lib32/libstand.a
+.endif
+
 # Pick up ../Makefile.inc early.
 .include <bsd.init.mk>
 

Modified: projects/uefi/sys/boot/i386/loader/Makefile
==============================================================================
--- projects/uefi/sys/boot/i386/loader/Makefile	Wed Jan 30 00:16:59 2013	(r246101)
+++ projects/uefi/sys/boot/i386/loader/Makefile	Wed Jan 30 00:40:28 2013	(r246102)
@@ -65,6 +65,11 @@ CLEANFILES=	vers.c ${LOADER} ${LOADER}.b
 CFLAGS+=	-Wall
 LDFLAGS=	-static -Ttext 0x0
 
+.if ${MACHINE_CPUARCH} == "amd64"
+LDFLAGS+=	-Wl,-m,elf_i386_fbsd
+LIBSTAND=	/usr/lib32/libstand.a
+.endif
+
 # i386 standalone support library
 LIBI386=	${.OBJDIR}/../libi386/libi386.a
 CFLAGS+=	-I${.CURDIR}/..

Modified: projects/uefi/sys/boot/i386/zfsboot/Makefile
==============================================================================
--- projects/uefi/sys/boot/i386/zfsboot/Makefile	Wed Jan 30 00:16:59 2013	(r246101)
+++ projects/uefi/sys/boot/i386/zfsboot/Makefile	Wed Jan 30 00:40:28 2013	(r246102)
@@ -33,6 +33,11 @@ CFLAGS=	-DBOOTPROG=\"zfsboot\" \
 
 LDFLAGS=-static -N --gc-sections
 
+.if ${MACHINE_CPUARCH} == "amd64"
+LDFLAGS+=	-m elf_i386_fbsd
+LIBSTAND=	/usr/lib32/libstand.a
+.endif
+
 # Pick up ../Makefile.inc early.
 .include <bsd.init.mk>
 



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201301300040.r0U0eT8j017440>