From b207c51057e00a19949c0a84261b33790c891f62 Mon Sep 17 00:00:00 2001 From: Pixel Date: Wed, 17 Dec 2008 00:11:45 -0800 Subject: Apple fixes. --- mpq-bios.c | 8 ++++++++ recycle.c | 2 +- 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/mpq-bios.c b/mpq-bios.c index d2c96f7..7ed56f8 100644 --- a/mpq-bios.c +++ b/mpq-bios.c @@ -12,6 +12,10 @@ #include #endif +#ifdef __APPLE__ +#define lseek64 lseek +#endif + #include #include #include @@ -129,6 +133,10 @@ struct mpq_archive_t { #define O_BINARY 0 #endif +#ifndef O_LARGEFILE +#define O_LARGEFILE 0 +#endif + struct mpq_archive_t * mpqlib_open_archive(const char * fname) { int fd; struct mpq_archive_t * r; diff --git a/recycle.c b/recycle.c index 084854b..25af503 100644 --- a/recycle.c +++ b/recycle.c @@ -78,7 +78,7 @@ char *purpose; char *x = (char *)malloc(len); if (!x) { - fprintf(stderr, "malloc of %d failed for %s\n", + fprintf(stderr, "malloc of %ld failed for %s\n", len, purpose); exit(-1); } -- cgit v1.2.3