large link to /usr/bin/X11

J dreadpiratejeff at gmail.com
Tue Mar 16 19:19:23 UTC 2010


On Tue, Mar 16, 2010 at 14:38, MirJafar Ali <mirjafarali at gmail.com> wrote:
> Hello,
>
> I had downloaded 32 bit Ubuntu 9.10 and noticed that it has very long empty
> link to /usr/bin/X11. Please
> see the following command to understand what I mean.
>
> crash-06:/usr/bin/X11/X11/X11/X11$
>
> I can go forever cd X11 and it will have another X11 directory and when I
> give
>

>
> Can someone tell what is happening ?

It's not a real long link... it's a recursive symlink...

> crash-06:/usr/bin/X11/X11/X11/X11$ ls -al X11
> lrwxrwxrwx 1 root root 1 2010-03-10 11:39 X11 -> .

Notice, the symlink X11 points to . which is the current working
directory...  I think the ability to continuously cd into X11 and
having it tack on an additional X11 to $PWD is just an effect of doing
this in BASH (not sure if the same behaviour would be seen in other
shells).

Either way, every time you cd into X11 you are cd-ing into the current
directory...

My best guess (and I actually got this from someone I work with) was
that this was done to allow users (and other programs) to call X apps
by using /usr/bin/X11/Xfoo for legacy purposes...

At one point in the past, there actually WAS an X11 directory that had
all the GUI apps, while the others went into /usr/bin.

I have a feeling this is more a legacy throwback to when X was
XFree86, prior to the move to Xorg.

Cheers,

Jeff




More information about the ubuntu-users mailing list