From 4eb43dc4de6e88c9863dada6c9c34c74f1a024df Mon Sep 17 00:00:00 2001 From: Adrian Reber Date: Wed, 17 Feb 2021 16:58:50 +0000 Subject: [PATCH] test: fix test compilation on rawhide The latest glibc has redefined SIGSTKSZ as 'sysconf (_SC_SIGSTKSZ)' and this breaks a static char[] definition. Hardcoding TESTSIGSTKSZ to 16384 in the test. This fixes: sigaltstack.c:17:13: error: variably modified 'stack_thread' at file scope 17 | static char stack_thread[SIGSTKSZ + TEST_MSG_BUFFER_SIZE] __stack_aligned__; | ^~~~~~~~~~~~ sigaltstack.c:18:13: error: variably modified 'stack_main' at file scope 18 | static char stack_main[SIGSTKSZ + TEST_MSG_BUFFER_SIZE] __stack_aligned__; | ^~~~~~~~~~ Signed-off-by: Adrian Reber --- test/zdtm/static/sigaltstack.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/test/zdtm/static/sigaltstack.c b/test/zdtm/static/sigaltstack.c index f36d409f5..13602d3a1 100644 --- a/test/zdtm/static/sigaltstack.c +++ b/test/zdtm/static/sigaltstack.c @@ -14,8 +14,10 @@ const char *test_doc = "Check for alternate signal stack"; const char *test_author = "Cyrill Gorcunov "; -static char stack_thread[SIGSTKSZ + TEST_MSG_BUFFER_SIZE] __stack_aligned__; -static char stack_main[SIGSTKSZ + TEST_MSG_BUFFER_SIZE] __stack_aligned__; +#define TESTSIGSTKSZ 16384 + +static char stack_thread[TESTSIGSTKSZ + TEST_MSG_BUFFER_SIZE] __stack_aligned__; +static char stack_main[TESTSIGSTKSZ + TEST_MSG_BUFFER_SIZE] __stack_aligned__; enum { SAS_MAIN_OLD,