[lltx] how to disable language before dumping it to lualatex.fmt?

Linas Stonys lstonys at vtex.lt
Thu Nov 22 15:33:46 CET 2012

Hi, all,
I've read "The hyphen.cfg file for LuaTEX" (luatex-hyphen.pdf from 
TL2012) and still don't understand is it possible to do not add language 
to lualatex.fmt, by disabling it in language.dat.lua, but leaving it 
enabled in language.dat.

The problem is that I want to dump old russian cyrillic hyphenation 
patterns to latex, but don't want it to be in lualatex (with latex is 
everything ok).

cyrillic loadhyph-ru-cyrl.tex

\addlanguage {cyrillic}{loadhyph-ru-cyrl}{}{2}{3}

     ["cyrillic"] = {
         loader = 'loadhyph-ru-cyrl.tex',
         lefthyphenmin = 2,
         righthyphenmin = 2,
         synonyms = {  },
         special = 'disabled:Not supported in luatex',

I update language config files:
   tlmgr generate language

Then, I recreate fmt files. And when I compile
test document with lualatex, I see "cyrillic" language in listed patterns :
This is LuaTeX, Version beta-0.70.2-2012080612 (TeX Live 2012/W32TeX) 
(format=lualatex 2012.11.22)  22 NOV 2012 15:29
  restricted \write18 enabled.
LaTeX2e <2011/06/27>
LuaTeX adaptation of babel <v3.8m-luatex-1.5> and hyphenation patterns 
for engl
ish, dumylang, nohyphenation, cyrillic, loaded.

and I still can access language counter \l at cyrillic.
So I understand, that language counter is increased anyway (it does not 
check "special = 'disabled:'" before adding language to the list)

Is it possible to disable some how the language from dumping it to fmt 
at all?
For example to write let say:
["cyrillic"] = null

In tex loadhyph-ru-cyrl.tex I disable it from dumping by testing the 
engine, but the language counter is increased anyway and \l at cyrillic is 

\testengine Τ!\relax
% Unicode-aware engine (such as XeTeX or LuaTeX) only sees a single 
(2-byte) argument
     \message{Not supported for XeTeX or LuaTeX}
     \message{Cyrillic Hyphenation Patterns for "russian"}
     \input ruhyph.tex


More information about the lualatex-dev mailing list