From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from list by lists.gnu.org with archive (Exim 4.71) id 1XAt8U-0004fd-1p for mharc-grub-devel@gnu.org; Fri, 25 Jul 2014 23:59:06 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:37952) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XAt8N-0004eu-Hf for grub-devel@gnu.org; Fri, 25 Jul 2014 23:59:03 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1XAt8J-0006QM-6W for grub-devel@gnu.org; Fri, 25 Jul 2014 23:58:59 -0400 Received: from mail-lb0-x236.google.com ([2a00:1450:4010:c04::236]:38395) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XAt8I-0006QG-Ps for grub-devel@gnu.org; Fri, 25 Jul 2014 23:58:55 -0400 Received: by mail-lb0-f182.google.com with SMTP id z11so3915296lbi.41 for ; Fri, 25 Jul 2014 20:58:53 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=date:from:to:cc:subject:message-id:in-reply-to:references :mime-version:content-type; bh=3J2KDR4Ubhk9ZPtsh7PF1OIitSYkJAps1o9klKD0/Yg=; b=AV5QoH1YS8STPPi5gfmjJZwh1bt1I2O9xIxoqGmLK+hWAI5IPEgU7k9dJyciyEjh5Q BZE7smlFQsWzB6YN6fLhwayUM8H68MVFLnyYxAFBbLZuGF7+mnVmCGIkqPV9BFDskDMp TptkC3tRVHtNg9Df7HAxABh2zMV6DfUekbdm8yYF9gQfl+MLL3SpGt7/vf+JuKaRlihE J2TYlxOI3WXDb1D3kIQxT09icvcAlRdNkreME108CgmFbUVqJNYYtrpE1raDFqiGKpQ6 o+qlJxYbU7lm2CsZfVn/IkoVcP/11zfGhejU6qUtaM7UYbs3z9eNOZxtwSiQaFDUFpv/ /FHw== X-Received: by 10.152.204.74 with SMTP id kw10mr15578073lac.63.1406347133481; Fri, 25 Jul 2014 20:58:53 -0700 (PDT) Received: from opensuse.site (ppp94-29-76-101.pppoe.spdop.ru. [94.29.76.101]) by mx.google.com with ESMTPSA id c7sm7955507laf.2.2014.07.25.20.58.52 for (version=SSLv3 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Fri, 25 Jul 2014 20:58:52 -0700 (PDT) Date: Sat, 26 Jul 2014 07:58:51 +0400 From: Andrey Borzenkov To: The development of GNU GRUB Subject: Re: [PATCH] Do not use inline in argp.h on FreeBSD Message-ID: <20140726075851.53c47cca@opensuse.site> In-Reply-To: <53D2CE98.9070702@gmail.com> References: <1406302104-30958-1-git-send-email-arvidjaar@gmail.com> <53D2CE98.9070702@gmail.com> X-Mailer: Claws Mail 3.9.2 (GTK+ 2.24.22; x86_64-suse-linux-gnu) Mime-Version: 1.0 Content-Type: multipart/signed; micalg=PGP-SHA1; boundary="Sig_/tEMX8snF44Cor2ryd2pnbaj"; protocol="application/pgp-signature" X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2a00:1450:4010:c04::236 Cc: phcoder@gmail.com X-BeenThere: grub-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list Reply-To: The development of GNU GRUB List-Id: The development of GNU GRUB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 26 Jul 2014 03:59:03 -0000 --Sig_/tEMX8snF44Cor2ryd2pnbaj Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable =D0=92 Fri, 25 Jul 2014 23:39:36 +0200 Vladimir '=CF=86-coder/phcoder' Serbinenko =D0=BF=D0=B8= =D1=88=D0=B5=D1=82: > On 25.07.2014 17:28, Andrey Borzenkov wrote: > > This fixes this error: > >=20 > > In file included from util/grub-mkimage.c:54:0: > > ./grub-core/gnulib/argp.h:627:49: error: '__sbistype' is static but > > used in inline function '_option_is_short' which is not static > > [-Werror] cc1: all warnings being treated as errors gmake[2]: *** > > [util/grub_mkimage-grub-mkimage.o] Error 1 > >=20 > Did you contatc gnulib?=20 Yes, this was sent to gnulib list :) > Can we just silence this warning? Apparently not for this particular case, and this warning is real, it should not be simply ignored. Unfortunately, while FreeBSD allows to disable "static inline" in _ctype.h it breaks compilation due to different FreeBSD bug, so this looks like the only workaround.=20 > > Treat FreeBSD similar to Apple and do not try inlines. It currently > > does it for GCC only, as this is what had been tested. > >=20 > > Reported-By: Beeblebrox > > Tested-By: Beeblebrox > > Signed-off-by: Andrey Borzenkov > >=20 > > --- > > m4/extern-inline.m4 | 10 +++++++--- > > 1 file changed, 7 insertions(+), 3 deletions(-) > >=20 > > diff --git a/m4/extern-inline.m4 b/m4/extern-inline.m4 > > index 240150e..009b928 100644 > > --- a/m4/extern-inline.m4 > > +++ b/m4/extern-inline.m4 > > @@ -24,7 +24,10 @@ AC_DEFUN([gl_EXTERN_INLINE], > > . > > OS X 10.9 has a macro __header_inline indicating the bug is fixed f= or C and > > for clang but remains for g++; see . > > - Perhaps Apple will fix this some day. */ > > + Perhaps Apple will fix this some day. > > + > > + Suppress use of inlines on FreeBSD with GCC similar to Apple. It fa= ils to > > + compile arpg.h due to static inlines in ctype.h */ > > #if (defined __APPLE__ \ > > && (defined __header_inline \ > > ? (defined __cplusplus && defined __GNUC_STDC_INLINE__ \ > > @@ -36,7 +39,8 @@ AC_DEFUN([gl_EXTERN_INLINE], > > # define _GL_EXTERN_INLINE_APPLE_BUG > > #endif > > #if ((__GNUC__ \ > > - ? defined __GNUC_STDC_INLINE__ && __GNUC_STDC_INLINE__ \ > > + ? (defined __GNUC_STDC_INLINE__ && __GNUC_STDC_INLINE__) \ > > + && !defined __FreeBSD__ \ > > : (199901L <=3D __STDC_VERSION__ \ > > && !defined __HP_cc \ > > && !(defined __SUNPRO_C && __STDC__))) \ > > @@ -45,7 +49,7 @@ AC_DEFUN([gl_EXTERN_INLINE], > > # define _GL_EXTERN_INLINE extern inline > > # define _GL_EXTERN_INLINE_IN_USE > > #elif (2 < __GNUC__ + (7 <=3D __GNUC_MINOR__) && !defined __STRICT_ANS= I__ \ > > - && !defined _GL_EXTERN_INLINE_APPLE_BUG) > > + && !defined _GL_EXTERN_INLINE_APPLE_BUG && !defined __FreeBSD__) > > # if defined __GNUC_GNU_INLINE__ && __GNUC_GNU_INLINE__ > > /* __gnu_inline__ suppresses a GCC 4.2 diagnostic. */ > > # define _GL_INLINE extern inline __attribute__ ((__gnu_inline__)) > >=20 >=20 >=20 --Sig_/tEMX8snF44Cor2ryd2pnbaj Content-Type: application/pgp-signature; name=signature.asc Content-Disposition: attachment; filename=signature.asc -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.22 (GNU/Linux) iEYEARECAAYFAlPTJ3sACgkQR6LMutpd94yNTQCgieh5nbo1UMChtD69VG59M8FG KOUAniNKQhMeywqfzdZspg6+oOx4hEzx =XRdx -----END PGP SIGNATURE----- --Sig_/tEMX8snF44Cor2ryd2pnbaj--