From owner-svn-src-head@FreeBSD.ORG Sat Jan 8 23:00:54 2011 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 AC4031065700; Sat, 8 Jan 2011 23:00:54 +0000 (UTC) (envelope-from imp@bsdimp.com) Received: from harmony.bsdimp.com (bsdimp.com [199.45.160.85]) by mx1.freebsd.org (Postfix) with ESMTP id 4C1E88FC08; Sat, 8 Jan 2011 23:00:54 +0000 (UTC) Received: from [127.0.0.1] (localhost [127.0.0.1]) by harmony.bsdimp.com (8.14.3/8.14.1) with ESMTP id p08Mw8fa063313; Sat, 8 Jan 2011 15:58:08 -0700 (MST) (envelope-from imp@bsdimp.com) Message-ID: <4D28EBFE.10004@bsdimp.com> Date: Sat, 08 Jan 2011 15:58:06 -0700 From: Warner Losh User-Agent: Mozilla/5.0 (X11; U; FreeBSD amd64; en-US; rv:1.9.2.12) Gecko/20101029 Thunderbird/3.1.6 MIME-Version: 1.0 To: Doug Barton References: <201101062107.p06L7p9o028440@svn.freebsd.org> <4D27F295.1030609@FreeBSD.org> In-Reply-To: <4D27F295.1030609@FreeBSD.org> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org, Warner Losh Subject: Re: svn commit: r217071 - head/lib/bind 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: Sat, 08 Jan 2011 23:00:54 -0000 On 01/07/2011 22:13, Doug Barton wrote: > I've said before that I like to have the opportunity to pre-commit > review patches in this area because at minimum it helps me to be aware > of them for potential MFC purposes. Thanks for the reminder Doug. Hope there's no hard feelings... > That said, I appreciate the help, especially with the more "exotic" > arches that I don't have experience with. > > A few comments below. me too... > > On 01/06/2011 13:07, Warner Losh wrote: >> Author: imp >> Date: Thu Jan 6 21:07:51 2011 >> New Revision: 217071 >> URL: http://svn.freebsd.org/changeset/base/217071 >> >> Log: >> Make this work on big endian MIPS, while not breaking it for small >> endian mips. This will also make it work automatically on all future >> big endian platforms. >> >> Modified: >> head/lib/bind/config.mk >> >> Modified: head/lib/bind/config.mk >> ============================================================================== >> >> --- head/lib/bind/config.mk Thu Jan 6 21:04:00 2011 (r217070) >> +++ head/lib/bind/config.mk Thu Jan 6 21:07:51 2011 (r217071) >> @@ -1,6 +1,7 @@ >> # $FreeBSD$ >> >> .include >> +.include >> >> # BIND version number >> .if defined(BIND_DIR)&& exists(${BIND_DIR}/version) >> @@ -45,7 +46,7 @@ CFLAGS+= -DOPENSSL >> CFLAGS+= -DUSE_MD5 >> >> # Endianness >> -.if ${MACHINE_CPUARCH} == "powerpc" || ${MACHINE_CPUARCH} == "sparc64" >> +.if ${TARGET_ENDIANNESS} == 4321 >> CFLAGS+= -DWORDS_BIGENDIAN >> .endif > > This is just the kind of solution I was hoping would be available, and > exactly the kind I prefer, the no-maintenance kind. :) Is this safe > to MFC, or does it require bits that are only in HEAD atm? If the > latter, can you please let me know when it's ready to go? Thanks. I think that bsd.endian.mk is -current only, but there's no reason it can't be MFC'd. I'll merge it to 7 and 8 here in a few minutes and let you know. > >> @@ -64,11 +65,7 @@ CFLAGS+= -I${LIB_BIND_DIR} >> .endif >> >> # Use the right version of the atomic.h file from lib/isc >> -.if ${MACHINE_ARCH} == "amd64" || ${MACHINE_ARCH} == "i386" >> -ISC_ATOMIC_ARCH= x86_32 >> -.else >> -ISC_ATOMIC_ARCH= ${MACHINE_CPUARCH} >> -.endif >> +ISC_ATOMIC_ARCH=${MACHINE_CPUARCH:S/i386/x86_32/:S/amd64/x86_32/} > > This change I am less enthusiastic about. It seems to me that it does > the exact same thing, but while admittedly quite a bit more clever > than I am capable of I find it less readable. Unless this is doing > something more or better than the previous code I will likely revert > this. Damn. I missed that in my pre-commit review, or I'd have mentioned it in the commit log. Feel free to revert it if you don't like it, or I'd be happy to revert it if you wanted me to clean up my own mess. Warner > > > Doug >