summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rwxr-xr-xbin/dosym7
1 files changed, 4 insertions, 3 deletions
diff --git a/bin/dosym b/bin/dosym
index 081e2acde..e0af15e2c 100755
--- a/bin/dosym
+++ b/bin/dosym
@@ -8,6 +8,7 @@ if [[ $# -ne 2 ]] ; then
exit 1
fi
-target=$1
-linkname=$2
-exec ln -snf "${target}" "${D}${linkname}"
+destdir=${2%/*}
+[[ ! -d ${D}${destdir} ]] && dodir "${destdir}"
+
+exec ln -snf "$1" "${D}$2"