]> git.ipfire.org Git - thirdparty/systemd.git/blame - tools/meson-make-symlink.sh
meson: Respect MESON_INSTALL_QUIET
[thirdparty/systemd.git] / tools / meson-make-symlink.sh
CommitLineData
7629744a 1#!/bin/sh
2set -eu
7b76fce1 3
09422f9a
DDM
4if [ "${MESON_INSTALL_QUIET:-0}" = 1 ] ; then
5 VERBOSE=""
6else
7 VERBOSE="v"
8fi
9
7b76fce1
ZJS
10# this is needed mostly because $DESTDIR is provided as a variable,
11# and we need to create the target directory...
12
09422f9a 13mkdir -${VERBOSE}p "$(dirname "${DESTDIR:-}$2")"
c8475239 14if [ "$(dirname $1)" = . -o "$(dirname $1)" = .. ]; then
09422f9a 15 ln -${VERBOSE}fs -T -- "$1" "${DESTDIR:-}$2"
7b76fce1 16else
09422f9a 17 ln -${VERBOSE}fs -T --relative -- "${DESTDIR:-}$1" "${DESTDIR:-}$2"
7b76fce1 18fi