I am using tikz' externalize library on windows. Since my document contains graphics with \ref, I need to use list and make instead of convert with system call.
Since I am working on windows, I cannot use make main.makefile, as was also reported in this question.
Issuing the correct system calls is not a problem. However, I do not know how to find out which figures need to be updated since main.figlist seems to always list all figures. externalize obviously checks for whether a figure needs to be updated before issuing the system call, and I believe something like this is included in the makefile as well.
Unfortunately I do not know how makefiles work.
Is there a way to issue this check manually, or can I get a list of outdated figures?
The generated makefiles look as follows:
ALL_FIGURE_NAMES=$(shell cat thesis.figlist)
ALL_FIGURES=$(ALL_FIGURE_NAMES:%=%.pdf)
allimages: $(ALL_FIGURES)
@echo All images exist now. Use make -B to re-generate them.
FORCEREMAKE:
include $(ALL_FIGURE_NAMES:%=%.dep)
%.dep:
mkdir -p "$(dir $@)"
touch "$@" # will be filled later.
fig-0.pdf:
pdflatex -enable-write18 -halt-on-error -interaction=batchmode -jobname "fig-0" "\def\tikzexternalrealjob{main}\input{main}"
fig-0.pdf: fig-0.md5
Edit: tikz-externalize does collect the information on whether a figure is up-to-date or not. This is obvious because after a full run, it can issue a warning if there are figures that are not up-to-date. Furthermore, if externalize is set to convert with system call, only those figures are updated, that were outdated. So tikz has to have a way to invoke something like an md5 check.
So instead of creating a list of outdated figures, is there maybe a way to invoke this up-to-date-check using a manual pdflatex command? Naivly put, something like pdflatex -jobname=figure0 --check-md5?
I am perfectly happy to start updating figures manually, but creating all figures everytime I change one is - to put it mildy - time consuming... There has to be a solution that is working on windows as well, I suppose?
I had a look into the tikz-externalize files, but my tex is not good enough for this...
Edit 2: I realize I did not make my problem clear enough, or maybe the motivation for my question.
My document includes several tikz pictures, many of those are very time consuming to create. I have tikzexternalize configured to consecutively number all figures in my document. Thus, I can manually invoke pdflatex -jobname=figure0 ..., and somehow pdflatex finds the right tikz code, although the tikzfiles are not named figure0.tikz and so on. I really can't do the manual md5 check unless I either find out where the externalize magic happens. This leaves me with the following choices:
- understand the magic (propably not going to happen anytime soon)
- find a way to invoke the tikze-md5check before typesetting
- find a way to get a list of outdated figures
makeonly makes things which need remaking. It doesn't matter that they are listed. Unless you force a remake,makewill check if they need remaking before doing so. Have you tried to see if it does the right thing? – cfr Jul 27 '16 at 02:55makeworks. You can force it to remake things which don't look as if they need to be remade, but to do that you have to override the default. – cfr Jul 27 '16 at 10:16makedoes and just look at the modification times for the files? If the.md5is newer than the.pdf, then the image needs remaking. Otherwise not. – cfr Jul 28 '16 at 18:10The MD5 is compared against the MD5 of the previous run, which, in turn, will be written into an extra file with the extension .md5. This file will be modified if and only if the MD5 comparison indicates a difference.Otherwisemakewould remake all the figures after a recompilation, too. – cfr Jul 28 '16 at 18:18.md5as the trigger for the.pdf. – cfr Jul 28 '16 at 18:19md5files in directories of projects I recompiled over weeks or months. E.g. for one project, I have one for 4th Feb and the rest for 17th Feb. But I last recompiled on this machine on 24th Feb. (And it is very unlikely I commented out the images involved in this project as some are used repeatedly throughout.) – cfr Jul 28 '16 at 18:27makeworked this way or what theMakefilemeant. – cfr Jul 28 '16 at 19:59make? The support forwin32appears to be actively maintained (a commit pertaining to this platform occurred 5 weeks ago). The current version is 4.2.1. I know nothing about installing this kind of thing on Windows, although I'm aware that MS does not provide users with development tools. (Because that would be far too empowering? Because the tools suck? Because they make more money this way?) But often projects make binaries available for Windows for precisely this reason, even if they provide none for other platforms. If not, surely somebody must provide them? – cfr Jul 29 '16 at 03:38README.W32which explains what you need and where you can obtain it. [I don't know how much this stuff matters to you, so this may just be more hassle than running the commands manually. But, if not, it seems that you do have some reasonable options to install GNU'smake.] – cfr Jul 29 '16 at 03:55makeis not that terrible. – cfr Jul 30 '16 at 13:10