From 36c79b100e7e1f7e98bbf0763a950db4a8b52445 Mon Sep 17 00:00:00 2001 From: "roberto@quantal64" Date: Thu, 9 Aug 2012 15:00:19 +0200 Subject: [PATCH] =?UTF-8?q?improved=20build=20system=20reporting=20(by=20?= =?UTF-8?q?=C5=81ukasz=20Mierzwa)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- uwsgiconfig.py | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/uwsgiconfig.py b/uwsgiconfig.py index 0c1535e9..7200c0eb 100644 --- a/uwsgiconfig.py +++ b/uwsgiconfig.py @@ -218,6 +218,10 @@ def build_uwsgi(uc, print_only=False): path = 'plugins/%s' % p path = path.rstrip('/') + if not os.path.isdir(path): + print("Error: plugin '%s' not found" % p) + sys.exit(1) + sys.path.insert(0, path) import uwsgiplugin as up reload(up) @@ -995,6 +999,10 @@ class uConf(object): def build_plugin(path, uc, cflags, ldflags, libs, name = None): path = path.rstrip('/') + if not os.path.isdir(path): + print("Error: unable to find directory '%s'" % path) + sys.exit(1) + sys.path.insert(0, path) import uwsgiplugin as up reload(up)