From ff31da6f744c6c17de70c8e528f1a490e3bd9849 Mon Sep 17 00:00:00 2001 From: Jeff Squyres Date: Tue, 23 Jan 2018 13:44:43 -0800 Subject: [PATCH] opal_check_attributes: fix __extension__ test Per https://gcc.gnu.org/onlinedocs/gcc/Alternate-Keywords.html#index-_005f_005fextension_005f_005f, use __extension__ in a C statement that will actually verify if the compiler supports it or not. Signed-off-by: Jeff Squyres --- config/opal_check_attributes.m4 | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/config/opal_check_attributes.m4 b/config/opal_check_attributes.m4 index cd9acf6b4e2..53fa38eb0d9 100644 --- a/config/opal_check_attributes.m4 +++ b/config/opal_check_attributes.m4 @@ -11,7 +11,7 @@ dnl University of Stuttgart. All rights reserved. dnl Copyright (c) 2004-2005 The Regents of the University of California. dnl All rights reserved. dnl Copyright (c) 2009 Oak Ridge National Labs. All rights reserved. -dnl Copyright (c) 2010-2013 Cisco Systems, Inc. All rights reserved. +dnl Copyright (c) 2010-2018 Cisco Systems, Inc. All rights reserved dnl Copyright (c) 2013 Mellanox Technologies, Inc. dnl All rights reserved. dnl Copyright (c) 2015 Research Organization for Information Science @@ -569,7 +569,7 @@ AC_DEFUN([OPAL_CHECK_ATTRIBUTES], [ _OPAL_CHECK_SPECIFIC_ATTRIBUTE([extension], [ - #define FOO __extension__ ({size_t bar; bar = 3;}) + int i = __extension__ 3; ], [], [])