1

After updating packages (on Miktex), almost nothing compiles anymore. For example:

\documentclass{article}
\usepackage{libertine}

\begin{document}
plop
\end{document}

results in the following errors:

C:\Users\TL\AppData\Roaming\MiKTeX\2.9\tex\latex\libertine\libertine.sty:10: Undefined control sequence. [\ifxetex]
C:\Users\TL\AppData\Roaming\MiKTeX\2.9\tex\latex\libertine\libertine.sty:12: Extra \else. [\else]
C:\Users\TL\AppData\Roaming\MiKTeX\2.9\tex\latex\libertine\libertine.sty:12: Undefined control sequence. [\else\ifluatex]
C:\Users\TL\AppData\Roaming\MiKTeX\2.9\tex\latex\libertine\libertine.sty:14: Extra \else. [\else]
C:\Users\TL\AppData\Roaming\MiKTeX\2.9\tex\latex\libertine\libertine.sty:16: Extra \fi. [\fi]
C:\Users\TL\AppData\Roaming\MiKTeX\2.9\tex\latex\libertine\libertine.sty:16: Extra \fi. [\fi\fi]
C:\Users\TL\AppData\Roaming\MiKTeX\2.9\tex\latex\libertine\libertine.sty:289: Undefined control sequence. [  \defaultfontfeatures]
C:\Users\TL\AppData\Roaming\MiKTeX\2.9\tex\latex\libertine\libertine.sty:290: LaTeX Error: Missing \begin{document}. [     L]
C:\Users\TL\AppData\Roaming\MiKTeX\2.9\tex\latex\libertine\libertine.sty:296: Undefined control sequence. [    \setmainfont]

However, the package iftex is installed, and there is no ifxetex package to download. Seems like ifptex provides \ifXeTeX, not ifxetex (seriously !?!...). Similar problems arise for \ifluatex.

How to fix this ?

Synxis
  • 111
  • Welcome to TeX.SX! The iftex package was updated a few months (weeks?) ago, and now both ifxetex and ifluatex (and a couple others) just load iftex. I'd guess that you updated the ifxetex package but not iftex. Check that, and also “make sure you update in both user and admin modes” – Phelype Oleinik Dec 05 '19 at 00:02
  • WTF... it works now, that discrepency between user and admin modes is pretty bad (usually I do everything as admin, I had no idea some packages were installed as user and thus not updated). Thank you anyway ! – Synxis Dec 05 '19 at 00:12
  • You're welcome! I don't have MiKTeX (and avoid Windows), so I don't really know the whys and hows, but “update in user and admin mode” seems to solve several MiKTeX problems :-) – Phelype Oleinik Dec 05 '19 at 00:14
  • 4
    I'm voting to close this question as off-topic because it was solved by updating (both in user and admin mode) – Phelype Oleinik Dec 05 '19 at 00:16
  • Agree, it is just sad this very important information is so hard to get (as is it really non-intuitive...) – Synxis Dec 05 '19 at 00:37
  • I have the same problem, but this solution didn't work for me (I installed for all users). My solution consisted in making a copy of the iftex directory in LocalTeXMF/tex/latex (the distribution installs it in tex/generic). – Bernard Dec 05 '19 at 00:42
  • @Synxis This answer seems to explains why this user/admin problem arises, and this one suggests installing with user rights only (if I got it right). – Phelype Oleinik Dec 05 '19 at 00:44
  • @PhelypeOleinik While it's true, you don't get to these answers by searching for errors similar to what is in my question... – Synxis Dec 05 '19 at 10:41

0 Answers0