Skip to content

Commit 665b1e8

Browse files
committed
fixup! otp_build: Refuse if current directory is not under ERL_TOP
1 parent a38e9ce commit 665b1e8

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

otp_build

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -137,11 +137,11 @@ check_erltop ()
137137
echo "The environment variable ERL_TOP must be set." >&2
138138
exit 1
139139
fi
140-
else
140+
elif [ "X$1" != "Xtests" ]
141141
real_ERL_TOP=`realpath $ERL_TOP`
142142
real_PWD=`realpath $PWD`
143143
if [ "X${real_PWD##$real_ERL_TOP*}" != "X" ]; then
144-
echo "Current working directory is not in ERL_TOP." >&2
144+
echo "ERROR: Current working directory is not in ERL_TOP." >&2
145145
echo "ERL_TOP=$ERL_TOP" >&2
146146
echo "PWD=$PWD" >&2
147147
exit 1
@@ -1360,7 +1360,7 @@ do_remove_prebuilt_files ()
13601360

13611361
# main
13621362

1363-
check_erltop
1363+
check_erltop $1
13641364

13651365
cd "$ERL_TOP"
13661366

0 commit comments

Comments
 (0)