This is the mail archive of the cygwin mailing list for the Cygwin project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

`CYGWIN=winsymlinks:nativestrict`, `ln -s target link` fails if target doesn't exist

Hello everybody!

First post on this mailing list, my name is Gene, I'm from Russia,
long-time Linux user, but had to use Windows as desktop for the last 8
years. Cygwin really helps me to keep my sanity! Thanks :)

I have an issue to report:

Introduction: On a UNIX system, `ln -s target link` creates a link
regardless of target's existence.
This is used in some scripts, e.g. Gentoo's `run-crons` (which I also
use on Cygwin) uses a symlink pointing to the running process PID as
Issue: if `CYGWIN=winsymlinks:nativestrict` env var is set, running
`ln -s target link` completely fails (even though running `mklink link
target` in `cmd.exe` succeeds, same as `ln -s` does on UNIX). If
`CYGWIN=winsymlinks:native`, a non-native link is created.

So, `nativestrict` might break some (admittedly unorthodox) scripts.
With `native` these script work, but still a native link would be
preferrable and it is possible to create, but a non-native link is
created instead.

Bottom line, I think the native symlink creation code should be
checked and a possibility should be added to create links to
non-existent targets, rather than the current behavior of failing.


Problem reports:
Unsubscribe info:

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]