summaryrefslogtreecommitdiff
path: root/tools/meson-make-symlink.sh
diff options
context:
space:
mode:
authorDaan De Meyer <daan.j.demeyer@gmail.com>2020-12-06 18:16:59 +0000
committerDaan De Meyer <daan.j.demeyer@gmail.com>2020-12-06 22:11:11 +0000
commit09422f9a28481eb5c49d375a6b5b7ca2b773c1ae (patch)
treed615cf5a0d0249ee4dfad1f1d18a52e55966c52a /tools/meson-make-symlink.sh
parent5e577e1737a4fd603067536b3b21d32f7d180fee (diff)
downloadsystemd-09422f9a28481eb5c49d375a6b5b7ca2b773c1ae.tar.gz
meson: Respect MESON_INSTALL_QUIET
MESON_INSTALL_QUIET is set when --quiet is passed to meson install. Make sure we check the variable in our custom install scripts and don't output anything if it is set.
Diffstat (limited to 'tools/meson-make-symlink.sh')
-rwxr-xr-xtools/meson-make-symlink.sh12
1 files changed, 9 insertions, 3 deletions
diff --git a/tools/meson-make-symlink.sh b/tools/meson-make-symlink.sh
index cdd5214125..8c7e887f51 100755
--- a/tools/meson-make-symlink.sh
+++ b/tools/meson-make-symlink.sh
@@ -1,12 +1,18 @@
#!/bin/sh
set -eu
+if [ "${MESON_INSTALL_QUIET:-0}" = 1 ] ; then
+ VERBOSE=""
+else
+ VERBOSE="v"
+fi
+
# this is needed mostly because $DESTDIR is provided as a variable,
# and we need to create the target directory...
-mkdir -vp "$(dirname "${DESTDIR:-}$2")"
+mkdir -${VERBOSE}p "$(dirname "${DESTDIR:-}$2")"
if [ "$(dirname $1)" = . -o "$(dirname $1)" = .. ]; then
- ln -vfs -T -- "$1" "${DESTDIR:-}$2"
+ ln -${VERBOSE}fs -T -- "$1" "${DESTDIR:-}$2"
else
- ln -vfs -T --relative -- "${DESTDIR:-}$1" "${DESTDIR:-}$2"
+ ln -${VERBOSE}fs -T --relative -- "${DESTDIR:-}$1" "${DESTDIR:-}$2"
fi