## LaTeX forum ⇒ XeTeX ⇒ Compilation problem with XeteX on one machine, not 2 others Topic is solved

Information and discussion about XeTeX, an alternative for pdfTeX based on e-Tex
efroselli
Posts: 24
Joined: Wed Feb 20, 2013 1:24 pm

### Compilation problem with XeteX on one machine, not 2 others

Hello,

I have another mystery at my firm since trying to move to using XeTeX rather than the standard PDFLaTeX with Lyx.

The reason I need XeTeX is that my firm wants to use the Calibri Opentype font in its technical documentation.

I have modified the custom class used to generate our document set to include the following packages:

\RequirePackage{ifthen}\RequirePackage{graphicx}\RequirePackage{fancyhdr}\RequirePackage{setspace}\RequirePackage{grffile}

Each of the documents to be compiled also has the following code in its individual preamble:

\usepackage[T1]{fontenc}\usepackage{xcolor}\usepackage{graphics}\usepackage[cm-default]{fontspec}\usepackage[no-sscript]{xltxtra}\usepackage{xunicode} \setmainfont[Mapping=tex-text]{Calibri}\setsansfont{Calibri}  % Make nomeclature items bold and sans-serif\def\nomlabel#1{\textsf{\textbf{#1}}\hfil} %Relase settings here. Do not remove this comment

The Lyx installation, which was quite up to date on my machine, was updated on a second test machine. On both my own and the test machine, we were able to generate pdf4s without any trouble with the XeTeX compiler. The generated documents use the new fonts.

But on a third machine, which is the one that serves our documentation and manages the versioning, we cannot generate the files. This is using exactly the same lyx sources, class and layout files with the same updates as we used on machine 2. Moreover, we have checked that the Calibri font is installed as on the other machines.

These are the errors we get:
Undefined control sequence.LaTeX Error: Missing \begin{document}.Undefined control sequence.Undefined control sequence.Missing number, treated as zero.Undefined control sequence.Undefined control sequence.Undefined control sequence.Missing number, treated as zero.Missing number, treated as zero.

In the Description section, it says:

\setmainfont[Mapping=tex-text]Calibri}The control sequence at the end of the top lineof your error message was never \def'ed. If you have misspelled it (e.g., '\hobx'), type 'I' and the correct spelling (e.g., 'I\hobx'). Otherwise just continue,and I'll forget about whatever was undefined.

Since the files all generate correctly on two machines but not on a third, we surmise that the problem is not in the files but in some sort of unmet external dependency. The two machines that work are using Windows 7 and the one that does not work is using Windows Server 2008.

Any help would be greatly appreciated. Many thanks,

EFR

Tags:

efroselli
Posts: 24
Joined: Wed Feb 20, 2013 1:24 pm
We were finally able to get the third machine to compile after removing and reinstalling the entire Lyx/MiKTeX installation twice.

We were tangentially helped by a mention in the thread " XeLaTeX won't compile after upgrading to MiKTeX 2.9" in this forum.

Cheers all,
EFR