1/* 2 Copyright (c) 1990-2000 Info-ZIP. All rights reserved. 3 4 See the accompanying file LICENSE, version 2000-Apr-09 or later 5 (the contents of which are also included in unzip.h) for terms of use. 6 If, for some reason, all these files are missing, the Info-ZIP license 7 also may be found at: ftp://ftp.info-zip.org/pub/infozip/license.html 8*/ 9#ifndef __theos_thscfg_h 10#define __theos_thscfg_h 11 12#include <unistd.h> /* dup proto & unix system calls live here */ 13#define _HANDLE_DEFINED 14#include <fcntl.h> /* O_BINARY for open() w/o CR/LF translation */ 15#include <conio.h> 16#include <time.h> 17#include <sys/types.h> /* off_t, time_t, dev_t, ... */ 18#include "theos/stat.h" 19#include <sys/utime.h> 20#define GOT_UTIMBUF 21#define DATE_FORMAT dateformat() 22#define SCREENLINES screenlines() 23#define USE_EF_UT_TIME 24#define DIR_END '/' 25#define INT_SPRINTF 26#define lenEOL 1 27#define PutNativeEOL *q++ = native(CR); 28#define PIPE_ERROR (errno = 9999) 29#define isatty(a) _isatty(a) 30#undef match 31int open(const char *name, int mode, ...); 32size_t read(int fd, char *buf, size_t len); 33size_t write(int fd, char *buf, size_t len); 34unsigned long lseek(int fd, long offset, int base); 35int close(int); 36int _fprintf(FILE *fp, const char *fmt, ...); 37int _isatty(int); 38typedef unsigned char uid_t; 39typedef unsigned char gid_t; 40 41extern int _sprintf(char *s, const char *fmt, ...); 42 43#ifndef NO_BOGUS_SPC 44# include <stdio.h> 45# undef fprintf 46# undef sprintf 47# define fprintf _fprintf 48# define sprintf _sprintf 49#else /* NO_BOGUS_SPC */ 50#ifndef Info /* may already have been defined for redirection */ 51# ifdef FUNZIP 52# define Info(buf,flag,sprf_arg) \ 53 fprintf((flag)&1? stderr : stdout, (char *)(_sprintf sprf_arg, (buf))) 54# else 55# define Info(buf,flag,sprf_arg) \ 56 UzpMessagePrnt((zvoid *)&G, (uch *)(buf), (ulg)_sprintf sprf_arg, (flag)) 57# endif 58#endif /* !Info */ 59#endif /* ?NO_BOGUS_SPC */ 60 61#endif /* !__theos_thscfg_h */ 62 63