blob: 061e81a8138d71686e1cf0b822db9fc65b96d9db (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
|
#!/bin/sh
set -eu
# this is needed mostly because $DESTDIR is provided as a variable,
# and we need to create the target directory...
mkdir -vp "$(dirname "${DESTDIR:-}$2")"
if [ "$(dirname $1)" = . ]; then
ln -fs -T "$1" "${DESTDIR:-}$2"
else
ln -fs -T --relative "${DESTDIR:-}$1" "${DESTDIR:-}$2"
fi
|