Date: Fri, 26 Sep 2008 23:29:25 +0200 From: Juergen Lock <nox@jelal.kn-bremen.de> To: Anthony Liguori <anthony@codemonkey.ws> Cc: freebsd-emulation@freebsd.org, qemu-devel@nongnu.org Subject: Re: [Qemu-devel] [PATCH] preprocessor issue in qemu/patch-block-raw-posix.c Message-ID: <20080926212925.GA10666@saturn.kn-bremen.de> In-Reply-To: <48DBF71E.1000405@codemonkey.ws> References: <20080921204025.GA81055@saturn.kn-bremen.de> <200809242210.m8OMAcSZ021572@saturn.kn-bremen.de> <20080925201703.GA12142@saturn.kn-bremen.de> <48DBF71E.1000405@codemonkey.ws>
next in thread | previous in thread | raw e-mail | index | archive | help
On Thu, Sep 25, 2008 at 03:39:58PM -0500, Anthony Liguori wrote: > Juergen Lock wrote: >> I forgot to note that this also needed the following patch: >> > > Why? This #ifdef is working around a very specific bug. > Well, looks like the preprocessor tries to parse the entire expression including the undefined `!__GLIBC_PREREQ(2, 4)' before evaluating it: block-raw-posix.c:548:69: missing binary operator before token "(" so I just put it on an extra line. > Regards, > > Anthony Liguori > >> Index: qemu/block-raw-posix.c >> @@ -545,7 +545,8 @@ >> qemu_aio_set_fd_handler(s->fd, posix_aio_read, NULL, >> posix_aio_flush, s); >> -#if defined(__linux__) && defined(__GLIBC_PREREQ) && !__GLIBC_PREREQ(2, >> 4) >> +#if defined(__linux__) && defined(__GLIBC_PREREQ) >> +#if !__GLIBC_PREREQ(2, 4) >> { >> /* XXX: aio thread exit seems to hang on RedHat 9 and this init >> seems to fix the problem. */ >> @@ -557,6 +558,7 @@ >> aio_init(&ai); >> } >> #endif >> +#endif >> posix_aio_state = s; >> return 0; >> >> Signed-off-by: Juergen Lock <nox@jelal.kn-bremen.de> >> >> >> >
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20080926212925.GA10666>