Files

110 lines
3.5 KiB
Diff
Raw Permalink Normal View History

Fix:
error: implicit declaration of function 'execve' is invalid in C99 [-Werror,-Wimplicit-function-declaration]
error: implicit declaration of function 'getgroups' is invalid in C99 [-Werror,-Wimplicit-function-declaration]
error: implicit declaration of function 'lseek' is invalid in C99 [-Werror,-Wimplicit-function-declaration]
error: implicit declaration of function 'rename' is invalid in C99 [-Werror,-Wimplicit-function-declaration]
error: implicit declaration of function 'setgid' is invalid in C99 [-Werror,-Wimplicit-function-declaration]
error: implicit declaration of function 'setgroups' is invalid in C99 [-Werror,-Wimplicit-function-declaration]
error: implicitly declaring library function '_exit' with type 'void (int) __attribute__((noreturn))' [-Werror,-Wimplicit-function-declaration]
error: implicitly declaring library function 'exit' with type 'void (int) __attribute__((noreturn))' [-Werror,-Wimplicit-function-declaration]
error: implicitly declaring library function 'printf' with type 'int (const char *, ...)' [-Werror,-Wimplicit-function-declaration]
--- src/matchtest.c.orig 2001-07-12 11:49:49.000000000 -0500
+++ src/matchtest.c 2023-03-05 20:43:58.000000000 -0600
@@ -1,3 +1,4 @@
+#include <unistd.h>
#include "match.h"
#include "buffer.h"
#include "str.h"
--- src/multilog.c.orig 2001-07-12 11:49:49.000000000 -0500
+++ src/multilog.c 2023-03-05 20:43:58.000000000 -0600
@@ -1,3 +1,4 @@
+#include <stdio.h>
#include <unistd.h>
#include <sys/types.h>
#include <sys/stat.h>
--- src/pathexec_env.c.orig 2001-07-12 11:49:49.000000000 -0500
+++ src/pathexec_env.c 2023-03-05 20:43:58.000000000 -0600
@@ -1,5 +1,6 @@
/* Public domain. */
+#include <unistd.h>
#include "stralloc.h"
#include "alloc.h"
#include "str.h"
--- src/pathexec_run.c.orig 2001-07-12 11:49:49.000000000 -0500
+++ src/pathexec_run.c 2023-03-05 20:43:58.000000000 -0600
@@ -1,5 +1,6 @@
/* Public domain. */
+#include <unistd.h>
#include "error.h"
#include "stralloc.h"
#include "str.h"
--- src/prot.c.orig 2001-07-12 11:49:49.000000000 -0500
+++ src/prot.c 2023-03-05 20:43:58.000000000 -0600
@@ -1,5 +1,6 @@
/* Public domain. */
+#include <unistd.h>
#include "hasshsgr.h"
#include "prot.h"
--- src/seek_set.c.orig 2001-07-12 11:49:49.000000000 -0500
+++ src/seek_set.c 2023-03-05 20:43:58.000000000 -0600
@@ -1,6 +1,7 @@
/* Public domain. */
#include <sys/types.h>
+#include <unistd.h>
#include "seek.h"
#define SET 0 /* sigh */
--- src/supervise.c.orig 2001-07-12 11:49:49.000000000 -0500
+++ src/supervise.c 2023-03-05 20:43:58.000000000 -0600
@@ -1,3 +1,4 @@
+#include <stdio.h>
#include <unistd.h>
#include <sys/types.h>
#include <sys/stat.h>
--- src/trycpp.c.orig 2001-07-12 11:49:49.000000000 -0500
+++ src/trycpp.c 2023-03-05 22:14:39.000000000 -0600
@@ -1,5 +1,8 @@
/* Public domain. */
+#include <stdio.h>
+#include <stdlib.h>
+
int main()
{
#ifdef NeXT
--- src/trypoll.c.orig 2001-07-12 11:49:49.000000000 -0500
+++ src/trypoll.c 2023-03-05 22:06:26.000000000 -0600
@@ -3,6 +3,7 @@
#include <sys/types.h>
#include <fcntl.h>
#include <poll.h>
+#include <unistd.h>
int main()
{
--- src/tryshsgr.c.orig 2001-07-12 11:49:49.000000000 -0500
+++ src/tryshsgr.c 2023-03-05 22:05:46.000000000 -0600
@@ -1,5 +1,7 @@
/* Public domain. */
+#include <unistd.h>
+
int main()
{
short x[4];
--- src/tryulong64.c.orig 2001-07-12 11:49:49.000000000 -0500
+++ src/tryulong64.c 2023-03-05 22:06:52.000000000 -0600
@@ -1,5 +1,7 @@
/* Public domain. */
+#include <unistd.h>
+
int main()
{
unsigned long u;