Skip to content
Snippets Groups Projects
Commit 91cceebb5c3c authored by Jean-Francois Pieronne's avatar Jean-Francois Pieronne
Browse files

VMS patches for 3.2.2

parent 5f47fc19c3ae
Branches
Tags
No related merge requests found
...@@ -229,6 +229,24 @@ ...@@ -229,6 +229,24 @@
# define be64toh(x) (x) # define be64toh(x) (x)
# define le64toh(x) (((uint64_t)le32toh(((uint32_t)(((uint64_t)(x)) >> 32)))) | (((uint64_t)le32toh(((uint32_t)(x)))) << 32)) # define le64toh(x) (((uint64_t)le32toh(((uint32_t)(((uint64_t)(x)) >> 32)))) | (((uint64_t)le32toh(((uint32_t)(x)))) << 32))
#elif defined(__vms)
# #include <stdint.h>
# define htobe16(x) htons(x)
# define htole16(x) (x)
# define be16toh(x) ntohs(x)
# define le16toh(x) (x)
# define htobe32(x) htonl(x)
# define htole32(x) (x)
# define be32toh(x) ntohl(x)
# define le32toh(x) (x)
# define htobe64(x) (((uint64_t)htonl(((uint32_t)(((uint64_t)(x)) >> 32)))) | (((uint64_t)htonl(((uint32_t)(x)))) << 32))
# define htole64(x) (x)
# define be64toh(x) (((uint64_t)ntohl(((uint32_t)(((uint64_t)(x)) >> 32)))) | (((uint64_t)ntohl(((uint32_t)(x)))) << 32))
# define le64toh(x) (x)
// typedef uint8_t u_int8_t;
#else #else
# error platform not supported # error platform not supported
......
...@@ -28,6 +28,13 @@ ...@@ -28,6 +28,13 @@
typedef uint16_t u_int16_t; typedef uint16_t u_int16_t;
typedef uint32_t u_int32_t; typedef uint32_t u_int32_t;
typedef uint64_t u_int64_t; typedef uint64_t u_int64_t;
#elif defined(__vms)
#include <stdint.h>
typedef uint8_t u_int8_t;
typedef uint16_t u_int16_t;
typedef uint32_t u_int32_t;
typedef uint64_t u_int64_t;
#define __attribute__(unused)
#else #else
#include <stdint.h> #include <stdint.h>
#endif #endif
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment