Skip to content

Commit 4727bc6

Browse files
authored
Build process.c with _GNU_SOURCE (#363)
Otherwise the build will fail on glibc 2.29 and later because posix_spawn_file_actions_addchdir_np is not declared. Starting with glibc 2.37, posix_spawn_file_actions_addchdir_np will be available with the default feature flags; see glibc commit 2ff48a4025515e93d722947a9eabb114f4a65b22 ("posix: Make posix_spawn extensions available by default").
1 parent 2ca6608 commit 4727bc6

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

Sources/TSCclibc/process.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,9 @@
11
#if defined(__linux__)
22

3+
#ifndef _GNU_SOURCE
4+
#define _GNU_SOURCE /* for posix_spawn_file_actions_addchdir_np */
5+
#endif
6+
37
#include <errno.h>
48

59
#include "process.h"

0 commit comments

Comments
 (0)