Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 10 Jan 2017 20:15:24 +0000 (UTC)
From:      Oleksandr Tymoshenko <gonzo@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r311891 - head/sys/boot/efi
Message-ID:  <201701102015.v0AKFOa3060914@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: gonzo
Date: Tue Jan 10 20:15:24 2017
New Revision: 311891
URL: https://svnweb.freebsd.org/changeset/base/311891

Log:
  [efi] Build EFI bits with -fPIC on ARM
  
  clang 3.9.0 without -fPIC generates absolute jump table for
  switch/case statement which trips boot1.efi and loader.efi
  on ARM platform.
  
  Reviewed by:	andrew
  MFC after:	3 days
  Differential Revision:	https://reviews.freebsd.org/D9108

Modified:
  head/sys/boot/efi/Makefile.inc

Modified: head/sys/boot/efi/Makefile.inc
==============================================================================
--- head/sys/boot/efi/Makefile.inc	Tue Jan 10 20:12:07 2017	(r311890)
+++ head/sys/boot/efi/Makefile.inc	Tue Jan 10 20:15:24 2017	(r311891)
@@ -23,4 +23,8 @@ CFLAGS+=	-fshort-wchar
 CFLAGS+=	-fPIC
 .endif
 
+.if ${MACHINE_CPUARCH} == "arm"
+CFLAGS+=	-fPIC
+.endif
+
 .include "../Makefile.inc"



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