1LNDIR(1)                    General Commands Manual                   LNDIR(1)
2
3
4

NAME

6       lndir  -  create a shadow directory of symbolic links to another direc‐
7       tory tree
8

SYNOPSIS

10       lndir [ -silent ] [ -ignorelinks ] [ -withrevinfo ] fromdir [ todir ]
11

DESCRIPTION

13       The lndir program makes  a  shadow  copy  todir  of  a  directory  tree
14       fromdir,  except  that  the shadow is not populated with real files but
15       instead with symbolic links pointing at the real files in  the  fromdir
16       directory tree.  This is usually useful for maintaining source code for
17       different machine architectures.  You create a  shadow  directory  con‐
18       taining  links  to the real source, which you will have usually mounted
19       from a remote machine.  You can build  in  the  shadow  tree,  and  the
20       object files will be in the shadow directory, while the source files in
21       the shadow directory are just symlinks to the real files.
22
23       This scheme has the advantage that if you update the source,  you  need
24       not  propagate the change to the other architectures by hand, since all
25       source in all shadow directories are symlinks to the real  thing:  just
26       cd to the shadow directory and recompile away.
27
28       The  todir  argument is optional and defaults to the current directory.
29       The fromdir argument may be relative (e.g., ../src) and is relative  to
30       todir (not the current directory).
31
32       Note  that  BitKeeper, RCS, SCCS, .svn, CVS and CVS.adm directories are
33       shadowed only if the -withrevinfo flag is specified.
34
35       If you add files, simply run lndir again.  New files will  be  silently
36       added.  Old files will be checked that they have the correct link.
37
38       Deleting  files is a more painful problem; the symlinks will just point
39       into never never land.
40
41       If a file in fromdir is a symbolic link, lndir will make the same  link
42       in todir rather than making a link back to the (symbolic link) entry in
43       fromdir.  The -ignorelinks flag changes this behavior.
44

OPTIONS

46       -silent
47              Normally lndir outputs the  name  of  each  subdirectory  as  it
48              descends  into  it.   The -silent option suppresses these status
49              messages.
50
51       -ignorelinks
52              Causes the program to not treat symbolic links in  fromdir  spe‐
53              cially.  The link created in todir will point back to the corre‐
54              sponding (symbolic link) file in fromdir.  If the link is  to  a
55              directory, this is almost certainly the wrong thing.
56
57              This  option exists mostly to emulate the behavior the C version
58              of lndir had in X11R6.  Its use is not recommended.
59
60       -withrevinfo
61              Causes any BitKeeper, RCS, SCCS, .svn, CVS and CVS.adm subdirec‐
62              tories  to  be  treated  as  any  other  directory,  rather than
63              ignored.
64

DIAGNOSTICS

66       The program displays the name of each subdirectory it enters,  followed
67       by a colon.  The -silent option suppresses these messages.
68
69       A  warning message is displayed if the symbolic link cannot be created.
70       The usual problem is that a regular  file  of  the  same  name  already
71       exists.
72
73       If  the  link already exists but doesn't point to the correct file, the
74       program prints the link name and the location where it does point.
75
76
77
78X Version 11                      lndir 1.0.1                         LNDIR(1)
Impressum