This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
[PATCH] string/endian.h: Restore the __USE_MISC conditionals
- From: Alistair Francis <alistair dot francis at wdc dot com>
- To: libc-alpha at sourceware dot org
- Cc: alistair23 at gmail dot com, Alistair Francis <alistair dot francis at wdc dot com>
- Date: Wed, 2 Oct 2019 11:20:38 -0700
- Subject: [PATCH] string/endian.h: Restore the __USE_MISC conditionals
- Ironport-sdr: SPt3p8FobiyqiuK8/kw6snfKSJc7bVPeliZbUqeUXnhhFZ1igw2E1EUnQBfRS0xdfuyPG4+3/v Wm8xZEXFkczv6r3NZ3PIc1Se26LcCBD4cN1zez8o27ALXnzM1R+v2w3ulwx36zr+yT9HRSUfdh EeHAJS40vK7WHIOkLTmdIDp1udZLjNQrqSZO4bQgp/Nrc1Gk5slneGFxsccN6oFfVEw1qwWJb0 GqvOslts2Wsk9NnvTyWtGqCPU469hCyzgYIfVRR1oSdTltdWEzWwXbhJYIwxa71bd8pXcsdJtp 6FQ=
- Ironport-sdr: rrT18oghmqtHFnf4jJqewY4+SAnF2cKTNufCd7rVdib0LedDcDkPi3mbAgMKYlGd5mbztIr6sw RIPSRdLQJ0PkJK7dbwbJsEbIV3AMpcKdTgYpc1YK/TaiTZh3vTxWQJiZ/x8qSb3lcmGswDr5nM +/KLInuXfvPNMoDC1wGjStkKjXd0GpRqepQ1F3IaV+2EDqituopUPl9ecA1dAB90Achh0diAQ4 kvDc5SlupL3DAyZcTtNw6p8iAVBQwflJTwLbqwoRcX2Gh+gI6zgxX2pqKGdP1ACq5mzWQlzswO 2wwuDHkmBosxKxHE/XQ4Ea7I
- Ironport-sdr: UoU93M553BLny7ajG7oyMMYeXOKrERBJvuz8joatNvAkJYXONmAPgn3Hr9QsIOn/AQmEkk1Ynd Z9Rse2y9ffO2mArQjum0kLWenPvUlGyx2sK3B4c9Ym75ep8Qu1UBt2XcmYfOX1kDRJnR7CYg6Y C37DgMaIH26iXfR09OIdMwWu0mdx672n9dLhcXH/O6jw6jo87I3maUL4yUr3IfE4u4+pSUl0tY J/DBv2gVLTovN95uYJE3wvT0Ae/TMNAvw8BV9cKujUTRnK1ou6LHoLg/mzNB5Ey/90TXZ3ezgu sCc=
- Wdcironportexception: Internal
Commit 69fd157a3 "time: Add padding for the timespec if required"
caused a breakage in the glibc tests as the endian.h include file was
kept in the networking headers while the __USE_MISC #ifdefs had been
removed. This resulted in namespace violations in the networking
headers.
This patche restores the __USE_MISC conditionals in endian.h to fix the
test failures.
* string/endian.h: Restore the __USE_MISC conditionals.
---
string/endian.h | 12 +++++++-----
1 file changed, 7 insertions(+), 5 deletions(-)
diff --git a/string/endian.h b/string/endian.h
index 0eb534e434b..1a9fe3c97e7 100644
--- a/string/endian.h
+++ b/string/endian.h
@@ -23,12 +23,14 @@
/* Get the definitions of __*_ENDIAN, __BYTE_ORDER, and __FLOAT_WORD_ORDER. */
#include <bits/endian.h>
-#define LITTLE_ENDIAN __LITTLE_ENDIAN
-#define BIG_ENDIAN __BIG_ENDIAN
-#define PDP_ENDIAN __PDP_ENDIAN
-#define BYTE_ORDER __BYTE_ORDER
+#ifdef __USE_MISC
+# define LITTLE_ENDIAN __LITTLE_ENDIAN
+# define BIG_ENDIAN __BIG_ENDIAN
+# define PDP_ENDIAN __PDP_ENDIAN
+# define BYTE_ORDER __BYTE_ORDER
+#endif
-#ifndef __ASSEMBLER__
+#if defined __USE_MISC && !defined __ASSEMBLER__
/* Conversion interfaces. */
# include <bits/byteswap.h>
# include <bits/uintn-identity.h>
--
2.23.0