Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 24 Oct 2019 03:37:17 +0000 (UTC)
From:      Kyle Evans <kevans@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-12@freebsd.org
Subject:   svn commit: r353999 - stable/12/stand/i386
Message-ID:  <201910240337.x9O3bH9P025330@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: kevans
Date: Thu Oct 24 03:37:17 2019
New Revision: 353999
URL: https://svnweb.freebsd.org/changeset/base/353999

Log:
  MFC r340834: Disable build-id in i386 binary boot components
  
  A user may enable build-id for all builds by adding
  LDFLAGS=-Wl,--build-id=sha1 to /etc/make.conf.  In this case the build-id
  note ends added up to mbr and pmbr's .text, which makes it too large (it
  ends up being 532 bytes). To avoid this explicitly turn off build-id for
  these components.

Modified:
  stable/12/stand/i386/Makefile.inc
Directory Properties:
  stable/12/   (props changed)

Modified: stable/12/stand/i386/Makefile.inc
==============================================================================
--- stable/12/stand/i386/Makefile.inc	Thu Oct 24 03:32:47 2019	(r353998)
+++ stable/12/stand/i386/Makefile.inc	Thu Oct 24 03:37:17 2019	(r353999)
@@ -2,6 +2,8 @@
 #
 # $FreeBSD$
 
+.include "bsd.linker.mk"
+
 LOADER_ADDRESS?=0x200000
 LDFLAGS+=	-nostdlib
 LDFLAGS.lld+=	-Wl,--no-rosegment
@@ -23,6 +25,9 @@ LDSCRIPT=	${BOOTSRC}/i386/boot.ldscript
 # LDFLAGS_BIN=-e start -Ttext ${ORG} -Wl,-T,${LDSCRIPT},-S,--oformat,binary
 # LD_FLAGS_BIN=-static -T ${LDSCRIPT} --gc-sections
 LDFLAGS_BIN=-e start -Ttext ${ORG} -Wl,-N,-S,--oformat,binary
+.if ${LINKER_FEATURES:Mbuild-id} != ""
+LDFLAGS_BIN+=-Wl,--build-id=none
+.endif
 LD_FLAGS_BIN=-static -N --gc-sections
 
 .if ${MACHINE_CPUARCH} == "amd64"



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