[Aranym-user] symlinks to inexistant target

Vincent Rivière vincent.riviere at freesbee.fr
Wed Aug 18 16:18:03 CEST 2010


Once again, I complain about symlinks on hostfs.

I was building a hostfs-only MiNT setup, and I was surprised to discover 
that standard configure scripts were failing with "cat: -: No such file 
or directory". I digged into that, so I found the culprits were cat, 
bash, TMPDIR, mkfifo, and finally... symlinks.

The test command is:
$ ln -s /bad/dir baddir
The source directory must not exist.

On normal systems, as well as MiNT on ext2 drives, the result is:
$ ls -l
... baddir -> /bad/dir
We can see that the target has been stored as is, and no one has 
complained about the fact it does not exist.

Now do the same on a hostfs drive (I use ARAnyM on Windows).
$ ls -l
... baddir -> /cygdrive/u/bad/dir

We can see two abominations:
- /u: has been added by some MiNT or ARAnyM code
- /cygdrive: has been added by Cygwin

I suspect ARAnyM to internally do something like:
ln -s 'u:\bad\dir' baddir2
because the result is exactly the same.
If it the case, it is wrong.
The symlink target should be passed unmodified to the underlying OS.
In any case, the symlink target should never be a DOS-like path.

It is really a pity because the hostfs is a great feature but such bugs 
prevents to use it to do serious stuff.

Vincent Rivière

More information about the cz-bobek-lists-aranym-user mailing list