diff mbox series

Fix testsuite/g++.old-deja/g++.mike/p658.C build failure on VxWorks RTP

Message ID orzh25frb2.fsf@lxoliva.fsfla.org
State New
Headers show
Series Fix testsuite/g++.old-deja/g++.mike/p658.C build failure on VxWorks RTP | expand

Commit Message

Alexandre Oliva Dec. 22, 2020, 9:45 p.m. UTC
The conflicting definition of OK is present in VxWorks RTP headers too.

Regstrapped on x86_64-linux-gnu, and tested with -x-arm-wrs-vxworks7r2.
Ok to install?


from Jerome Lambourg <lambourg@adacore.com>
for  gcc/testsuite/ChangeLog

        * g++.old-deja/g++.mike/p658.C: Also undefine OK on VxWorks RTP.
---
 gcc/testsuite/g++.old-deja/g++.mike/p658.C |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

Comments

Mike Stump Dec. 29, 2020, 6:48 p.m. UTC | #1
On Dec 22, 2020, at 1:45 PM, Alexandre Oliva <oliva@adacore.com> wrote:
> 
> The conflicting definition of OK is present in VxWorks RTP headers too.
> 
> Regstrapped on x86_64-linux-gnu, and tested with -x-arm-wrs-vxworks7r2.
> Ok to install?

Ok.

Ok to stylize all the #undef in the same way.  This is one happens to use a slightly different stye then the others as I recall.
diff mbox series

Patch

diff --git a/gcc/testsuite/g++.old-deja/g++.mike/p658.C b/gcc/testsuite/g++.old-deja/g++.mike/p658.C
index 8fc7cd51b2be3..a6268a36fd76b 100644
--- a/gcc/testsuite/g++.old-deja/g++.mike/p658.C
+++ b/gcc/testsuite/g++.old-deja/g++.mike/p658.C
@@ -12,9 +12,9 @@ 
 #define TRUE true
 #endif
 
-// The VxWorks kernel-mode headers define a macro named "OK", which is not
+// The VxWorks headers define a macro named "OK", which is not
 // ISO-compliant, but is part of the VxWorks API.
-#if defined __vxworks && !defined __RTP__
+#if defined __vxworks
 #undef OK
 #endif