summaryrefslogtreecommitdiffstats
path: root/Modules
diff options
context:
space:
mode:
authorAndre McCurdy <armccurdy@gmail.com>2016-10-14 23:26:58 (GMT)
committerAndre McCurdy <armccurdy@gmail.com>2016-10-14 23:26:58 (GMT)
commit4bc17345c01ea467099e28c7df30c23ace9e7811 (patch)
tree827f3459cbebb7ab4f8a45fb5c529c4426299705 /Modules
parent0d818632978a450f1afaf687c867e62e885457f7 (diff)
downloadCMake-4bc17345c01ea467099e28c7df30c23ace9e7811.zip
CMake-4bc17345c01ea467099e28c7df30c23ace9e7811.tar.gz
CMake-4bc17345c01ea467099e28c7df30c23ace9e7811.tar.bz2
CheckFunctionExists.c: avoid gcc warnings with -Wstrict-prototypes
Avoid warnings (and therefore build failures etc) if a user happens to add -Wstrict-prototypes to CFLAGS. | $ gcc --version | gcc (Ubuntu 4.8.4-2ubuntu1~14.04.3) 4.8.4 | | $ gcc -Wstrict-prototypes -Werror -DCHECK_FUNCTION_EXISTS=pthread_create -o foo.o -c Modules/CheckFunctionExists.c | Modules/CheckFunctionExists.c:7:3: error: function declaration isn't a prototype [-Werror=strict-prototypes] | CHECK_FUNCTION_EXISTS(); | ^ | cc1: all warnings being treated as errors | Signed-off-by: Andre McCurdy <armccurdy@gmail.com>
Diffstat (limited to 'Modules')
-rw-r--r--Modules/CheckFunctionExists.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/Modules/CheckFunctionExists.c b/Modules/CheckFunctionExists.c
index 2304000..224e340 100644
--- a/Modules/CheckFunctionExists.c
+++ b/Modules/CheckFunctionExists.c
@@ -4,7 +4,7 @@
extern "C"
#endif
char
- CHECK_FUNCTION_EXISTS();
+ CHECK_FUNCTION_EXISTS(void);
#ifdef __CLASSIC_C__
int main()
{