Re: vim patch for cygwin
- Bram Moolenaar wrote:
> Hmm, I'm not getting the feeling this has been properly tested. I'llI did't run any regression test.
> await comments for a while.
The only problem on cygwin is the "E303: Unable to open swap file..."
Looking at vim under the ddd/gdb debugger I found that it
was trying to compose the name of the .swp file concatenating
a posix path with a windows one (that was the result of the
symlink exansion not recognized as an absolute path) so
I patched with cygwin_conv_to_posix_path() and recompiled.
I'm using this version now (just changed the position of the patch
as you suggested) and it works here.
> In src/main.c I found this, perhaps it's also needed in os_unix.c:It is not strictly needed because gcc compiled without having this snippet.
> #ifdef __CYGWIN__
> # ifndef WIN32
> # include <sys/cygwin.h> /* for cygwin_conv_to_posix_path() */
> # endif
> # include <limits.h>
Maybe having __CYGWIN__ defined cause the inclusion of sys/cygwin.h
in other place.
But from wath I see that can be useful if you compile from cygwin
to windows native and you want to avoid the inclusion of
cygwin_conv_to_posix_path() when WIN32 is defined.
Maybe the better solution is to avoid mixing different
kind of path instead of patching a symlink that was expanded
as a windows path when it should had be expanded as a posix path.
(my current solution).