util: arch.h: use #pragma once in headers

Signed-off-by: Jonathon Jongsma <jjongsma@redhat.com>
Reviewed-by: Ján Tomko <jtomko@redhat.com>
Signed-off-by: Ján Tomko <jtomko@redhat.com>
This commit is contained in:
Jonathon Jongsma 2019-06-18 11:12:49 -05:00 committed by Ján Tomko
parent 7987eeaf9c
commit 1a5a5b3d3a

View File

@ -19,10 +19,9 @@
* *
*/ */
#ifndef LIBVIRT_VIRARCH_H #pragma once
# define LIBVIRT_VIRARCH_H
# include "internal.h" #include "internal.h"
typedef enum { typedef enum {
VIR_ARCH_NONE, VIR_ARCH_NONE,
@ -73,28 +72,28 @@ typedef enum {
VIR_ARCH_LAST, VIR_ARCH_LAST,
} virArch; } virArch;
# define ARCH_IS_X86(arch) ((arch) == VIR_ARCH_X86_64 ||\ #define ARCH_IS_X86(arch) ((arch) == VIR_ARCH_X86_64 ||\
(arch) == VIR_ARCH_I686) (arch) == VIR_ARCH_I686)
# define ARCH_IS_PPC(arch) ((arch) == VIR_ARCH_PPC ||\ #define ARCH_IS_PPC(arch) ((arch) == VIR_ARCH_PPC ||\
(arch) == VIR_ARCH_PPCLE ||\ (arch) == VIR_ARCH_PPCLE ||\
(arch) == VIR_ARCH_PPC64 ||\ (arch) == VIR_ARCH_PPC64 ||\
(arch) == VIR_ARCH_PPC64LE ||\ (arch) == VIR_ARCH_PPC64LE ||\
(arch) == VIR_ARCH_PPCEMB) (arch) == VIR_ARCH_PPCEMB)
# define ARCH_IS_PPC64(arch) ((arch) == VIR_ARCH_PPC64 ||\ #define ARCH_IS_PPC64(arch) ((arch) == VIR_ARCH_PPC64 ||\
(arch) == VIR_ARCH_PPC64LE) (arch) == VIR_ARCH_PPC64LE)
# define ARCH_IS_ARM(arch) ((arch) == VIR_ARCH_ARMV6L ||\ #define ARCH_IS_ARM(arch) ((arch) == VIR_ARCH_ARMV6L ||\
(arch) == VIR_ARCH_ARMV7L ||\ (arch) == VIR_ARCH_ARMV7L ||\
(arch) == VIR_ARCH_ARMV7B ||\ (arch) == VIR_ARCH_ARMV7B ||\
(arch) == VIR_ARCH_AARCH64) (arch) == VIR_ARCH_AARCH64)
# define ARCH_IS_RISCV(arch) ((arch) == VIR_ARCH_RISCV32 ||\ #define ARCH_IS_RISCV(arch) ((arch) == VIR_ARCH_RISCV32 ||\
(arch) == VIR_ARCH_RISCV64) (arch) == VIR_ARCH_RISCV64)
# define ARCH_IS_S390(arch) ((arch) == VIR_ARCH_S390 ||\ #define ARCH_IS_S390(arch) ((arch) == VIR_ARCH_S390 ||\
(arch) == VIR_ARCH_S390X) (arch) == VIR_ARCH_S390X)
typedef enum { typedef enum {
VIR_ARCH_LITTLE_ENDIAN, VIR_ARCH_LITTLE_ENDIAN,
@ -107,5 +106,3 @@ const char *virArchToString(virArch arch);
virArch virArchFromString(const char *name); virArch virArchFromString(const char *name);
virArch virArchFromHost(void); virArch virArchFromHost(void);
#endif /* LIBVIRT_VIRARCH_H */