OpenClovis Logo

clArchHeaders.h
1 #ifndef __CL_ARCH_HEADERS_H__
2 #define __CL_ARCH_HEADERS_H__
3 
4 /*==========================================*/
5 #ifdef POSIX_BUILD
6 
7 #include <arpa/inet.h>
8 #include <sys/time.h>
9 #include <sys/socket.h>
10 #include <strings.h>
11 #include <errno.h>
12 #include <fcntl.h>
13 #include <sys/param.h>
14 #include <sys/uio.h>
15 
16 #ifdef VXWORKS_BUILD
17 #include <clVxWorks.h>
18 #elif defined(QNX_BUILD)
19 #include <clQnx.h>
20 #endif
21 
22 #define OS_VERSION_CODE 0
23 
24 #define OS_KERNEL_VERSION(x,y,z) 1
25 
26 #define CL_TIPC_PACKET_SIZE 1500
27 
28 #define CL_ENABLE_ASP_TRAFFIC_SHAPING
29 
30 /*==========================================*/
31 
32 #elif defined SOLARIS_BUILD
33 
34 #include <arpa/inet.h>
35 #include <sys/socket.h>
36 #include <sys/sem.h>
37 #include <sys/fcntl.h>
38 #include <sys/stat.h>
39 #include <errno.h>
40 #include <strings.h>
41 #include <stdlib.h>
42 #include <poll.h>
43 #include <getopt.h>
44 #include "tipc.h"
45 
46 #define OS_VERSION_CODE 0
47 #define OS_KERNEL_VERSION(x,y,z) 1
48 
49 #define CL_TIPC_PACKET_SIZE 0xFFFF
50 
51 /*==========================================*/
52 #elif defined __linux__
53 
54 #include <arpa/inet.h>
55 #include <sys/errno.h>
56 #include <sys/ipc.h>
57 #include <sys/sem.h>
58 #include <sys/fcntl.h>
59 #include <linux/version.h>
60 #include <string.h>
61 #include <poll.h>
62 #include <getopt.h>
63 #include <execinfo.h>
64 #include <unistd.h>
65 
66 #define OS_VERSION_CODE LINUX_VERSION_CODE
67 #define OS_KERNEL_VERSION KERNEL_VERSION
68 
69 #define CL_TIPC_PACKET_SIZE 0xFFFF
70 
71 
72 #endif
73 
74 #if !defined __linux__
75 
76 #define CL_NODE_RESET() do { system("reboot"); } while(0)
77 
78 #else
79 
80 #include <unistd.h>
81 #include <sys/reboot.h>
82 
83 #define CL_NODE_RESET() do { reboot(RB_AUTOBOOT); } while(0)
84 
85 #endif
86 /*==========================================*/
87 
88 #endif

Generated on Tue Jan 10 10:29:15 PST 2012 for OpenClovis SDK using Doxygen