INSTALL: fix build on Snow Leopard

http://codereview.appspot.com/116073
This commit is contained in:
Russ Cox 2009-09-11 13:51:50 -04:00
parent a673ea2203
commit fa662c9571
10 changed files with 30 additions and 4 deletions

View file

@ -18,6 +18,8 @@ extern int class[LAST][LAST];
#define max(x,y) (((x) >= (y)) ? (x) : (y)) /* beware of side effects */
#define min(x,y) (((x) <= (y)) ? (x) : (y))
#undef sprintf /* Snow Leopard */
extern char errbuf[200];
extern char *cmdname;
#define ERROR sprintf(errbuf,

View file

@ -1,4 +1,7 @@
extern char errbuf[200];
#undef sprintf /* Snow Leopard */
#define ERROR sprintf(errbuf,
#define FATAL ), yyerror(errbuf), exit(1)
#define WARNING ), yyerror(errbuf)

View file

@ -10,6 +10,9 @@
extern void yyerror(char *);
extern char errbuf[200];
#undef sprintf /* Snow Leopard */
#define ERROR sprintf(errbuf,
#define FATAL ), yyerror(errbuf), exit(1)
#define WARNING ), yyerror(errbuf)

View file

@ -12,6 +12,9 @@
#define dprintf if(dbg)printf
extern char errbuf[200];
#undef sprintf /* Snow Leopard */
#define ERROR sprintf(errbuf,
#define FATAL ), yyerror(errbuf), exit(1)
#define WARNING ), yyerror(errbuf)

View file

@ -68,6 +68,8 @@ typedef struct Tbuf Tbuf;
#define oputs(a) OUT "%s", a PUT
#define oput(c) ( *obufp++ = (c), obufp > obuf+BUFSIZ ? flusho() : 1 )
#undef sprintf /* Snow Leopard */
extern char errbuf[];
#define ERROR sprintf(errbuf,
#define WARN ), errprint()

View file

@ -1,3 +1,7 @@
#if defined(__APPLE__)
#define _DARWIN_NO_64_BIT_INODE /* Snow Leopard */
#endif
#include <u.h>
#define NOPLAN9DEFINES
#include <libc.h>

View file

@ -6,6 +6,9 @@
#include <sched.h>
#include <signal.h>
#if !defined(__OpenBSD__)
# if defined(__APPLE__)
# define _XOPEN_SOURCE /* for Snow Leopard */
# endif
# include <ucontext.h>
#endif
#include <sys/utsname.h>