You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

95 lines
2.4 KiB
C

/****************************************************************************
* FileName : basetype.h *
* Programmer : Li Liangchu *
* Writen at : 2002.09.20 *
* Version : *
* Description: header of the nport.c *
* Last modify: 2002.11.6 *
****************************************************************************/
#ifndef __BASETYPE_H_ICL__
#define __BASETYPE_H_ICL__
/*#ifndef OS_WINDOWS
//#include <winsock.h>
//#else
#include <sys/types.h>
#else*/
typedef unsigned char u_char;
typedef unsigned short u_short;
typedef unsigned int u_int;
typedef unsigned long u_long;
//#endif// OS_WINDOWS
typedef u_char BYTE;
typedef u_short WORD;
typedef u_long DWORD;
typedef long i_32;
typedef u_long u_32;
typedef int BOOL;
#define TRUE 1
#define FALSE 0
typedef struct tagCMDDEF
{
u_32 CmdTimerCnt; //命令时间计数
u_32 CmdTimerConst; //命令时间间隔
} CMDDEF, *pCMDDEF;
#ifndef _WIN32
typedef long long _int64;
typedef unsigned long long _uint64;
typedef int SOCKET;
#endif
/*#ifndef OS_WINDOWS
typedef int bool;
typedef int64_t _int64;
typedef uint64_t _uint64;
typedef u_long UINT;
#define true TRUE
#define false FALSE
typedef struct
{
WORD Year __attribute__ ((packed));
u_char Month __attribute__ ((packed));
u_char Day __attribute__ ((packed));
u_char WeekDay __attribute__ ((packed));
u_char MonthDay __attribute__ ((packed));
u_char Hour __attribute__ ((packed));
u_char Min __attribute__ ((packed));
u_char Sec __attribute__ ((packed));
u_char reserved __attribute__ ((packed));
WORD mSec __attribute__ ((packed));
}DAY_TIME;
#define DSLIB_API
#else*/
#ifdef _WIN32
#ifdef DSLIB_EXPORTS
#define DSLIB_API __declspec(dllexport)
#else
#define DSLIB_API __declspec(dllimport)
#endif// DSLIB_EXPORTS
#else
#define DSLIB_API
#endif
#pragma pack (push,1)
typedef struct
{
WORD Year;
u_char Month;
u_char Day;
u_char WeekDay;
u_char MonthDay;
u_char Hour;
u_char Min;
u_char Sec;
u_char reserved;
WORD mSec;
} DAY_TIME;
#pragma pack (pop)
//#endif// OS_WINDOWS
#endif// __BASETYPE_H_ICL__