239N/Alib _fxstat,__fxstat,_lxstat,__lxstat,_xmknod,__xmknod,_xstat,__xstat,lstat,mknod,sync
sys/types.h sys/stat.h 239N/Alcl xstat -D_LARGEFILE64_SOURCE link{
239N/A struct stat64 { int xxx; }; /* disable if stat64 available */
239N/A extern int stat(const char* path, struct stat* st)
239N/A return __xstat(_STAT_VER, path, st);
239N/A return _xstat(_STAT_VER, path, st);
239N/A return stat(".",&st) < 0;
239N/Alcl xstat64 -D_LARGEFILE64_SOURCE link{
1258N/A extern int stat64(const char* path, struct stat64* st)
239N/A return __xstat64(_STAT_VER, path, st);
239N/A return _xstat64(_STAT_VER, path, st);
239N/A return stat64(".",&st) < 0;
3817N/Aextern chmod int (const char*, mode_t)
3817N/Aextern fstat int (int, struct stat*)
3817N/Aextern lstat int (const char*, struct stat*)
3817N/Aextern mkdir int (const char*, mode_t)
3817N/Aextern mkfifo int (const char*, mode_t)
3817N/Aextern mknod int (const char*, mode_t, dev_t)
3817N/Aextern stat int (const char*, struct stat*)
3817N/Aextern mkfifo mode_t (mode_t)
<<"#if defined(__STDPP__directive) && defined(__STDPP__initial)">>
<<"__STDPP__directive pragma pp:initial">>
<<"#define major(x)">> major((x))
#define L_MAXMAJ ((1<<L_BITSMAJOR)-1)
#define L_MAXMIN ((1<<L_BITSMINOR)-1)
<<"#define major(x)">> ((int)(((unsigned)(x)>>L_BITSMINOR)&L_MAXMAJ))
<<"#define minor(x)">> minor((x))
<<"#define minor(x)">> ((int)((x)&L_MAXMIN))
<<"#define makedev(x,y)">> makedev((x),(y))
<<"#define makedev(x,y)">> ((dev_t)((((x)&0377)<<8)|((y)&0377)))
<<"#if defined(__STDPP__directive) && defined(__STDPP__initial)">>
<<"__STDPP__directive pragma pp:noinitial">>
#define major(x) ((int)(((unsigned)(x)>>8)&0377))
#define minor(x) ((int)((x)&0377))
#define makedev(x,y) ((dev_t)((((x)&0377)<<8)|((y)&0377)))
sys fs_types,mount,statfs,statvfs,vfs,vmount
int f(vp)struct statvfs* vp;{return vp->f_reserved7[0] = 1;}
lib getmntent,getmntinfo,mntctl,mntopen,mntread,mntclose,setmntent
return statfs("/",&fs,sizeof(fs),0);
lib getmntinfo_statvfs note{ getmntinfo uses statvfs -- since when? }end compile{
return getmntinfo(fs, 0);
#if !_mem_statvfs_f_basetype
#define f_basetype f_reserved7
#define _mem_f_basetype_statvfs 1
#define _mem_f_frsize_statvfs 1
unsigned long f_bsize; /* fundamental file system block size */
unsigned long f_frsize; /* fragment size */
unsigned long f_blocks; /* total # of blocks of f_frsize on fs */
unsigned long f_bfree; /* total # of free blocks of f_frsize */
unsigned long f_bavail; /* # of free blocks avail to non-superuser */
unsigned long f_files; /* total # of file nodes (inodes) */
unsigned long f_ffree; /* total # of free file nodes */
unsigned long f_favail; /* # of free nodes avail to non-superuser */
unsigned long f_fsid; /* file system id (dev for now) */
char f_basetype[16]; /* target fs type name, null-terminated */
unsigned long f_flag; /* bit-mask of flags */
unsigned long f_namemax; /* maximum file name length */
char f_fstr[32]; /* filesystem-specific string */
unsigned long f_filler[16]; /* reserved for future expansion */
extern int fstatvfs(int, struct statvfs*);
extern int statvfs(const char*, struct statvfs*);
#if _lib_statvfs64 && !defined(statvfs)
#define statvfs statvfs64
#if !defined(__USE_LARGEFILE64)
extern int statvfs64(const char*, struct statvfs64*);
#if _lib_fstatvfs64 && !defined(fstatvfs)
#define fstatvfs fstatvfs64
#if !defined(__USE_LARGEFILE64)
extern int fstatvfs64(int, struct statvfs64*);
int f(st)struct stat* st;{return st->st_fstype[0];}
int f(st)struct stat* st;{return st->st_fstype = 1;}
int f(st)struct stat* st;{return st->st_spare1 = 1;}
int f(st)struct stat* st;{return st->st_spare4[0] = 1;}
int f(st)struct stat* st;{return st->st_pad4[0] = 1;}