From 1f4312c3320f353a18ab4aec4b8ae725fc25c911 Mon Sep 17 00:00:00 2001 From: Rusty Russell Date: Sat, 1 Jan 2011 17:15:41 +1030 Subject: [PATCH] config.h: HAVE_FLEXIBLE_ARRAY_MEMBER --- config.h | 1 + tools/configurator/configurator.c | 2 ++ 2 files changed, 3 insertions(+) diff --git a/config.h b/config.h index fc2b892d..7ef5d3ba 100644 --- a/config.h +++ b/config.h @@ -24,6 +24,7 @@ #define HAVE_BYTESWAP_H 1 #define HAVE_COMPOUND_LITERALS 1 #define HAVE_FOR_LOOP_DECLARATION 0 +#define HAVE_FLEXIBLE_ARRAY_MEMBER 1 #define HAVE_GETPAGESIZE 1 #define HAVE_LITTLE_ENDIAN 1 #define HAVE_MMAP 1 diff --git a/tools/configurator/configurator.c b/tools/configurator/configurator.c index ffa188d7..4445139c 100644 --- a/tools/configurator/configurator.c +++ b/tools/configurator/configurator.c @@ -85,6 +85,8 @@ static struct test tests[] = { { "HAVE_FOR_LOOP_DECLARATION", INSIDE_MAIN, NULL, "for (int i = 0; i < argc; i++) { return 0; };\n" "return 1;" }, + { "HAVE_FLEXIBLE_ARRAY_MEMBER", OUTSIDE_MAIN, NULL, + "struct foo { unsigned int x; int arr[]; };" }, { "HAVE_GETPAGESIZE", DEFINES_FUNC, NULL, "#include \n" "static int func(void) { return getpagesize(); }" }, -- 2.39.2