From cd6a992089d8ff49653e5375c7bfc9cdd3bf5e59 Mon Sep 17 00:00:00 2001 From: Stefan Schantl Date: Mon, 26 Dec 2011 17:01:09 +0100 Subject: [PATCH] Check if build arch is supported by host. --- python/pakfire/builder.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/python/pakfire/builder.py b/python/pakfire/builder.py index 9b33694b..c089a60e 100644 --- a/python/pakfire/builder.py +++ b/python/pakfire/builder.py @@ -121,6 +121,10 @@ class BuildEnviron(object): self.distro = self.pakfire.distro self.path = self.pakfire.path + # Check if this host can build the requested architecture. + if not self.arch in self.pakfire.config.supported_arches: + raise BuildError, _("Cannot build for %s on this host.") % self.arch + # Where do we put the result? self.resultdir = os.path.join(self.path, "result") -- 2.39.2