You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@arrow.apache.org by ap...@apache.org on 2021/02/23 09:53:30 UTC

[arrow] branch master updated: ARROW-11501: [C++] endianness check does not work on Solaris

This is an automated email from the ASF dual-hosted git repository.

apitrou pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/arrow.git


The following commit(s) were added to refs/heads/master by this push:
     new f60c0b8  ARROW-11501: [C++] endianness check does not work on Solaris
f60c0b8 is described below

commit f60c0b8e30532ca8a607e1e330087b8f9e0a0673
Author: Neal Richardson <ne...@gmail.com>
AuthorDate: Tue Feb 23 10:51:27 2021 +0100

    ARROW-11501: [C++] endianness check does not work on Solaris
    
    This includes the change that @kiszk suggested, also applied to the vendored fast_float header as well. That patch has been upstreamed (https://github.com/fastfloat/fast_float/pull/59). I have confirmed that this now compiles on Solaris.
    
    Closes #9549 from nealrichardson/sun-endian
    
    Authored-by: Neal Richardson <ne...@gmail.com>
    Signed-off-by: Antoine Pitrou <an...@python.org>
---
 cpp/src/arrow/util/endian.h                      | 2 ++
 cpp/src/arrow/vendored/fast_float/README.md      | 1 +
 cpp/src/arrow/vendored/fast_float/float_common.h | 4 ++++
 3 files changed, 7 insertions(+)

diff --git a/cpp/src/arrow/util/endian.h b/cpp/src/arrow/util/endian.h
index 81577e9..0cb2e44 100644
--- a/cpp/src/arrow/util/endian.h
+++ b/cpp/src/arrow/util/endian.h
@@ -22,6 +22,8 @@
 #else
 #if defined(__APPLE__) || defined(__FreeBSD__)
 #include <machine/endian.h>  // IWYU pragma: keep
+#elif defined(sun) || defined(__sun)
+#include <sys/byteorder.h>  // IWYU pragma: keep
 #else
 #include <endian.h>  // IWYU pragma: keep
 #endif
diff --git a/cpp/src/arrow/vendored/fast_float/README.md b/cpp/src/arrow/vendored/fast_float/README.md
index d0b249e..876d6b0 100644
--- a/cpp/src/arrow/vendored/fast_float/README.md
+++ b/cpp/src/arrow/vendored/fast_float/README.md
@@ -5,3 +5,4 @@ See https://github.com/lemire/fast_float
 
 Changes:
 - enclosed in `arrow_vendored` namespace.
+- changeset e0bd5735300e761d8553a24b0525dd1e856fa4ca has been applied (Solaris endian header)
\ No newline at end of file
diff --git a/cpp/src/arrow/vendored/fast_float/float_common.h b/cpp/src/arrow/vendored/fast_float/float_common.h
index 6127fe6..0147468 100644
--- a/cpp/src/arrow/vendored/fast_float/float_common.h
+++ b/cpp/src/arrow/vendored/fast_float/float_common.h
@@ -32,6 +32,10 @@
 #else
 #if defined(__APPLE__) || defined(__FreeBSD__)
 #include <machine/endian.h>
+// Start: addition to Arrow for Solaris support
+#elif defined(sun) || defined(__sun)
+#include <sys/byteorder.h>  // IWYU pragma: keep
+// End
 #else
 #include <endian.h>
 #endif