Jürgen Spitzmüller wrote: > > Yes. > > And who is gonna do it? ;-)
Always the one who asks ... Could someone with TeXLive 2009 try if the attached patch works (i.e., reports that LuaTeX is not usable and does not set it up)? Jürgen
Index: lib/configure.py =================================================================== --- lib/configure.py (Revision 38044) +++ lib/configure.py (Arbeitskopie) @@ -426,6 +426,34 @@ return '' +def checkLuatex(): + ''' Check if luatex is there and usable ''' + path, LUATEX = checkProg('LuaTeX', ['lualatex $$i']) + path, DVILUATEX = checkProg('LuaTeX (DVI)', ['dvilualatex $$i']) + # no luatex + if LUATEX != '': + msg = "checking if LuaTeX is usable ..." + # Check if luatex is usable + writeToFile('luatest.tex', ''' +\\nonstopmode\\documentclass{minimal} +\\usepackage{fontspec} +\\begin{document} +. +\\end{document} +''') + # run lualatex on luatest.tex and check result + if cmdOutput(LUATEX + ' luatest.tex').find('XeTeX is required to compile this document') == -1: + # working luatex + logger.info(msg + ' yes') + addToRC(r'\converter luatex pdf5 "%s" "latex=lualatex"' % LUATEX) + if DVILUATEX != '': + addToRC(r'\converter luatex dvi3 "%s" "latex=lualatex"' % DVILUATEX) + else: + logger.info(msg + ' no (probably not recent enough)') + # remove temporary files + removeFiles(['luatest.tex', 'luatest.log']) + + def checkModule(module): ''' Check for a Python module, return the status ''' msg = 'checking for "' + module + ' module"... ' @@ -600,11 +628,7 @@ checkProg('XeTeX', ['xelatex $$i'], rc_entry = [ r'\converter xetex pdf4 "%%" "latex=xelatex"' ]) - checkProg('LuaTeX', ['lualatex $$i'], - rc_entry = [ r'\converter luatex pdf5 "%%" "latex=lualatex"' ]) - - checkProg('LuaTeX (DVI)', ['dvilualatex $$i'], - rc_entry = [ r'\converter luatex dvi3 "%%" "latex=lualatex"' ]) + checkLuatex() ''' If we're running LyX in-place then tex2lyx will be found in ../src/tex2lyx. Add this directory to the PATH temporarily and