mirror of
https://github.com/Cisco-Talos/clamav.git
synced 2026-02-05 20:42:08 -05:00
We defined WORDS_BIGENDIAN to 0 if it wasn't defined, however that doesn't work with Apple universal builds, since we don't know the endianness at configure time! So add the ifndef WORDS_BIGNENDIAN -> define WORDS_BIGENDIAN 0 logic to platform.h.
46 lines
798 B
C
46 lines
798 B
C
#ifndef _WIN32
|
|
#define closesocket(s) close(s)
|
|
#endif
|
|
|
|
#ifndef O_BINARY
|
|
#define O_BINARY 0
|
|
#endif
|
|
|
|
#ifndef FALSE
|
|
#define FALSE (0)
|
|
#endif
|
|
#ifndef TRUE
|
|
#define TRUE (1)
|
|
#endif
|
|
|
|
#ifndef MIN
|
|
#define MIN(a, b) (((a) < (b)) ? (a) : (b))
|
|
#endif
|
|
#ifndef MAX
|
|
#define MAX(a,b) (((a) > (b)) ? (a) : (b))
|
|
#endif
|
|
|
|
#ifndef HAVE_IN_PORT_T
|
|
typedef unsigned short in_port_t;
|
|
#endif
|
|
|
|
#ifndef HAVE_IN_ADDR_T
|
|
typedef unsigned int in_addr_t;
|
|
#endif
|
|
|
|
#ifdef _WIN32
|
|
#define PATHSEP "\\"
|
|
#else
|
|
#define PATHSEP "/"
|
|
#endif
|
|
|
|
#define CONFDIR_CLAMD CONFDIR PATHSEP "clamd.conf"
|
|
#define CONFDIR_FRESHCLAM CONFDIR PATHSEP "freshclam.conf"
|
|
#define CONFDIR_MILTER CONFDIR PATHSEP "clamav-milter.conf"
|
|
|
|
/* Nothing is safe in windows, not even open */
|
|
#define safe_open open
|
|
#ifndef WORDS_BIGENDIAN
|
|
#define WORDS_BIGENDIAN 0
|
|
#endif
|