From cb2357f481396820ec954dc4b69eafc01a8d162a Mon Sep 17 00:00:00 2001 From: Fabrice Fontaine Date: Mon, 3 Feb 2020 21:24:25 +0100 Subject: [PATCH] test: fix build when SHOULD_FORK is false The code in test/cairo-test-runner.c properly takes into account platforms that do have fork() support, and uses the SHOULD_FORK define to know whether fork is available or not. However, this SHOULD_FORK macro is used to guard the inclusion of , which is needed to get the prototype of other functions (namely readlink and getppid), that are used in portions of this file not guarded by SHOULD_FORK. Signed-off-by: Thomas Petazzoni [Retrieved from: https://git.buildroot.net/buildroot/tree/package/cairo/0001-fix-nofork-build.patch] Signed-off-by: Fabrice Fontaine --- test/cairo-test-runner.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/cairo-test-runner.c b/test/cairo-test-runner.c index f9e7d4712..b1f77b358 100644 --- a/test/cairo-test-runner.c +++ b/test/cairo-test-runner.c @@ -36,10 +36,10 @@ #include /* for version information */ #define SHOULD_FORK HAVE_FORK && HAVE_WAITPID -#if SHOULD_FORK #if HAVE_UNISTD_H #include #endif +#if SHOULD_FORK #if HAVE_SIGNAL_H #include #endif