mirror of
https://frontier.innolan.net/github/amigaos-cross-toolchain6.git
synced 2024-10-19 10:29:55 +00:00
Add endian aware getters and setters.
This commit is contained in:
@ -7,13 +7,15 @@
|
||||
#ifndef _DEFS_H_
|
||||
#define _DEFS_H_
|
||||
|
||||
#include <arpa/inet.h>
|
||||
#include <endian.h>
|
||||
#include <dos/doshunks.h>
|
||||
|
||||
#include "a.out.h"
|
||||
|
||||
#define GETWORD(x) ntohs(x)
|
||||
#define GETLONG(x) ntohl(x)
|
||||
#define GETWORD(x) be16toh(x)
|
||||
#define GETLONG(x) be32toh(x)
|
||||
#define PUTWORD(x) htobe16(x)
|
||||
#define PUTLONG(x) htobe32(x)
|
||||
|
||||
/* Converts an SLINE value to an offset in the text section.
|
||||
This definition is OK for ld 1.8, currently used on the Amiga AFAIK,
|
||||
|
||||
Reference in New Issue
Block a user