From owner-svn-src-all@freebsd.org Tue Oct 25 14:01:15 2016 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 4AB10C21DEB; Tue, 25 Oct 2016 14:01:15 +0000 (UTC) (envelope-from andrew@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 010E3307; Tue, 25 Oct 2016 14:01:14 +0000 (UTC) (envelope-from andrew@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id u9PE1E9F000785; Tue, 25 Oct 2016 14:01:14 GMT (envelope-from andrew@FreeBSD.org) Received: (from andrew@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id u9PE1E41000783; Tue, 25 Oct 2016 14:01:14 GMT (envelope-from andrew@FreeBSD.org) Message-Id: <201610251401.u9PE1E41000783@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: andrew set sender to andrew@FreeBSD.org using -f From: Andrew Turner Date: Tue, 25 Oct 2016 14:01:14 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r307908 - in head/sys/boot/efi: libefi loader X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 25 Oct 2016 14:01:15 -0000 Author: andrew Date: Tue Oct 25 14:01:13 2016 New Revision: 307908 URL: https://svnweb.freebsd.org/changeset/base/307908 Log: Fix the build on both arm64 and when WITHOUT_FORTH is defined. * On arm64 we need to use the ${MACHINE_CPUARCH} subdirectory. * env.c is only needed when using forth so only build it there. Sponsored by: ABT Systems Ltd Modified: head/sys/boot/efi/libefi/Makefile head/sys/boot/efi/loader/main.c Modified: head/sys/boot/efi/libefi/Makefile ============================================================================== --- head/sys/boot/efi/libefi/Makefile Tue Oct 25 13:45:59 2016 (r307907) +++ head/sys/boot/efi/libefi/Makefile Tue Oct 25 14:01:13 2016 (r307908) @@ -1,10 +1,12 @@ # $FreeBSD$ +.include + LIB= efi INTERNALLIB= WARNS?= 2 -SRCS= delay.c devpath.c efi_console.c efinet.c efipart.c env.c errno.c \ +SRCS= delay.c devpath.c efi_console.c efinet.c efipart.c errno.c \ handles.c libefi.c .if ${MACHINE_CPUARCH} == "amd64" || ${MACHINE_CPUARCH} == "i386" @@ -12,6 +14,11 @@ SRCS+= time.c .elif ${MACHINE_CPUARCH} == "aarch64" || ${MACHINE_CPUARCH} == "arm" SRCS+= time_event.c .endif +.if ${MK_FORTH} != "no" +SRCS+= env.c +CFLAGS+= -I${.CURDIR}/../../ficl +CFLAGS+= -I${.CURDIR}/../../ficl/${MACHINE_CPUARCH} +.endif # We implement a slightly non-standard %S in that it always takes a # CHAR16 that's common in UEFI-land instead of a wchar_t. This only @@ -26,7 +33,6 @@ CFLAGS+= -msoft-float -mgeneral-regs-onl .if ${MACHINE_ARCH} == "amd64" CFLAGS+= -fPIC -mno-red-zone .endif -CFLAGS+= -I${.CURDIR}/../../ficl -I${.CURDIR}/../../ficl/${MACHINE} CFLAGS+= -I${.CURDIR}/../include CFLAGS+= -I${.CURDIR}/../include/${MACHINE} CFLAGS+= -I${.CURDIR}/../../../../lib/libstand Modified: head/sys/boot/efi/loader/main.c ============================================================================== --- head/sys/boot/efi/loader/main.c Tue Oct 25 13:45:59 2016 (r307907) +++ head/sys/boot/efi/loader/main.c Tue Oct 25 14:01:13 2016 (r307908) @@ -55,9 +55,11 @@ extern char bootprog_rev[]; extern char bootprog_date[]; extern char bootprog_maker[]; +#ifdef BOOT_FORTH /* Force a reference to bring in EFI support from the library */ extern int efi_variable_support; int *dummy1 = &efi_variable_support; +#endif struct arch_switch archsw; /* MI/MD interface boundary */