4 ?RCS: Copyright (c) 2000, Jarkko Hietaniemi
7 ?X: This unit tries to create a symlink tree on a -Dmksymlinks request
10 ?MAKE:Mksymlinks: lns issymlink src
11 ?MAKE: -pick add $@ %<
13 ?LINT:extern mksymlinks
18 ''|'.') echo "Cannot create symlinks in the original directory." >&4
21 *) case "$lns:$issymlink" in
22 *"ln"*" -s:"*"test -"?)
23 echo "Creating the symbolic links..." >&4
25 awk '{print $1}' $src/MANIFEST | sed -e 's:/\([^/]*\)$: \1:' |
35 print "# dir = ", dir, "file = ", file
36 mf[dir] = mf[dir]" "source"/"dir"/"file;
39 if (d != ".") { print("mkdir -p "d) }
40 print("ln -sf "mf[d]" "d);
42 }' source="$src" > UU/mksymlinks.$$
46 if test ! -d t/base; then
47 echo "Failed to create the subdirectories. Aborting." >&4
51 if test ! -f t/base/lex.t; then
52 echo "Failed to create the symlinks (t/base/lex.t missing). Aborting." >&4
55 if test ! -f win32/win32.c; then
56 echo "Failed to create the symlinks (win32/win32.c missing). Aborting." >&4
61 *) echo "(I cannot figure out how to do symbolic links, ignoring mksymlinks)." >&4