[PATCH] Define _C99 in libstdc++ vxworks/os_defines.h
Olivier Hainque
hainque@adacore.com
Fri Dec 10 15:06:38 GMT 2021
Hello,
The attached patch for libstdc++ / VxWorks helps building
the library for old versions of the OS, as witnessed with
VxWorks 6.9 in particular.
It explicitly requests C99 features from old system headers,
on which libstc++ relies since at least c++98. The specific
issue that exposed this was a failure to compile
libstdc++-v3/src/c++17/floating_to_chars.cc
for VxWorks 6.9 with a batch of errors such as:
error: 'FP_NAN' was not declared in this scope
The missing definitions are provided by the
system headers with guards on _HAS_C9X, which gets
internally defined when _C99 is.
Ok to commit?
Thanks in advance!
2021-12-07 Olivier Hainque <hainque@adacore.com>
libstdc++-v3/
* config/os/vxworks/os_defines.h: #define _C99.
Olivier
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-Define-_C99-in-libstdc-vxworks-os_defines.h.patch
Type: application/octet-stream
Size: 1346 bytes
Desc: not available
URL: <https://gcc.gnu.org/pipermail/libstdc++/attachments/20211210/5f0ef2e7/attachment-0001.obj>
More information about the Libstdc++
mailing list