From 0ebf79ec8b74c8cbb1ea96fff740a8dfd80340b1 Mon Sep 17 00:00:00 2001 From: Nirbheek Chauhan Date: Fri, 21 Apr 2017 23:57:21 +0530 Subject: configure_file: Accept output of configure_file as input --- mesonbuild/interpreter.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/mesonbuild/interpreter.py b/mesonbuild/interpreter.py index 0eb392d3b..eaaea737a 100644 --- a/mesonbuild/interpreter.py +++ b/mesonbuild/interpreter.py @@ -2313,9 +2313,11 @@ class Interpreter(InterpreterBase): raise InterpreterException('Input must be a string or a file') if isinstance(inputfile, str): inputfile = os.path.join(self.subdir, inputfile) + ifile_abs = os.path.join(self.environment.source_dir, inputfile) else: + ifile_abs = inputfile.absolute_path(self.environment.source_dir, + self.environment.build_dir) inputfile = inputfile.relative_name() - ifile_abs = os.path.join(self.environment.source_dir, inputfile) elif 'command' in kwargs and '@INPUT@' in kwargs['command']: raise InterpreterException('@INPUT@ used as command argument, but no input file specified.') # Validate output -- cgit v1.2.3