From c24573483d9ba5ded394578d20bc805f2759c2c4 Mon Sep 17 00:00:00 2001 From: Thibault Saunier Date: Sat, 19 Sep 2015 16:24:33 +0200 Subject: Do not use intr before it exists --- meson.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/meson.py b/meson.py index da7b12f..1e80b9f 100755 --- a/meson.py +++ b/meson.py @@ -144,9 +144,6 @@ itself as required.''' else: mlog.log('Build type:', mlog.bold('native build')) b = build.Build(env) - if env.is_cross_build(): - mlog.log('Host machine cpu:', mlog.bold(intr.builtin['host_machine'].cpu_method([], {}))) - mlog.log('Target machine cpu:', mlog.bold(intr.builtin['target_machine'].cpu_method([], {}))) if self.options.backend == 'ninja': import ninjabackend g = ninjabackend.NinjaBackend(b) @@ -158,7 +155,11 @@ itself as required.''' g = xcodebackend.XCodeBackend(b) else: raise RuntimeError('Unknown backend "%s".' % self.options.backend) + intr = interpreter.Interpreter(b, g) + if env.is_cross_build(): + mlog.log('Host machine cpu:', mlog.bold(intr.builtin['host_machine'].cpu_method([], {}))) + mlog.log('Target machine cpu:', mlog.bold(intr.builtin['target_machine'].cpu_method([], {}))) mlog.log('Build machine cpu:', mlog.bold(intr.builtin['build_machine'].cpu_method([], {}))) intr.run() g.generate(intr) -- cgit v1.1