From owner-freebsd-arch@FreeBSD.ORG Fri Nov 18 06:47:21 2011 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 4AEAF106568C; Fri, 18 Nov 2011 06:47:21 +0000 (UTC) (envelope-from rmh.aybabtu@gmail.com) Received: from mail-iy0-f182.google.com (mail-iy0-f182.google.com [209.85.210.182]) by mx1.freebsd.org (Postfix) with ESMTP id E00C28FC0A; Fri, 18 Nov 2011 06:47:20 +0000 (UTC) Received: by iakl21 with SMTP id l21so4680114iak.13 for ; Thu, 17 Nov 2011 22:47:19 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=mime-version:sender:in-reply-to:references:date :x-google-sender-auth:message-id:subject:from:to:cc:content-type; bh=Wya4bzIxnif0+Z1je+0QPhKvYLh5o6dnK4POQj8O5Os=; b=Mav0/furJu7zn7RK/Z6xhnPy+VB8pJRcGbqbrb1WqygfvhecEIyg56WAbGNtSt2ZoH lUi8m8mGLPo34IIPkWpUYQ/fkDbZi9hNMsoK4k4LZAB+4ZBCnGKn81Fzo989z31GBhjy HjrdjgkhxRFqhgiJGHx7hh3NePxLk8y6LA1YQ= MIME-Version: 1.0 Received: by 10.42.135.66 with SMTP id o2mr1295447ict.0.1321598839444; Thu, 17 Nov 2011 22:47:19 -0800 (PST) Sender: rmh.aybabtu@gmail.com Received: by 10.42.243.198 with HTTP; Thu, 17 Nov 2011 22:47:19 -0800 (PST) In-Reply-To: <201111171632.34979.jhb@freebsd.org> References: <201111170959.56767.jhb@freebsd.org> <201111171632.34979.jhb@freebsd.org> Date: Fri, 18 Nov 2011 07:47:19 +0100 X-Google-Sender-Auth: 7GOt4SHay_RPr6AKNyeK6txG96U Message-ID: From: Robert Millan To: John Baldwin Content-Type: text/plain; charset=UTF-8 Cc: Kostik Belousov , Adrian Chadd , freebsd-current@freebsd.org, freebsd-arch@freebsd.org Subject: Re: [PATCH] Detect GNU/kFreeBSD in user-visible kernel headers X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 18 Nov 2011 06:47:21 -0000 2011/11/17 John Baldwin : > Hmm, I wonder if it's better to use the #ifndef approach rather than #undef > so that when compilers are updated to DTRT we will honor their settings? Well, the compiler is supposed to know better than sys/param.h, because it inherited this number from the runtime kernel when it was built. However, __FreeBSD__ comes from the compiler already so if you "#define __FreeBSD_kernel__ __FreeBSD__" you get the information from the compiler anyway. As both approaches do the same thing, I really don't mind either way.