mirror of
https://github.com/xen-project/xen.git
synced 2026-10-28 02:01:24 +01:00
Introduce an autoconf macro to check for the include path of certain headers that can be different between OSes. Use such macro to find the correct path for the endian.h header, and modify the users of endian.h to use the output of such check. Suggested-by: Ian Jackson <iwj@xenproject.org> Signed-off-by: Roger Pau Monné <roger.pau@citrix.com> Reviewed-by: Ian Jackson <iwj@xenproject.org> Release-Acked-by: Ian Jackson <iwj@xenproject.org>
46 lines
1.0 KiB
C
46 lines
1.0 KiB
C
#include <stdio.h>
|
|
#include INCLUDE_ENDIAN_H
|
|
#include <stdlib.h>
|
|
#include <stddef.h>
|
|
#include <stdint.h>
|
|
#include <inttypes.h>
|
|
|
|
#include "xg_private.h"
|
|
#include "xg_dom_decompress_unsafe.h"
|
|
|
|
typedef uint8_t u8;
|
|
|
|
typedef uint16_t __u16;
|
|
typedef uint32_t __u32;
|
|
typedef uint64_t __u64;
|
|
|
|
typedef uint16_t __le16;
|
|
typedef uint32_t __le32;
|
|
typedef uint64_t __le64;
|
|
|
|
typedef uint16_t __be16;
|
|
typedef uint32_t __be32;
|
|
typedef uint64_t __be64;
|
|
|
|
#define __attribute_const__
|
|
#define __force
|
|
#define always_inline
|
|
#define noinline
|
|
|
|
#undef ERROR
|
|
|
|
#define __BYTEORDER_HAS_U64__
|
|
#define __TYPES_H__ /* xen/types.h guard */
|
|
#include "../../xen/include/xen/byteorder/little_endian.h"
|
|
#define __ASM_UNALIGNED_H__ /* asm/unaligned.h guard */
|
|
#include "../../xen/include/xen/unaligned.h"
|
|
#include "../../xen/include/xen/xxhash.h"
|
|
#include "../../xen/lib/xxhash64.c"
|
|
#include "../../xen/common/unzstd.c"
|
|
|
|
int xc_try_zstd_decode(
|
|
struct xc_dom_image *dom, void **blob, size_t *size)
|
|
{
|
|
return xc_dom_decompress_unsafe(unzstd, dom, blob, size);
|
|
}
|