0

I want to change some package,but in the beginning of the package i need in checking,what compiler use. For example,if i use latex,i want to require one packages,for lualatex i want to require other packages,and for any other compiler i want to require other packages,which i not require for latex and lualatex. Give me please small example,which show,how to check latex,lualatex and any other compilers. Thanks everybody for the help.

  • 2
    You can use the package ifluatex, ifxetex and ifpdf for various test combinations. In expl3 there are also various commands like \sys_if_engine_luatex:TF, for such tests. Be aware that you should never change the original code of a package. – Ulrike Fischer Apr 03 '19 at 14:37
  • @Ulrike Fischer I read something about commands \sys_if_engine_luatex:T and \sys_if_engine_luatex:TF,but at first,i not understood,what differents between T and TF. At second,i not found any example,how to use this commands,because add a lot of other packages to the package it,in my opinion,very bad practice,so i want to use \sys_if_engine_tex:T,\sys_if_engine_luatex:T,etc. But may be also exist command to check any other compilers? I mean if i use not latex and not lualatex require another packages. – Aleksandr Kozlovskiy Apr 03 '19 at 15:32
  • 1
    The difference between T and TF is that the first has only a "true" branch, the second a "true" and a "false" branch. In expl3 there are tests for xetex, pdftex, luatex, ptex and uptex, and for the output modes dvi and pdf. – Ulrike Fischer Apr 03 '19 at 15:42

0 Answers0