build: renable -Wstrict-prototypes compiler warning

The warning -Wstrict-prototypes was disabled by commit
db9b1df0e4 .

Enable it again, but avoid warnings for WiMax SDK by explicitly disabling the
compiler warning where needed.

Apparently clang does not produce a warning for -Wstrict-prototypes,
hence we don't need a clang specific #pragma.

Signed-off-by: Thomas Haller <thaller@redhat.com>
This commit is contained in:
Thomas Haller 2014-10-29 12:59:51 +01:00
parent dd243ceefe
commit f1a0b4afd2
6 changed files with 14 additions and 3 deletions

View file

@ -25,6 +25,7 @@ if test "$GCC" = "yes" -a "$set_more_warnings" != "no"; then
for option in -Wshadow -Wmissing-declarations -Wmissing-prototypes \
-Wdeclaration-after-statement -Wformat-security \
-Wfloat-equal -Wno-unused-parameter -Wno-sign-compare \
-Wstrict-prototypes \
-fno-strict-aliasing -Wno-unused-but-set-variable \
-Wundef -Wimplicit-function-declaration \
-Wpointer-arith -Winit-self \

View file

@ -31,7 +31,8 @@
#include <glib.h>
#include <WiMaxType.h>
#include "nm-wimax-util.h"
#include <WiMaxAPI.h>
#include <WiMaxAPIEx.h>

View file

@ -22,7 +22,8 @@
#ifndef __IWMXSDK_H__
#define __IWMXSDK_H__
#include <wimax/WiMaxType.h>
#include "nm-wimax-util.h"
#include <wimax/WiMaxTypesEx.h>
#include <wimax/WiMaxAPIEx.h>

View file

@ -26,6 +26,9 @@
#include <sys/socket.h>
#include <glib/gi18n.h>
#include "nm-wimax-util.h"
#include <WiMaxAPI.h>
#include <WiMaxAPIEx.h>

View file

@ -18,7 +18,6 @@
* Copyright (C) 2009 Novell, Inc.
*/
#include <WiMaxAPI.h>
#include "nm-wimax-util.h"
#include "nm-utils.h"
#include "iwmxsdk.h"

View file

@ -23,7 +23,13 @@
#include <glib.h>
#pragma GCC diagnostic push
#pragma GCC diagnostic ignored "-Wstrict-prototypes"
#include <WiMaxType.h>
#pragma GCC diagnostic pop
#include <WiMaxError.h>
#include "nm-wimax-types.h"