From: Tim Deegan Subject: Re: [PATCH] xen: Don't use -nostdinc flags with CLANG Date: Tue, 11 Feb 2014 13:35:15 +0100 Message-ID: <20140211123515.GD97288@deinos.phlegethon.org> References: <1392074974-1488-1-git-send-email-julien.grall@linaro.org> <20140211085317.GB92054@deinos.phlegethon.org> <52FA17E3.9070105@linaro.org> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Received: from mail6.bemta5.messagelabs.com ([195.245.231.135]) by lists.xen.org with esmtp (Exim 4.72) (envelope-from ) id 1WDCYZ-0001r5-GJ for xen-devel@lists.xenproject.org; Tue, 11 Feb 2014 12:35:19 +0000 Content-Disposition: inline In-Reply-To: <52FA17E3.9070105@linaro.org> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: Julien Grall Cc: xen-devel@lists.xenproject.org, keir@xen.org, Ian.Jackson@eu.citrix.com, ian.campbell@citrix.com List-Id: xen-devel@lists.xenproject.org At 12:30 +0000 on 11 Feb (1392118227), Julien Grall wrote: > > > On 11/02/14 08:53, Tim Deegan wrote: > > At 23:29 +0000 on 10 Feb (1392071374), Julien Grall wrote: > >> Commit 06a9c7e "xen: move -nostdinc into common Rules.mk." breaks > >> compilation with clang: > >> > >> In file included from sched_sedf.c:8: > >> In file included from /home/julieng/works/xen/xen/include/xen/lib.h:5: > >> /home/julieng/works/xen/xen/include/xen/stdarg.h:20:12: error: 'stdarg.h' file > >> not found with include; use "quotes" instead > >> ^~~~~~~~~~ > >> "stdarg.h" > > > > Looks like on your system stdarg.h doesn't live in a compiler-specific > > path, like we have for the BSDs. I think we should just go to using > > our own definitions for stdarg/stdbool everywhere; trying to chase the > > compiler-specific versions around is a PITA, and the pieces we > > actually need are trivial. > > For BSDs, we are using our own stdargs/stdbool. So we don't include the > system . > > Linux is using $(CC) -print-file-name=include to get the right path. It > works with both gcc and clang on Linux distos, but not on FreeBSD. Wait - is the error message you posted from clang on FreeBSD? That's surprising; on FreeBSD xen/stdarg.h shouldn't be trying to include at all. Is __FreeBSD__ not being defined? Tim.