From: Ian Campbell Subject: Re: stdbool.h -nostdinc XSA-55 trouble Date: Thu, 8 Aug 2013 17:12:51 +0100 Message-ID: <1375978371.14651.12.camel@kazak.uk.xensource.com> References: <20130808114945.GG22372@quark> <5203B51402000078000EA534@nat28.tlf.novell.com> <20130808151835.GB870@quark> <5203D59E02000078000EA634@nat28.tlf.novell.com> <20130808154714.GD870@quark> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <20130808154714.GD870@quark> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: Patrick Welche Cc: Ian Jackson , Jan Beulich , xen-devel@lists.xen.org List-Id: xen-devel@lists.xenproject.org (adding Ian J who did most of XSA-55) On Thu, 2013-08-08 at 16:47 +0100, Patrick Welche wrote: > On Thu, Aug 08, 2013 at 04:30:06PM +0100, Jan Beulich wrote: > > No, according to my checking, the --prefix configure option > > listed does not correlate with the directory where the header > > is found. > > Yes - I think our emails crossed... > > The underlying problem is: > > Linux: /usr/lib/gcc/i?86-linux-gnu/n.m/include/stdbool.h > NetBSD: /usr/include/stdbool.h The hypervisor side, which is where --nostdinc is used, has it's own bool_t in asm/types.h. Perhaps libelf (which is supposed to compile for both user and hypervisor space) should be using #ifdef __XEN__ #include #else #include #endif ? I'd be a bit concerned about the fact that Xen's bool_t is a typedef for char, as opposed to the compilers typedef to _Bool which has special meaning. It may not matter in practice but might the fact that _Bool canonicalises to 0 or 1 vs. 0 or !0 cause something subtle? ian.