From owner-svn-src-head@FreeBSD.ORG Fri Jun 11 02:43:37 2010 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 014691065678; Fri, 11 Jun 2010 02:43:37 +0000 (UTC) (envelope-from imp@FreeBSD.org) Received: from svn.freebsd.org (unknown [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id DAA568FC0A; Fri, 11 Jun 2010 02:43:36 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id o5B2hacm041453; Fri, 11 Jun 2010 02:43:36 GMT (envelope-from imp@svn.freebsd.org) Received: (from imp@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id o5B2ha7H041451; Fri, 11 Jun 2010 02:43:36 GMT (envelope-from imp@svn.freebsd.org) Message-Id: <201006110243.o5B2ha7H041451@svn.freebsd.org> From: Warner Losh Date: Fri, 11 Jun 2010 02:43:36 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r209024 - head/share/mk X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 11 Jun 2010 02:43:37 -0000 Author: imp Date: Fri Jun 11 02:43:36 2010 New Revision: 209024 URL: http://svn.freebsd.org/changeset/base/209024 Log: Merge from tbemd branch: Introduce MACHINE_CPUARCH. Many different MACHINE_ARCHs will be built from one MACHINE_CPUARCH. This will allow us to move to a more standard MACHINE_ARCH for mips and arm which exist in many different endian variants, and for powerpc where both 32 and 64 bit binaries are generated from the same sources. Reviewed by: arch@ (mostly silence though) Modified: head/share/mk/sys.mk Modified: head/share/mk/sys.mk ============================================================================== --- head/share/mk/sys.mk Fri Jun 11 02:09:18 2010 (r209023) +++ head/share/mk/sys.mk Fri Jun 11 02:43:36 2010 (r209024) @@ -4,6 +4,18 @@ unix ?= We run FreeBSD, not UNIX. .FreeBSD ?= true +.if !defined(%POSIX) +# +# MACHINE_CPUARCH defines a collection of MACHINE_ARCH. Machines with +# the same MACHINE_ARCH can run reach-other's binaries, so it +# necessarily has word size and endian swizzled in. However, support +# files for these machines often are shared amongst all combinations +# of size and/or endian. This is called MACHINE_CPU in NetBSD, but +# that's used for something different in FreeBSD. +# +MACHINE_CPUARCH=${MACHINE_ARCH:C/mipse[lb]/mips/:C/armeb/arm/} +.endif + # If the special target .POSIX appears (without prerequisites or # commands) before the first noncomment line in the makefile, make shall # process the makefile as specified by the Posix 1003.2 specification. @@ -35,7 +47,7 @@ CC ?= c89 CFLAGS ?= -O .else CC ?= cc -.if ${MACHINE_ARCH} == "arm" || ${MACHINE_ARCH} == "mips" +.if ${MACHINE_CPUARCH} == "arm" || ${MACHINE_CPUARCH} == "mips" CFLAGS ?= -O -pipe .else CFLAGS ?= -O2 -pipe