[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: OpenVMS todo list:
Re: OpenVMS todo list:
Fri, 07 Jul 2017 10:08:31 +0200
KMail/5.1.3 (Linux/4.4.0-83-generic; KDE/5.18.0; x86_64; ; )
John E. Malmberg wrote:
> >> * lib/passfd.c
> >> This needs "_X_OPEN_SOURCE_EXTENDED" for the XPG4 V2 features
> >> in the code to compile on OpenVMS. Specifically the "msg_control"
> >> and "msg_controllen" members of struct msghdr.
> >> This would need to be defined before any system header files are
> >> included.
> > This too is best done in the 'extensions' module.
> >> For the OpenVMS header files, enabling _X_OPEN_SOURCE_EXTENDED
> >> causes macros and symbols not defined by the applicable
> >> standard to be hidden from the compiler. There currently
> >> is no way to make them visible and have XPG4 V2 features enabled.
> > ?? I don't understand the last sentence. What features get disabled
> > when you define _X_OPEN_SOURCE_EXTENDED?
> Anything that is not specified in XPG4 V2. XPG4 V2 compliance requires
> that several extensions be disabled by default.
> XPG4 V2 compliance allows extensions to be enabled. The OpenVMS
> supplied header files do not provide a way to enable these extensions
> when XPG4 V2 is requested, which is an odd omission.
> All BSD extensions are disabled.
> struct tm no longer has: tm_gmtoff tm_zone
> The u_char, u_short, u_long typedefs are gone from types.h
> /* And also makes these STDIO macros not defined */
> #define _IOREAD 0x01
> #define _IOWRT 0x02
> #define _IOMYBUF 0x08
> #define _IOSTRG 0x40
> #define _IORW 0x80
> The bcmp,bcopy,bzero,ffs, strcasecmp, strncasecmp, index, and rindex are
> only in <strings.h> not <string.h> and gnulib is not including string.h.
> The setenv, unsetenv, strtoll prototypes are gone.
> It exposes a bug in the OpenVMS if.h header file is missing an include
> of <times.h> because that is now the only place "timeval" is supplied.
> It exposes a bug where the OpenVMS iconv header file is not testing the
> _XOPEN_SOURCE macro properly.
> And I am not sure that I have a complete list of what is disabled. It
> just got too painful trying to get the other gnulib modules to build in
> strict XPG4 V2 mode.
Thanks for the write-up of these collisions. In this case, you can not
define _X_OPEN_SOURCE_EXTENDED in config.h. So, define it for a single
compilation unit only. If necessary, you can even create a new .c file
just for OpenVMS (like we have stat-w32.c which is only for native Windows).
> > In this case, you need to arrange for REPLACE_STRTOUMAX to be 1.
> > But please limit these changes to OpenVMS, because it makes debugging
> > with gdb simpler when the 'rpl_' prefix is omitted when possible.
> The reverse is the case with VMS because the compiler adds prefixes to
> all C library known built-in routines/symbols.
You are thinking about the effect of your changes to OpenVMS. What I meant
is to think also at the effect of your changes to the other platforms.
Please make sure that your changes don't cause some REPLACE_* variables
to become 1 when they were 0 before your changes.
> >> * The configure test for the real directory for OpenVMS system
> >> supplied header file fails because they are not in a real directory.
> >> They are in a library file. If OpenVMS does not find a header
> >> file in supplied paths header files or in the source, it junks
> >> the directory portion the the header file path, and just looks
> >> up the filename in the text library.
> >> I export some symbols to cause Configure on VMS to skip the test.
> >> export gl_cv_next_errno_h="<vms_fake_path/errno.h>"
> > You need to find a way to make the
> > #include "/usr/include/foo.h"
> > or
> > #include_next "foo.h"
> > idiom to work, one way or the other. Gnulib relies heavily on it.
> The #include "vms_fake_path/foo.h" is the way to make sure that the
> system supplied foo.h header is used as long as "vms_fake_path" does not