Commit ad46156c authored by Timo Teräs's avatar Timo Teräs

abuild: use $builddir in default_prepare only if it exists

parent 2c1aaa55
......@@ -587,10 +587,11 @@ have_patches() {
default_prepare() {
local i
cd "$builddir" || { error "Is \$builddir set correctly?"; return 1; }
[ -n "$builddir" -a -d "$builddir" ] && cd "$builddir"
if ! have_patches; then
return 0
fi
[ -d "$builddir" ] || { error "Is \$builddir set correctly?"; return 1; }
for i in $source; do
case ${i%::*} in
*.patch)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment