9

Each time when I build my R markdown (Knit the current) document to have LaTeX and PDF files, I see in RStudio a warning message:

Your latexmk version seems to be too low. You may need to update the latexmk package or your LaTeX distribution.

Page https://www.ctan.org/pkg/latexmk says that current version of latexmk is 4.52c

However when I type

sudo apt-get update && sudo apt-get upgrade
sudo apt-get install --only-upgrade latexmk

I see on my screen:

latexmk is already the newest version (1:4.41-1).

which is consistent with information which I get when I type:

latexmk --version

Latexmk, John Collins, 1 January 2015. Version 4.4

I wonder if it is possible to (and if I should) upgrade latexmk on my Ubuntu 16.04.1 LTS or should I just ignore this warning? Is there any different PPA for latexmk / RStudio dependencies?

8

I am extensively using the provided latexmk in my 16.04 system without any problem --- but I do not use R, so your case may be different.

The new version has new capabilities (like direct selection of lualatex and xelatex engines), so the reason for not upgrading it may be one (or both) of:

  • that the package's maintainer thinks it's too risky for a LTS release (but then it should be available a version for the update in newer Ubuntu, and it seems it is not the case)

  • Or simply the upgrades were not noticed by the maintainer, or they're too busy, or not interested anymore.

If you look at the files contents of the latexmk package, you'll find that practically it's just a script and documentation:

[romano:~] % wajig listfiles latexmk
/.
/usr
/usr/bin
/usr/bin/latexmk
/usr/share
/usr/share/man
/usr/share/man/man1
/usr/share/man/man1/latexmk.1L.gz
/usr/share/doc
/usr/share/doc/latexmk
/usr/share/doc/latexmk/latexmk.txt.gz
/usr/share/doc/latexmk/latexmk.ps.gz
/usr/share/doc/latexmk/copyright
/usr/share/doc/latexmk/latexmk.pdf.gz
/usr/share/doc/latexmk/README.gz
/usr/share/doc/latexmk/changelog.Debian.gz
/etc
/etc/LatexMk

(and the global configuration file).

So in case of a need of an upgrade, I would probably download the source package from its home, and then install locally in my user. The installiation instructions are really well done, but basically it boils down to

cp latexmk.pl $HOME/bin/latexmk 
chmod +x $HOME/bin/latexmk 

and now the new latexmk is overriding the old one. If you want to install it system-wide, the instructions are, again, quite complete.

  • Thank you for this detailed answer! However, I think it's rather a workaround for someone who needs to install latest version. I wish to know what was the reason to not include latest latexmk in the repo (maybe it is not stable / have bugs?) – matandked Feb 16 '17 at 9:11
  • Answer updated. – Rmano Feb 16 '17 at 9:23

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.