From bc00f56353272ce1074c132e2a1e27fde9256fae Mon Sep 17 00:00:00 2001 From: Michael Olbrich Date: Fri, 14 Jul 2017 14:27:13 +0200 Subject: ptxdist: handle symlinks correctly when comparing PTXDIST_TOPDIR and PTXDIST_WORKSPACE PTXDIST_TOPDIR is set to based on the path to ptxdist with all symlinks resolved. PTXDIST_WORKSPACE is set to the current working directory. If this path contains symlinks then comparing the strings does not work as expected. Use '-ef' instead to check if both paths point to the same directory. Signed-off-by: Michael Olbrich --- bin/ptxdist | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'bin') diff --git a/bin/ptxdist b/bin/ptxdist index 85c5a0197..6e04a7b96 100755 --- a/bin/ptxdist +++ b/bin/ptxdist @@ -1222,7 +1222,7 @@ create_docs() { builder="${1}" outdir=${PTXDIST_WORKSPACE}/Documentation - if [ "${PTXDIST_TOPDIR}" = "${PTXDIST_WORKSPACE}" ]; then + if [ "${PTXDIST_TOPDIR}" -ef "${PTXDIST_WORKSPACE}" ]; then srcdir="${PTXDIST_TEMPDIR}/docs" else srcdir="${STATEDIR}/docs" -- cgit v1.2.3