diff options
author | Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk> | 2022-02-08 22:10:11 +0000 |
---|---|---|
committer | Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk> | 2022-02-08 22:10:11 +0000 |
commit | 88eb9291fc0b866f0b5e81e63ef8c83022c3d7b2 (patch) | |
tree | 31ae328bb7c9c750b4ce068a5eda824b15338fa7 | |
parent | edd14f40ab3ccc585a6259dd990a07294596ca45 (diff) | |
download | openbios-88eb9291fc0b866f0b5e81e63ef8c83022c3d7b2.zip openbios-88eb9291fc0b866f0b5e81e63ef8c83022c3d7b2.tar.gz openbios-88eb9291fc0b866f0b5e81e63ef8c83022c3d7b2.tar.bz2 |
arch/unix/unix.c: fix build on x86 architecture with modern gcc compilers
Modern gcc compilers will fail to build x86 OpenBIOS failing with the error
message "libc/misc.c:20: multiple definition of `errno_int'" during link.
Since the accompanying comment mentions that the reason for adding the
definition is to allow compilation to succeed on OS X, surround it with
suitable #if defined(__APPLE__) ... #endif guards.
Signed-off-by: Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk>
-rw-r--r-- | arch/unix/unix.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/arch/unix/unix.c b/arch/unix/unix.c index 1f628eb..cb9757e 100644 --- a/arch/unix/unix.c +++ b/arch/unix/unix.c @@ -68,7 +68,9 @@ static int verbose = 0; unsigned long isa_io_base; #endif +#if defined(__APPLE__) int errno_int; /* implement for fs drivers, needed to build on Mac OS X */ +#endif ucell ofmem_claim(ucell addr, ucell size, ucell align) { |