wmii/include/plan9.h

46 lines
769 B
C
Raw Normal View History

/*
* compiler directive on Plan 9
*/
/*
* easiest way to make sure these are defined
*/
2007-07-03 13:13:01 +04:00
#ifndef KENC
# ifndef USED
# define USED(x) if(x);else
# endif
#endif
2008-01-18 23:05:45 +03:00
#define uchar _p9uchar
#define ushort _p9ushort
#define uint _p9uint
#define ulong _p9ulong
typedef unsigned char uchar;
typedef unsigned short ushort;
typedef unsigned int uint;
typedef unsigned long ulong;
typedef long long vlong;
typedef unsigned long long uvlong;
2007-07-03 13:13:01 +04:00
#include <utf.h>
#include <stdint.h>
#include <fmt.h>
#include <string.h>
#include <unistd.h>
#define OREAD O_RDONLY
#define OWRITE O_WRONLY
#define OCEXEC 0
#define ORCLOSE 0
#define OTRUNC 0
#define exits(x) exit(x && *x ? 1 : 0)
#undef nil
#define nil ((void*)0)
#undef nelem
#define nelem(x) (sizeof (x)/sizeof (x)[0])