home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
OS/2 Shareware BBS: 10 Tools
/
10-Tools.zip
/
tvos200.zip
/
CPL
/
WATSTUB.H
< prev
Wrap
C/C++ Source or Header
|
1995-04-12
|
2KB
|
87 lines
/*
* WatCOM to generic library stub
* ==============================
* (C)1995 by F. Jalvingh; All rights reserved.
*
* This header file contains defines, function prototypes etc. to allow
* the WatCOM 10.0a compiler to compile TurboC programs..
*
* Update history:
* ===============
* $Log$
*
*
*/
#ifndef __watstub_h
#define __watstub_h
/**** Defines ****/
#ifdef __32BITS__
//
// WatCOM beginthread call uses dummy 'stack'
//
# define beginthread(a,b,c) _beginthread((a), 0, (b), (c))
#endif
/**** Translated constants: defined in dos.h (both compilers) ****/
#define FA_RDONLY _A_RDONLY
#define FA_HIDDEN _A_HIDDEN
#define FA_SYSTEM _A_SYSTEM
#define FA_LABEL _A_VOLID
#define FA_DIREC _A_SUBDIR
#define FA_ARCH _A_ARCH
/**** ftime structure ****/
struct ftime {
unsigned ft_tsec : 5; /* Two second interval */
unsigned ft_min : 6; /* Minutes */
unsigned ft_hour : 5; /* Hours */
unsigned ft_day : 5; /* Days */
unsigned ft_month : 4; /* Months */
unsigned ft_year : 7; /* Year */
};
struct ffblk
{
char ff_reserved[21];
char ff_attrib;
unsigned ff_ftime;
unsigned ff_fdate;
long ff_fsize;
char ff_name[13];
};
#ifdef __cplusplus
extern "C" {
#endif
int findfirst (const char *path, struct ffblk *ffblk,
int attrib);
int findnext (struct ffblk *ffblk);
#define getftime(ha,ft) _dos_getftime((ha), &((unsigned *)(ft))[1], ((unsigned *)(ft)))
int setftime(int ha, struct ftime *ft);
#define WILDCARDS 0x01
#define EXTENSION 0x02
#define FILENAME 0x04
#define DIRECTORY 0x08
#define DRIVE 0x10
int fnsplit(const char *pathp, char *drivep, char *dirp, char *namep, char *extp);
void fnmerge(char *out, char const *drive, char const *dir, char const *name, char const *ext);
int getdisk(void);
int setdisk(int drive);
int getcurdir(int drive, char *dir);
#ifdef __cplusplus
};
#endif
#endif