From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([208.118.235.92]:51131) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Scdbu-0003Kv-T4 for qemu-devel@nongnu.org; Thu, 07 Jun 2012 10:22:52 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Scdbp-0005Q8-NT for qemu-devel@nongnu.org; Thu, 07 Jun 2012 10:22:50 -0400 Received: from youngberry.canonical.com ([91.189.89.112]:35550) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Scdbp-0005Pz-HX for qemu-devel@nongnu.org; Thu, 07 Jun 2012 10:22:45 -0400 Date: Thu, 7 Jun 2012 09:22:38 -0500 From: Serge Hallyn Message-ID: <20120607142238.GA4210@sergelap> References: <1339047357-29413-1-git-send-email-sw@weilnetz.de> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: Subject: Re: [Qemu-devel] [PATCH] configure: Fix build for some versions of glibc (9pfs) List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Stefano Stabellini Cc: Stefan Weil , Anthony Liguori , "qemu-devel@nongnu.org" , "aneesh.kumar@linux.vnet.ibm.com" Quoting Stefano Stabellini (stefano.stabellini@eu.citrix.com): > On Thu, 7 Jun 2012, Stefan Weil wrote: > > Some versions declare open_by_handle_at, but don't define AT_EMPTY_PATH. > > Extend the check in configure to test both preconditions. > > > > Signed-off-by: Stefan Weil > > It works for me. Also I think it is a better fix than the original > patch. Well, it works in that it allows compilation to proceed. It results in ./libhw64/9pfs/virtio-9p-handle.o not being built, since AT_EMPTY_PATH can't be found through /usr/include/fcntl.h, even though it can in /usr/include/linux/fcntl.h. I guess that is, unfortunately, the right thing to do. Oh hey, I think I've found the bug in the debian package causing that problem. Grr. > Acked-by: Stefano Stabellini Acked-by: Serge Hallyn thanks, -serge > > > configure | 4 ++++ > > 1 file changed, 4 insertions(+) > > > > diff --git a/configure b/configure > > index 799ad0f..f737f6c 100755 > > --- a/configure > > +++ b/configure > > @@ -2816,7 +2816,11 @@ fi > > open_by_hande_at=no > > cat > $TMPC << EOF > > #include > > +#if !defined(AT_EMPTY_PATH) > > +# error missing definition > > +#else > > int main(void) { struct file_handle fh; return open_by_handle_at(0, &fh, 0); } > > +#endif > > EOF > > if compile_prog "" "" ; then > > open_by_handle_at=yes > > -- > > 1.7.10 > >