From: Georg Baum Date: Tue, 10 May 2016 05:18:48 +0000 (+0200) Subject: Ensure that TeXFiles.py is run by python2 X-Git-Tag: 2.2.0~41 X-Git-Url: https://git.lyx.org/gitweb/?a=commitdiff_plain;h=a1cc93654873736194891bbc18fbce441c1f1516;p=features.git Ensure that TeXFiles.py is run by python2 We ensure that configure.py is called by python2, regardless whether 'python' is python 2 or 3. Therefore we can simply call TeXFiles.py with the currently running interpreter. This fixes configuration on systems where 'python' is python 3. --- diff --git a/lib/configure.py b/lib/configure.py index 0dcc4ce105..cd2a0c5aa5 100644 --- a/lib/configure.py +++ b/lib/configure.py @@ -1522,7 +1522,10 @@ def rescanTeXFiles(): if not os.path.isfile( os.path.join(srcdir, 'scripts', 'TeXFiles.py') ): logger.error("configure: error: cannot find TeXFiles.py script") sys.exit(1) - tfp = cmdOutput("python -tt " + '"' + os.path.join(srcdir, 'scripts', 'TeXFiles.py') + '"') + interpreter = sys.executable + if interpreter == '': + interpreter = "python" + tfp = cmdOutput(interpreter + " -tt " + '"' + os.path.join(srcdir, 'scripts', 'TeXFiles.py') + '"') logger.info(tfp) logger.info("\tdone")