From 92962daab0449f6982747694c789edf546e8ca78 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Safa=20Ar=C4=B1man?= Date: Mon, 5 Aug 2019 21:58:46 +0300 Subject: [PATCH] WorkDir patch applied --- pisi/operations/build.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/pisi/operations/build.py b/pisi/operations/build.py index ad20a158..8e4ab03b 100644 --- a/pisi/operations/build.py +++ b/pisi/operations/build.py @@ -682,6 +682,10 @@ class Builder: src_dir, ext = os.path.splitext(src_dir) if not ext: break + if not os.path.exists(src_dir): + src_dir = util.join_path(self.pkg_work_dir(), [d for d in os.walk(self.pkg_work_dir()).next()[1] if not d.startswith(".")][0]) + if self.get_state() == "unpack": + ctx.ui.debug("Using %s as WorkDir" % src_dir) return src_dir