Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 2 Oct 2019 17:15:39 +0000 (UTC)
From:      Kyle Evans <kevans@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r353018 - head/usr.bin/clang
Message-ID:  <201910021715.x92HFdMH085550@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: kevans
Date: Wed Oct  2 17:15:38 2019
New Revision: 353018
URL: https://svnweb.freebsd.org/changeset/base/353018

Log:
  clang: use -mxgot for 32-bit mips
  
  Various bits in usr.bin/clang/* will fail to compile without -mxgot due to
  truncated relocations. -mxgot entails a speed penalty, but I suspect we
  don't care as much about compiler performance in 32-bit mips land.
  
  Reviewed by:	arichardson
  Differential Revision:	https://reviews.freebsd.org/D21698

Modified:
  head/usr.bin/clang/Makefile.inc

Modified: head/usr.bin/clang/Makefile.inc
==============================================================================
--- head/usr.bin/clang/Makefile.inc	Wed Oct  2 17:08:20 2019	(r353017)
+++ head/usr.bin/clang/Makefile.inc	Wed Oct  2 17:15:38 2019	(r353018)
@@ -12,4 +12,9 @@ DEBUG_FILES_CFLAGS= -gline-tables-only
 DEBUG_FILES_CFLAGS= -g1
 .endif
 
+.if ${MACHINE_ARCH:Mmips*} && ${MACHINE_ARCH:Mmips64*} == ""
+CFLAGS+= -mxgot
+CXXFLAGS+= -mxgot
+.endif
+
 .include "../Makefile.inc"



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