From d7304129f667d82298ec61fbd2cb474a137b1035 Mon Sep 17 00:00:00 2001 From: managan Date: Thu, 6 Aug 2009 19:01:36 +0000 Subject: [PATCH] Move the definition of env['LATEXSUFFIXES'] from Defaults.py to the various *tex.py generate functions. This is to avoid adding LATEXSUFFIXES to the environment when the tools are not loaded. git-svn-id: http://scons.tigris.org/svn/scons/trunk@4323 fdb21ef1-2011-0410-befe-b5e4ea1792b1 --- src/engine/SCons/Defaults.py | 2 +- src/engine/SCons/Tool/latex.py | 2 ++ src/engine/SCons/Tool/pdflatex.py | 2 ++ src/engine/SCons/Tool/pdftex.py | 2 ++ src/engine/SCons/Tool/tex.py | 2 ++ 5 files changed, 9 insertions(+), 1 deletion(-) diff --git a/src/engine/SCons/Defaults.py b/src/engine/SCons/Defaults.py index eba86e4a..7ce981dd 100644 --- a/src/engine/SCons/Defaults.py +++ b/src/engine/SCons/Defaults.py @@ -463,7 +463,7 @@ ConstructionEnvironment = { 'DSUFFIXES' : SCons.Tool.DSuffixes, 'ENV' : {}, 'IDLSUFFIXES' : SCons.Tool.IDLSuffixes, - 'LATEXSUFFIXES' : SCons.Tool.LaTeXSuffixes, +# 'LATEXSUFFIXES' : SCons.Tool.LaTeXSuffixes, # moved to the TeX tools generate functions '_concat' : _concat, '_defines' : _defines, '_stripixes' : _stripixes, diff --git a/src/engine/SCons/Tool/latex.py b/src/engine/SCons/Tool/latex.py index 36c4fd26..8712d743 100644 --- a/src/engine/SCons/Tool/latex.py +++ b/src/engine/SCons/Tool/latex.py @@ -57,6 +57,8 @@ def generate(env): if LaTeXAction is None: LaTeXAction = SCons.Action.Action('$LATEXCOM', '$LATEXCOMSTR') + env.AppendUnique(LATEXSUFFIXES=SCons.Tool.LaTeXSuffixes) + import dvi dvi.generate(env) diff --git a/src/engine/SCons/Tool/pdflatex.py b/src/engine/SCons/Tool/pdflatex.py index 81bdcd52..c4a8264c 100644 --- a/src/engine/SCons/Tool/pdflatex.py +++ b/src/engine/SCons/Tool/pdflatex.py @@ -59,6 +59,8 @@ def generate(env): PDFLaTeXAuxAction = SCons.Action.Action(PDFLaTeXAuxFunction, strfunction=SCons.Tool.tex.TeXLaTeXStrFunction) + env.AppendUnique(LATEXSUFFIXES=SCons.Tool.LaTeXSuffixes) + import pdf pdf.generate(env) diff --git a/src/engine/SCons/Tool/pdftex.py b/src/engine/SCons/Tool/pdftex.py index fc09bf46..b487a8d0 100644 --- a/src/engine/SCons/Tool/pdftex.py +++ b/src/engine/SCons/Tool/pdftex.py @@ -78,6 +78,8 @@ def generate(env): PDFTeXLaTeXAction = SCons.Action.Action(PDFTeXLaTeXFunction, strfunction=SCons.Tool.tex.TeXLaTeXStrFunction) + env.AppendUnique(LATEXSUFFIXES=SCons.Tool.LaTeXSuffixes) + import pdf pdf.generate(env) diff --git a/src/engine/SCons/Tool/tex.py b/src/engine/SCons/Tool/tex.py index 2fc13d14..26232db6 100644 --- a/src/engine/SCons/Tool/tex.py +++ b/src/engine/SCons/Tool/tex.py @@ -621,6 +621,8 @@ def generate(env): TeXLaTeXAction = SCons.Action.Action(TeXLaTeXFunction, strfunction=TeXLaTeXStrFunction) + env.AppendUnique(LATEXSUFFIXES=SCons.Tool.LaTeXSuffixes) + import dvi dvi.generate(env) -- 2.26.2