aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndrew Waterman <andrew@sifive.com>2019-03-24 23:08:10 -0700
committerAndrew Waterman <andrew@sifive.com>2019-03-24 23:08:10 -0700
commit97b683ed3cbeeb059e5ad3de8f884db734447d56 (patch)
tree273759601d04b26c626462b4a0139c4cd6a406f1
parenta1c125dde740f5acd1e20a341cf3426ea44af292 (diff)
downloadpk-97b683ed3cbeeb059e5ad3de8f884db734447d56.zip
pk-97b683ed3cbeeb059e5ad3de8f884db734447d56.tar.gz
pk-97b683ed3cbeeb059e5ad3de8f884db734447d56.tar.bz2
Fix build with newer newlib
-rw-r--r--pk/elf.c4
-rw-r--r--pk/syscall.h1
2 files changed, 3 insertions, 2 deletions
diff --git a/pk/elf.c b/pk/elf.c
index c154f7e..43810ec 100644
--- a/pk/elf.c
+++ b/pk/elf.c
@@ -1,14 +1,14 @@
// See LICENSE for license details.
-#include "mmap.h"
#include "pk.h"
#include "mtrap.h"
#include "boot.h"
#include "bits.h"
+#include "elf.h"
#include <sys/stat.h>
#include <fcntl.h>
-#include <elf.h>
#include <string.h>
+#include "mmap.h"
/**
* The protection flags are in the p_flags section of the program header.
diff --git a/pk/syscall.h b/pk/syscall.h
index 963158e..478ea61 100644
--- a/pk/syscall.h
+++ b/pk/syscall.h
@@ -68,6 +68,7 @@
#define ERR_PTR(x) ((void*)(long)(x))
#define PTR_ERR(x) ((long)(x))
+#undef AT_FDCWD
#define AT_FDCWD -100
long do_syscall(long a0, long a1, long a2, long a3, long a4, long a5, unsigned long n);