Fix test builds.
authorPauli <paul.dale@oracle.com>
Thu, 28 Mar 2019 05:02:19 +0000 (15:02 +1000)
committerPauli <paul.dale@oracle.com>
Thu, 28 Mar 2019 05:02:19 +0000 (15:02 +1000)
/usr/include/bits/waitstatus.h includes endian.h under some libc's.
This clashes with the new test header file, so rename the latter.

Reviewed-by: Tim Hudson <tjh@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/8600)

test/endian.h [deleted file]
test/ossl_test_endian.h [new file with mode: 0644]
test/params_api_test.c

diff --git a/test/endian.h b/test/endian.h
deleted file mode 100644 (file)
index 0bcec04..0000000
+++ /dev/null
@@ -1,22 +0,0 @@
-/*
- * Copyright 2019 The OpenSSL Project Authors. All Rights Reserved.
- *
- * Licensed under the Apache License 2.0 (the "License").  You may not use
- * this file except in compliance with the License.  You can obtain a copy
- * in the file LICENSE in the source distribution or at
- * https://www.openssl.org/source/license.html
- */
-
-#ifndef HEADER_INTERNAL_ENDIAN_H
-# define HEADER_INTERNAL_ENDIAN_H
-
-# define DECLARE_IS_ENDIAN \
-    const union { \
-        long one; \
-        char little; \
-    } ossl_is_endian = { 1 }
-
-# define IS_LITTLE_ENDIAN (ossl_is_endian.little != 0)
-# define IS_BIG_ENDIAN    (ossl_is_endian.little == 0)
-
-#endif
diff --git a/test/ossl_test_endian.h b/test/ossl_test_endian.h
new file mode 100644 (file)
index 0000000..0bcec04
--- /dev/null
@@ -0,0 +1,22 @@
+/*
+ * Copyright 2019 The OpenSSL Project Authors. All Rights Reserved.
+ *
+ * Licensed under the Apache License 2.0 (the "License").  You may not use
+ * this file except in compliance with the License.  You can obtain a copy
+ * in the file LICENSE in the source distribution or at
+ * https://www.openssl.org/source/license.html
+ */
+
+#ifndef HEADER_INTERNAL_ENDIAN_H
+# define HEADER_INTERNAL_ENDIAN_H
+
+# define DECLARE_IS_ENDIAN \
+    const union { \
+        long one; \
+        char little; \
+    } ossl_is_endian = { 1 }
+
+# define IS_LITTLE_ENDIAN (ossl_is_endian.little != 0)
+# define IS_BIG_ENDIAN    (ossl_is_endian.little == 0)
+
+#endif
index c99af3d58b206237ed7b5716f0611636b2df3549..15dfb16f2a3b07255bf81a53accf256c8b0aeb61 100644 (file)
@@ -11,7 +11,7 @@
 #include <string.h>
 #include "testutil.h"
 #include "internal/nelem.h"
-#include "endian.h"
+#include "ossl_test_endian.h"
 #include <openssl/params.h>
 #include <openssl/bn.h>