aboutsummaryrefslogtreecommitdiff
path: root/libstdc++-v3
diff options
context:
space:
mode:
authorOlivier Hainque <hainque@adacore.com>2020-12-23 20:24:29 -0300
committerAlexandre Oliva <oliva@gnu.org>2020-12-23 20:27:36 -0300
commiteb81c997d81033407576a2376b6ce24b0646d3a1 (patch)
tree350b06d5c6c2b95ce66ec9b6d142463a6ebd22d0 /libstdc++-v3
parent36c08a8f212114252785ee68b3586e949c3612aa (diff)
downloadgcc-eb81c997d81033407576a2376b6ce24b0646d3a1.zip
gcc-eb81c997d81033407576a2376b6ce24b0646d3a1.tar.gz
gcc-eb81c997d81033407576a2376b6ce24b0646d3a1.tar.bz2
Account for VxWorks headers in libstdc++ test on names
Undefine various macros unexpectedly defined by VxWorks headers. for libstdc++-v3/ChangeLog * testsuite/17_intro/names.cc: Account for VxWorks headers.
Diffstat (limited to 'libstdc++-v3')
-rw-r--r--libstdc++-v3/testsuite/17_intro/names.cc41
1 files changed, 41 insertions, 0 deletions
diff --git a/libstdc++-v3/testsuite/17_intro/names.cc b/libstdc++-v3/testsuite/17_intro/names.cc
index 2c8bfff..4760a9e 100644
--- a/libstdc++-v3/testsuite/17_intro/names.cc
+++ b/libstdc++-v3/testsuite/17_intro/names.cc
@@ -211,4 +211,45 @@
#undef ptr
#endif
+#ifdef __VXWORKS__
+
+#include <_vxworks-versions.h>
+
+// Some VxWorks 6 or 7 headers are using those.
+
+// private/objLibP.h
+#undef u
+
+// arch/ppc/ffs/ArchLib.h
+#undef i
+#undef j
+
+// math.h
+#undef x
+#undef y
+
+// stdio.h
+#undef ptr
+
+// VxWorks >= 7 specificities
+
+#if _VXWORKS_MAJOR_GE(7)
+
+// regs.h regs structure has a field 'r'
+#undef r
+
+#ifndef __RTP__
+// in bootLib.h, bootParamCheck has parameters x, a-f
+#undef a
+#undef b
+#undef c
+#undef d
+#undef e
+#undef f
+#endif // __RTP__
+
+#endif // VxWorks Major >= 7
+
+#endif // __VXWORKS__
+
#include <bits/stdc++.h>