gnu: Add kafs-client
[jackhill/guix/guix.git] / gnu / packages / patches / gawk-shell.patch
CommitLineData
5d4fd267
LC
1As for libc's `system', change Awk to look for `sh' in $PATH. This patch is
2only meant to be used during bootstrapping, where we don't know in advance the
3absolute file name of `sh'.
4
e5865250
LC
5--- gawk-4.1.3/io.c 2015-05-19 15:37:20.000000000 +0200
6+++ gawk-4.1.3/io.c 2015-06-09 18:39:36.918414881 +0200
44e3e431 7@@ -2025,7 +2025,7 @@
5d4fd267 8
44e3e431 9 set_sigpipe_to_default();
5d4fd267 10
44e3e431
MB
11- execl("/bin/sh", "sh", "-c", command, NULL);
12+ execlp("sh", "sh", "-c", command, NULL);
13 _exit(errno == ENOENT ? 127 : 126);
14
15 case -1:
16@@ -2077,7 +2077,7 @@
5d4fd267 17
44e3e431
MB
18 signal(SIGPIPE, SIG_DFL);
19
20- execl("/bin/sh", "sh", "-c", command, NULL);
21+ execlp("sh", "sh", "-c", command, NULL);
22 _exit(errno == ENOENT ? 127 : 126);
23
24 case -1:
25@@ -2422,7 +2422,7 @@
5d4fd267
LC
26 fatal(_("close of pipe failed (%s)"), strerror(errno));
27 /* stderr does NOT get dup'ed onto child's stdout */
44e3e431 28 set_sigpipe_to_default();
5d4fd267
LC
29- execl("/bin/sh", "sh", "-c", str, NULL);
30+ execlp("sh", "sh", "-c", str, NULL);
31 _exit(errno == ENOENT ? 127 : 126);
32 }
e5865250 33 #endif /* NOT __EMX__, NOT __MINGW32__ */
44e3e431 34@@ -2659,7 +2659,7 @@
5d4fd267
LC
35 if (close(p[0]) == -1 || close(p[1]) == -1)
36 fatal(_("close of pipe failed (%s)"), strerror(errno));
44e3e431 37 set_sigpipe_to_default();
5d4fd267
LC
38- execl("/bin/sh", "sh", "-c", cmd, NULL);
39+ execlp("sh", "sh", "-c", cmd, NULL);
40 _exit(errno == ENOENT ? 127 : 126);
41 }
e5865250 42 #endif /* NOT __EMX__, NOT __MINGW32__ */