On 7/7/2017 2:43 AM, Bruno Haible wrote:
John E. Malmberg wrote:I found out what the issue is. The OpenVMS stdio.h file makes the unlocked IO routines only available as macros. There is no declaration.Configure detects the macros, and that there is no declaration of them. The unlocked-io.h since the HAVE_DECL_FPUTS_UNLOCKED is not defined, redefines the "fputc_unlocked" to not work. So unlocked-io.h would need to be modified to not replace the OpenVMS stdio.h macros if they exist.OK, can you provide a patch to m4/unlocked-io.m4 and/or lib/unlocked-io.h?
Here is a patch that modifies m4/extensions to enable the unlocked functions on OpenVMS.
I then modified lib/argp-namefrob.h and lib/unlocked-io.h to not replace the OpenVMS macros.
I assume that there is a reason that lib/arg-namefrob.h is not just including lib/unlocked-io.h.
I was not sure if mentioning that the unlocked functions currently are not available for OpenVMS C++ programs due to an issue with the current C++ compiler in the posix-functions documentation.
Regards, -John
0001-stdio-OpenVMS-port-of-putc_unlocked.patch.gz
Description: GNU Zip compressed data