On Fri, Mar 29, 2019 at 06:44:49AM -0400, Frediano Ziglio wrote: > > > > Signed-off-by: Christophe Fergeau <cfergeau@xxxxxxxxxx> > > --- > > common/verify.h | 24 ++++++++++++++---------- > > 1 file changed, 14 insertions(+), 10 deletions(-) > > > > diff --git a/common/verify.h b/common/verify.h > > index 267de29..3f3dece 100644 > > --- a/common/verify.h > > +++ b/common/verify.h > > @@ -1,10 +1,10 @@ > > /* Compile-time assert-like macros. > > > > - Copyright (C) 2005-2006, 2009-2016 Free Software Foundation, Inc. > > + Copyright (C) 2005-2006, 2009-2019 Free Software Foundation, Inc. > > > > This program is free software: you can redistribute it and/or modify > > it under the terms of the GNU Lesser General Public License as published > > by > > - the Free Software Foundation; either version 2.1 of the License, or > > + the Free Software Foundation; either version 3 of the License, or > > (at your option) any later version. > > > > This program is distributed in the hope that it will be useful, > > Still not compatible. *sigh*, sorry about this, gnulib's verify module is lpglv2+ https://git.savannah.gnu.org/gitweb/?p=gnulib.git;a=blob;f=modules/verify;h=5216ce890dac58e596a27341e31258e5d6c0d702;hb=HEAD Using gnulib-tool --import --lgpl=2 results in this s/2.1/3 change being gone from the diff. Christophe > > > @@ -13,7 +13,7 @@ > > GNU Lesser General Public License for more details. > > > > You should have received a copy of the GNU Lesser General Public License > > - along with this program. If not, see <http://www.gnu.org/licenses/>. */ > > + along with this program. If not, see <https://www.gnu.org/licenses/>. > > */ > > > > /* Written by Paul Eggert, Bruno Haible, and Jim Meyering. */ > > > > @@ -26,7 +26,7 @@ > > here generates easier-to-read diagnostics when verify (R) fails. > > > > Define _GL_HAVE_STATIC_ASSERT to 1 if static_assert works as per C++11. > > - This will likely be supported by future GCC versions, in C++ mode. > > + This is supported by GCC 6.1.0 and later, in C++ mode. > > > > Use this only with GCC. If we were willing to slow 'configure' > > down we could also use it with other compilers, but since this > > @@ -36,9 +36,7 @@ > > && !defined __cplusplus) > > # define _GL_HAVE__STATIC_ASSERT 1 > > #endif > > -/* The condition (99 < __GNUC__) is temporary, until we know about the > > - first G++ release that supports static_assert. */ > > -#if (99 < __GNUC__) && defined __cplusplus > > +#if (6 <= __GNUC__) && defined __cplusplus > > # define _GL_HAVE_STATIC_ASSERT 1 > > #endif > > > > @@ -248,7 +246,12 @@ template <int w> > > /* Verify requirement R at compile-time, as a declaration without a > > trailing ';'. */ > > > > -#define verify(R) _GL_VERIFY (R, "verify (" #R ")") > > +#ifdef __GNUC__ > > +# define verify(R) _GL_VERIFY (R, "verify (" #R ")") > > +#else > > +/* PGI barfs if R is long. Play it safe. */ > > +# define verify(R) _GL_VERIFY (R, "verify (...)") > > +#endif > > > > #ifndef __has_builtin > > # define __has_builtin(x) 0 > > @@ -263,7 +266,7 @@ template <int w> > > # define assume(R) ((R) ? (void) 0 : __builtin_unreachable ()) > > #elif 1200 <= _MSC_VER > > # define assume(R) __assume (R) > > -#elif (defined lint \ > > +#elif ((defined GCC_LINT || defined lint) \ > > && (__has_builtin (__builtin_trap) \ > > || 3 < __GNUC__ + (3 < __GNUC_MINOR__ + (4 <= > > || __GNUC_PATCHLEVEL__)))) > > /* Doing it this way helps various packages when configured with > > @@ -271,7 +274,8 @@ template <int w> > > when 'assume' silences warnings even with older GCCs. */ > > # define assume(R) ((R) ? (void) 0 : __builtin_trap ()) > > #else > > -# define assume(R) ((void) (0 && (R))) > > + /* Some tools grok NOTREACHED, e.g., Oracle Studio 12.6. */ > > +# define assume(R) ((R) ? (void) 0 : /*NOTREACHED*/ (void) 0) > > #endif > > > > /* @assert.h omit end@ */ > > Frediano
Attachment:
signature.asc
Description: PGP signature
_______________________________________________ Spice-devel mailing list Spice-devel@xxxxxxxxxxxxxxxxxxxxx https://lists.freedesktop.org/mailman/listinfo/spice-devel