Go to the documentation of this file.00001 
00002 
00003 
00004 
00005 
00006 
00007 
00008 
00009 
00010 
00011 
00012 
00013 
00014 
00015 
00016 
00017 
00018 
00019 
00020 
00021 
00022 
00023 
00024 #if !defined (_Compatability_h_)
00025 #define _Compatability_h_
00026 
00027 #include <sys/types.h>
00028 #include <sys/uio.h>
00029 #include <unistd.h>
00030 #include <stdio.h>
00031 #include <strings.h>
00032 
00033 #include "ink_defs.h"
00034 
00035 
00036 
00037 
00038 template<class T> T min(const T a, const T b)
00039 {
00040   return a < b ? a : b;
00041 }
00042 
00043 template<class T> T max(const T a, const T b)
00044 {
00045   return a > b ? a : b;
00046 }
00047 
00048 #define _O_ATTRIB_NORMAL  0x0000
00049 #define _O_ATTRIB_OVERLAPPED 0x0000
00050 
00051 
00052 
00053 
00054 
00055 #if defined(linux)
00056 #define NEED_ALTZONE_DEFINED
00057 #define MAP_SHARED_MAP_NORESERVE (MAP_SHARED)
00058 #elif defined(darwin)
00059 #define MAP_SHARED_MAP_NORESERVE (MAP_SHARED)
00060 #elif defined(solaris)
00061 #define NEED_ALTZONE_DEFINED
00062 #define MAP_SHARED_MAP_NORESERVE (MAP_SHARED | MAP_NORESERVE)
00063 #else
00064 #define MAP_SHARED_MAP_NORESERVE (MAP_SHARED | MAP_NORESERVE)
00065 #endif
00066 
00067 #if defined(darwin)
00068 typedef uint32_t in_addr_t;
00069 #endif
00070 
00071 #define NEED_HRTIME
00072 
00073 #endif