Christian wrote:
> On Di, 26 Nov 2019, Bram Moolenaar wrote: > > > Patch 8.1.2344 > > Problem: Cygwin: warning for using strptime(). > > Solution: Move defining _XOPEN_SOURCE and __USE_XOPEN to vim.h. (Ken > > Takata, > > closes #5265) Use 700 for _XOPEN_SOURCE for mkdtemp(). > > Files: src/os_unix.h, src/vim.h > > This still breaks on BSD like systems. > > How about the following patch on top of it? > > diff --git a/src/vim.h b/src/vim.h > index 9b49ba1a9..c0053ce14 100644 > --- a/src/vim.h > +++ b/src/vim.h > @@ -36,8 +36,8 @@ > Error: configure did not run properly. Check auto/config.log. > # endif > > -# if defined(UNIX) && !defined(MACOS_X) > -// Needed for strptime(). Needs to be done early, since header files can > +# if defined(UNIX) && !defined(MACOS_X) && !defined(__unix__) Why use __unix__ ? It's not used anywhere in Vim. There is an existing check for BSD. > +// Needed for strptime() on Cygwin. Needs to be done early, since header > files can It's also needed for Linux. > // include other header files and end up including time.h, where these > symbols > // matter for Vim. > // 700 is needed for mkdtemp(). -- Don't drink and drive. You might hit a bump and spill your beer. /// Bram Moolenaar -- [email protected] -- http://www.Moolenaar.net \\\ /// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ \\\ an exciting new programming language -- http://www.Zimbu.org /// \\\ help me help AIDS victims -- http://ICCF-Holland.org /// -- -- You received this message from the "vim_dev" maillist. Do not top-post! Type your reply below the text you are replying to. For more information, visit http://www.vim.org/maillist.php --- You received this message because you are subscribed to the Google Groups "vim_dev" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/vim_dev/201911272129.xARLT106004233%40masaka.moolenaar.net.
