bug-gnulib
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Intel C++ compiler for Linux 11.1 doesn't build m4 1.4.13 on NetBSD


From: Eric Blake
Subject: Re: Intel C++ compiler for Linux 11.1 doesn't build m4 1.4.13 on NetBSD
Date: Tue, 17 Nov 2009 06:12:47 -0700
User-agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.1.23) Gecko/20090812 Thunderbird/2.0.0.23 Mnenhy/0.7.6.666

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

According to Alexander Nasonov on 11/17/2009 2:37 AM:
> it fails here:
> 
> fflush.c(95): error: a value of type "__off_t={__int64_t={long long}}" cannot 
> be assigned to an entity of type "fpos_t"
>     fp_->_offset = pos;
>                  ^
> compilation aborted for fflush.c (code 2)
> *** [fflush.o] Error code 2
> 1 error

Thanks for the report.  This is a gnulib problem, so I'm adding that list.

Are you sure you are using a C++ compiler instead of a C compiler?

> 
> 
> A quick look at /usr/include/stdio.h shows where the problem is:
> 
> /*
>  * This is fairly grotesque, but pure ANSI code must not inspect the
>  * innards of an fpos_t anyway.  The library internally uses off_t, 
>  * which we assume is exactly as big as eight chars.
>  */
> #if (!defined(_ANSI_SOURCE) && !defined(__STRICT_ANSI__)) || defined(_LIBC)
> typedef __off_t fpos_t;
> #else
> typedef struct __sfpos {
>     __off_t _pos;
> } fpos_t;
> #endif
> 
> I think the comment is right and m4 shouldn't use C99 flag (or don't use 
> _offset).

Actually, the real fix is to make gnulib realize how to properly assign to
fpos_t, even when it is a struct.  But this is something that Bruno may be
more familiar with, since he wrote the code in this file.

- --
Don't work too hard, make some time for fun as well!

Eric Blake             address@hidden
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (Cygwin)
Comment: Public key at home.comcast.net/~ericblake/eblake.gpg
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iEYEARECAAYFAksCoU8ACgkQ84KuGfSFAYAphQCfZAmOV2d7gvptFnY6xCz7IH8o
LKkAnAwIrTsACYf562403k61yAYpgt4c
=YlLD
-----END PGP SIGNATURE-----




reply via email to

[Prev in Thread] Current Thread [Next in Thread]