From owner-p4-projects@FreeBSD.ORG Mon Nov 6 08:30:53 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 8A30C16A492; Mon, 6 Nov 2006 08:30:53 +0000 (UTC) X-Original-To: perforce@freebsd.org Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 5F5BF16A415 for ; Mon, 6 Nov 2006 08:30:53 +0000 (UTC) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id D9F8B43D80 for ; Mon, 6 Nov 2006 08:30:52 +0000 (GMT) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id kA68Uqsn033201 for ; Mon, 6 Nov 2006 08:30:52 GMT (envelope-from imp@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id kA68UqS8033198 for perforce@freebsd.org; Mon, 6 Nov 2006 08:30:52 GMT (envelope-from imp@freebsd.org) Date: Mon, 6 Nov 2006 08:30:52 GMT Message-Id: <200611060830.kA68UqS8033198@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to imp@freebsd.org using -f From: Warner Losh To: Perforce Change Reviews Cc: Subject: PERFORCE change 109347 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 06 Nov 2006 08:30:53 -0000 http://perforce.freebsd.org/chv.cgi?CH=109347 Change 109347 by imp@imp_lighthouse on 2006/11/06 08:30:32 Use the new MACHINE_CPU instead of MACHINE_ARCH as the basis for TARGET_ARCH. I'm unsure if the amd64 -> x86_64 translation should happen like it does in this file, or if that's another case for substitution in bsd.own.mk. I kinda think this is the right place, since it is a gnuism and the rest of the tree is setup so that amd64 is the right thing to do. The binultils infrastructure wants 'TARGET_BIG_ENDIAN' defined when we're building big endian architectures for those CPUs that can support many different byte sexes. Since I'm uneasy about doing a regular expression match against "*eb" I have listed the two cases where we have multi-endian architectures (mips and arm). powerpc may also be one, and some that NetBSD supports that FreeBSD does not. Note: armeb support isn't there yet, and I believe this will not break the present TARGET=arm TARGET_ARCH=arm TARGET_BIG_ENDIAN=t way of building for xscale based big endian boards. Affected files ... .. //depot/projects/arm/src/gnu/usr.bin/binutils/Makefile.inc0#2 edit Differences ... ==== //depot/projects/arm/src/gnu/usr.bin/binutils/Makefile.inc0#2 (text+ko) ==== @@ -6,13 +6,16 @@ VERSION= "2.15 [FreeBSD] 2004-05-23" -TARGET_ARCH?= ${MACHINE_ARCH} +TARGET_ARCH?= ${MACHINE_CPU} .if ${TARGET_ARCH} == "amd64" BINUTILS_ARCH=x86_64 .else BINUTILS_ARCH=${TARGET_ARCH} .endif TARGET_TUPLE?= ${BINUTILS_ARCH}-obrien-freebsd +.if ${MACHINE_ARCH} == "armeb" || ${MACHINE_ARCH} == "mipseb" +TARGET_BIG_ENDIAN=t +.endif # RELTOP is the relative path to this point in the source or object # tree, from any subdirectory of same. It gets extra "../" prefixes