I successfully used babylonian numerals with xelatex in Windows with Miktex, but I would like to do this now in Linux with Texlive. I installed texlive2018 portable full (but without docs and some languages). When I ran xelatex, the following error occurred:

! LaTeX Error: File `babyloniannum.sty' not found.

Then, I put the babylonian-master folder which contains the babyloniannum.sty file in .../texlive/texmf-local/tex/latex/local/ (Is this the correct location?) and after running texhash, the next error was:

! Package fontspec Error: The font "Santakku" cannot be found.

I have the folder santakku with only these files:


so, where should I put it? And how to tell xelatex to use it?

Note: I need to do without sudo password.

  • And one more question: Why don't texlive-full comes with this font? – Rodolfo FR Feb 3 '19 at 16:30
  • 3
    for the fonts your can try texmf-local/fonts/truetype/.... Perhaps you will to call the fonts by filename and not by fontname. For the pdf it depends. If is a docu, put it in texmf-local/doc/latex, if it is needed at runtime, it should be in texmf-local/tex/latex. – Ulrike Fischer Feb 3 '19 at 16:34
  • Why do you expect texlive to contain a font which is only available from an external website? – Ulrike Fischer Feb 3 '19 at 16:39
  • Now I understand: this font isn't a official one from Texlive. – Rodolfo FR Feb 4 '19 at 14:20

Put babyloniannum.sty in some place where TeX will find it, for instance in


(in this case remember to run mktexlsr as superuser). Otherwise keep it in the work directory. Fetch the Santakku font and again place it in a suitable directory under texmf-local, or in the work directory. In the example below I used the latter approach.

Then fix the most obvious glitch in the package, which is using \fontspec at every call of \babyloniannum. It's much better to define a specific font face.







enter image description here

There are also a couple of spurious spaces to be removed. Before editing, from


I get


With the following edits (that make also redundant the suggested \patchcmd)

\ProvidesPackage{babyloniannum}%%%% EDITED
    [2011/08/19 0.5 Typeset Babylonian numerals with XeTeX and LuaTeX]
\ifnum #1 > \z@ % glyph is not zero
  \chardef\m@mten=10 % cuts by units of 10
  \numdigits{#1}% parse number
  \ifcase\c@xsm@mctr %
    \relax %
    \unicodedisp{1230B} %10
    \unicodedisp{1230B}\kern-0.15em{}\unicodedisp{1230B} %20 -- unknown?
    \unicodedisp{1230D} %30
    \unicodedisp{1240F} %40
    \unicodedisp{12410} %50
  \ifnum \c@ism@mctr > \z@ %
    \ifnum \c@xsm@mctr > \z@ %
  \kern-0.5em{} % make glyphs closer
    \fi %
  \fi %
  \ifcase\c@ism@mctr %
    \unicodedisp{12079} %1
    \unicodedisp{1222B} %2
    \unicodedisp{12408} %3
    \unicodedisp{120FB} %4
    \unicodedisp{1240A} %5
    \unicodedisp{1240B} %6
    \unicodedisp{1240C} %7
    \unicodedisp{1240D} %8
    \unicodedisp{1240E} %9
  \ifnum\c@baby@glyphs > \z@ %
\kern0.5em{}% empty space for zero
\newcounter{baby@ism@mctr}  % "units"
\newcounter{baby@xsm@mctr}  % "tens"
\newcounter{baby@csm@mctr}  % "hundreds"
\newcounter{baby@ksm@mctr}  % "thousands"
\newcounter{baby@xksm@mctr} % "ten thousands"
\newcounter{baby@cksm@mctr} % "hundred thousands"
\newcounter{baby@msm@mctr}  % "millions"
\newcounter{baby@xmsm@mctr} % "ten millions"
\newcounter{baby@cmsm@mctr} % "hundred millions"
\newcounter{baby@bsm@mctr}  % "billions"
  \chardef\m@mten=60 % Cut by units of 60
  \numdigits{#1}% Parse number
%% End of file `babyloniannum.sty'.

the output is

enter image description here

| improve this answer | |

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.