diff options
author | Robert Managan <managan1@llnl.gov> | 2009-07-22 21:24:37 (GMT) |
---|---|---|
committer | Robert Managan <managan1@llnl.gov> | 2009-07-22 21:24:37 (GMT) |
commit | 10dc447016536d663d6031edc04e09cc50948130 (patch) | |
tree | 0ac94ad77530a505f7409625aa74691f4be2f2e2 | |
parent | 61d520c5b92f29d2d20441ced3abed52c5be211d (diff) | |
download | SCons-10dc447016536d663d6031edc04e09cc50948130.zip SCons-10dc447016536d663d6031edc04e09cc50948130.tar.gz SCons-10dc447016536d663d6031edc04e09cc50948130.tar.bz2 |
Turns out that in my revamped TeX builder I was listing the .dvi or
.pdf output file as a sideeffect since it is listed as an output
file in the .fls file. This caused the message that there were two ways to
build the file.
In fixing it I have to exclude both the .dvi and .pdf target because some
test decks produce both... THat hsoudl rarely happen in practice but
It is better to handle that case.
-rw-r--r-- | src/engine/SCons/Tool/tex.py | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/engine/SCons/Tool/tex.py b/src/engine/SCons/Tool/tex.py index e1ecd81..2fc13d1 100644 --- a/src/engine/SCons/Tool/tex.py +++ b/src/engine/SCons/Tool/tex.py @@ -481,7 +481,7 @@ def tex_emitter_core(target, source, env, graphics_extensions): targetdir = os.path.split(str(target[0]))[0] abspath = os.path.abspath(basedir) target[0].attributes.path = abspath - + # # file names we will make use of in searching the sources and log file # @@ -566,13 +566,13 @@ def tex_emitter_core(target, source, env, graphics_extensions): env.Clean(target[0],targetbase + suffix) # read fls file to get all other files that latex creates and will read on the next pass + # remove files from list that we explicitly dealt with above if os.path.exists(flsfilename): content = open(flsfilename, "rb").read() out_files = openout_re.findall(content) - mysuffixes = ['.log' , '.fls' , targetext] - for filename in out_files: - base,ext = SCons.Util.splitext(filename) - if ext in mysuffixes: + myfiles = [auxfilename, logfilename, flsfilename, targetbase+'.dvi',targetbase+'.pdf'] + for filename in out_files[:]: + if filename in myfiles: out_files.remove(filename) env.SideEffect(out_files,target[0]) env.Clean(target[0],out_files) |