On 01/22/2018 10:15 PM, Adam Jackson wrote:
On Mon, 2018-01-22 at 19:19 +0100, Florian Weimer wrote:
On 01/22/2018 06:26 PM, Adam Jackson wrote:
I'm trying to prepare xserver for this change, and it seems to provoke
an awkward warning when building on F27:
In file included from ../os/rpcauth.c:47:0:
/usr/include/tirpc/rpc/rpc.h:83:12: warning: redundant redeclaration of ‘bindresvport’ [-Wredundant-decls]
extern int bindresvport(int, struct sockaddr_in *);
^~~~~~~~~~~~
In file included from /usr/include/tirpc/rpc/rpc.h:40:0,
from ../os/rpcauth.c:47:
/usr/include/netinet/in.h:502:12: note: previous declaration of ‘bindresvport’ was here
extern int bindresvport (int __sockfd, struct sockaddr_in *__sock_in) __THROW;
^~~~~~~~~~~~
Is there any reasonable fix for this?
Redeclarations in system headers are expected. Do you compile with
-Wsystem-headers? Or do you something else which is unusual, such as
running the preprocessor separately?
Not that I'm aware of. The generated cc line is:
ninja: Entering directory `build'
[1/17] ccache cc -Ios/libxserver_os@sta -Ios -I../os -Ixfixes -I../xfixes
ccache runs the preprocessor separately. 8-)
Is -Wredundant-decls just not a thing one should try to use?
Certainly with ccache, yes.
Thanks,
Florian
_______________________________________________
devel mailing list -- devel@xxxxxxxxxxxxxxxxxxxxxxx
To unsubscribe send an email to devel-leave@xxxxxxxxxxxxxxxxxxxxxxx