diff mbox series

[v3,6/9] bswap.h: Include <endian.h> on Haiku for bswap operations

Message ID 20200703145614.16684-7-peter.maydell@linaro.org
State Superseded
Headers show
Series Build fixes for Haiku | expand

Commit Message

Peter Maydell July 3, 2020, 2:56 p.m. UTC
From: David CARLIER <devnexen@gmail.com>


Haiku puts the bswap* functions in <endian.h>; pull in that
include file on that platform.

Signed-off-by: David Carlier <devnexen@gmail.com>

[PMM: Expanded commit message]
Reviewed-by: Peter Maydell <peter.maydell@linaro.org>

Signed-off-by: Peter Maydell <peter.maydell@linaro.org>

---
 include/qemu/bswap.h | 2 ++
 1 file changed, 2 insertions(+)

-- 
2.20.1

Comments

Thomas Huth July 3, 2020, 3:19 p.m. UTC | #1
On 03/07/2020 16.56, Peter Maydell wrote:
> From: David CARLIER <devnexen@gmail.com>

> 

> Haiku puts the bswap* functions in <endian.h>; pull in that

> include file on that platform.

> 

> Signed-off-by: David Carlier <devnexen@gmail.com>

> [PMM: Expanded commit message]

> Reviewed-by: Peter Maydell <peter.maydell@linaro.org>

> Signed-off-by: Peter Maydell <peter.maydell@linaro.org>

> ---

>  include/qemu/bswap.h | 2 ++

>  1 file changed, 2 insertions(+)

> 

> diff --git a/include/qemu/bswap.h b/include/qemu/bswap.h

> index 2a9f3fe783e..1d3e4c24e41 100644

> --- a/include/qemu/bswap.h

> +++ b/include/qemu/bswap.h

> @@ -8,6 +8,8 @@

>  # include <machine/bswap.h>

>  #elif defined(__FreeBSD__)

>  # include <sys/endian.h>

> +#elif defined(__HAIKU__)

> +# include <endian.h>

>  #elif defined(CONFIG_BYTESWAP_H)

>  # include <byteswap.h>


Reviewed-by: Thomas Huth <thuth@redhat.com>
Philippe Mathieu-Daudé July 3, 2020, 3:22 p.m. UTC | #2
On 7/3/20 4:56 PM, Peter Maydell wrote:
> From: David CARLIER <devnexen@gmail.com>

> 

> Haiku puts the bswap* functions in <endian.h>; pull in that

> include file on that platform.

> 

> Signed-off-by: David Carlier <devnexen@gmail.com>

> [PMM: Expanded commit message]

> Reviewed-by: Peter Maydell <peter.maydell@linaro.org>

> Signed-off-by: Peter Maydell <peter.maydell@linaro.org>

> ---

>  include/qemu/bswap.h | 2 ++

>  1 file changed, 2 insertions(+)

> 

> diff --git a/include/qemu/bswap.h b/include/qemu/bswap.h

> index 2a9f3fe783e..1d3e4c24e41 100644

> --- a/include/qemu/bswap.h

> +++ b/include/qemu/bswap.h

> @@ -8,6 +8,8 @@

>  # include <machine/bswap.h>

>  #elif defined(__FreeBSD__)

>  # include <sys/endian.h>

> +#elif defined(__HAIKU__)

> +# include <endian.h>

>  #elif defined(CONFIG_BYTESWAP_H)

>  # include <byteswap.h>

>  

> 


Reviewed-by: Philippe Mathieu-Daudé <philmd@redhat.com>
diff mbox series

Patch

diff --git a/include/qemu/bswap.h b/include/qemu/bswap.h
index 2a9f3fe783e..1d3e4c24e41 100644
--- a/include/qemu/bswap.h
+++ b/include/qemu/bswap.h
@@ -8,6 +8,8 @@ 
 # include <machine/bswap.h>
 #elif defined(__FreeBSD__)
 # include <sys/endian.h>
+#elif defined(__HAIKU__)
+# include <endian.h>
 #elif defined(CONFIG_BYTESWAP_H)
 # include <byteswap.h>