From 162ec83f68efc89c46630f6842700bca8f16b201 Mon Sep 17 00:00:00 2001 From: Christian Ambach Date: Tue, 7 May 2013 09:06:50 +0200 Subject: waf: only use -fstack-protector when both compiler and linker support it otherwise build with xlc on AIX fails because the compiler silently ignores the parameter but the linker does not like it Signed-off-by: Christian Ambach Reviewed-by: Stefan Metzmacher --- lib/replace/wscript | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'lib/replace') diff --git a/lib/replace/wscript b/lib/replace/wscript index 9483e23089..bc45ee9043 100644 --- a/lib/replace/wscript +++ b/lib/replace/wscript @@ -53,7 +53,7 @@ struct foo bar = { .y = 'X', .x = 1 }; conf.ADD_CFLAGS(f) break - if conf.CHECK_CFLAGS(['-fstack-protector']): + if conf.CHECK_CFLAGS(['-fstack-protector']) and conf.CHECK_LDFLAGS(['-fstack-protector']): conf.ADD_CFLAGS('-fstack-protector') conf.ADD_LDFLAGS('-fstack-protector') -- cgit