From owner-freebsd-hackers Fri Jan 4 11:47: 1 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from smtp2.san.rr.com (smtp2.san.rr.com [24.25.195.39]) by hub.freebsd.org (Postfix) with ESMTP id 4BEE037B41E; Fri, 4 Jan 2002 11:46:57 -0800 (PST) Received: from dt0b2n73.san.rr.com (dt096n72.san.rr.com [24.94.9.114]) by smtp2.san.rr.com (8.11.4/8.11.4) with ESMTP id g04Jksf08575; Fri, 4 Jan 2002 11:46:55 -0800 (PST) Received: (from ralph@localhost) by dt0b2n73.san.rr.com (8.11.6/8.11.3) id g04JksF08444; Fri, 4 Jan 2002 11:46:54 -0800 (PST) (envelope-from ralph@webcom.com) From: "Ralph N. Smith" Date: Fri, 4 Jan 2002 11:46:49 -0800 To: John Baldwin Cc: Stephen Montgomery-Smith , freebsd-hackers@freebsd.org, Alfred Perlstein Subject: Re: Tell gcc I have a i686 Message-ID: <20020104114649.A8422@ralph.smithton.com> References: <3C35F513.2F16AC08@math.missouri.edu> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5i In-Reply-To: ; from jhb@freebsd.org on Fri, Jan 04, 2002 at 11:20:55AM -0800 Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Fri, Jan 04, 2002 at 11:20:55AM -0800, John Baldwin wrote: > > On 04-Jan-02 Stephen Montgomery-Smith wrote: > > Alfred Perlstein wrote: > >> > >> * Stephen Montgomery-Smith [020104 12:02] wrote: ... > >> > But arch doesn't exist on FreeBSD. > >> > >> Isn't this somewhat trivial? > >> > >> ARCH=i686 > >> CFLAGS+=-D${ARCH} > >> > >> ? > >> > > > > > > What I want is a makefile that automatically detects whether it is on an > > i686 or not (not for me to tell it so). > > This doesn't support a user who wants to compile an app that they want to run > on some other machine. :) On FreeBSD, you can see if CPUTYPE is set from > make.conf, but it's not required to be set. However, if this behavior is insisted upon I would recommend doing something with the output of 'sysctl hw.model'. Implementation is left as an exercise for the reader. Ralph -- Ralph N. Smith ralph@webcom.com To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message