From 345d556554a8c523b8b07f3dc4255d0eb2162d16 Mon Sep 17 00:00:00 2001 From: Clark Coleman <clc@zephyr-software.com> Date: Thu, 22 Jul 2021 11:15:25 -0400 Subject: [PATCH] Fix for clean when keystone/build dir has not been created yet. --- irdb-libs/SConscript | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/irdb-libs/SConscript b/irdb-libs/SConscript index 9d185d7d5..39a92d481 100644 --- a/irdb-libs/SConscript +++ b/irdb-libs/SConscript @@ -12,8 +12,9 @@ if env.GetOption('clean'): os.chdir(os.environ['SECURITY_TRANSFORMS_HOME']+"/third_party/capstone") os.system("make clean") os.chdir(os.environ['SECURITY_TRANSFORMS_HOME']) - os.chdir(os.environ['SECURITY_TRANSFORMS_HOME']+"/third_party/keystone/build") - os.system("rm -rf " + os.environ['SECURITY_TRANSFORMS_HOME']+"/third_party/keystone/build") + if os.path.exists(os.environ['SECURITY_TRANSFORMS_HOME']+"/third_party/keystone/build"): + os.chdir(os.environ['SECURITY_TRANSFORMS_HOME']+"/third_party/keystone/build") + os.system("rm -rf " + os.environ['SECURITY_TRANSFORMS_HOME']+"/third_party/keystone/build") os.chdir(os.environ['SECURITY_TRANSFORMS_HOME']) -- GitLab