www.pudn.com > av3dec_20050318.zip > sysOS.h


/*------------ Telecommunications & Signal Processing Lab -------------- 
                         McGill University 
 
Routine: 
  sysOS.h 
 
Description: 
  System and OS definitions 
 
Author / revision: 
  P. Kabal  Copyright (C) 1999 
  $Revision: 1.8 $  $Date: 1999/06/14 14:22:32 $ 
 
----------------------------------------------------------------------*/ 
 
#ifndef sysOS_h_ 
#define sysOS_h_ 
 
/* Operating System 
   - pure Unix 
     - file names: "/usr/xxx/yyy" 
     - text files same as binary files 
     - Posix routines available (in "unistd.h" for example) 
   - pure Windows 
     - file names: "D:\xxx\yyy" 
     - text files differ from binary files 
     - some Posix routines available in various places 
   - hybrid: Unix running under Windows (Cygwin) 
     - file names: "//d/xxx/yyy" 
     - text files differ from binary files 
     - Posix routines available (in "unistd.h" for example) 
*/ 
#define SY_OS_UNIX	0 
#define SY_OS_WINDOWS	1 
#define SY_OS_CYGWIN	2 
#define SY_FNS_UNIX	0 
#define SY_FNS_WINDOWS	1 
#if (defined(_WIN32) && ! defined(__CYGWIN32__)) 
#  define SY_OS			SY_OS_WINDOWS 
#  define SY_FILENAME_SPEC	SY_FNS_WINDOWS 
#  define SY_POSIX		0 
#elif (defined(_WIN32) && defined(__CYGWIN32__)) 
#  define SY_OS			SY_OS_CYGWIN 
#  define SY_FILENAME_SPEC	SY_FNS_UNIX 
#  define SY_POSIX		1 
#else 
#  define SY_OS			SY_OS_UNIX 
#  define SY_FILENAME_SPEC	SY_FNS_UNIX 
#  define SY_POSIX		1 
#endif 
 
#define SY_FS_UNIX	0 
#define SY_FS_X		1	/* Other */ 
#if (SY_OS == SY_OS_UNIX) 
#  define SY_FILE_SYS	SY_FS_UNIX 
# 
#endif 
 
#endif /* sysOS_h_ */