由于我无法在基于身份验证、仅 HTTP 的公司代理后面使用 first-setup.bat 脚本,因此我选择了 cygwin。
我安装了名为 20120628-1 的软件包texlive-collection-context
并尝试了它。
$ context test.tex
mtxrun | forcing cache reload
resolvers | resolving | unknown configuration file '/home/xxx/texmf/web2c/texmfcnf.lua'
resolvers | resolving | unknown configuration file '//usr/bin/texmfcnf.lua'
resolvers | resolving | unknown configuration file '//usr/bin/share/texmf-site/web2c/texmfcnf.lua'
resolvers | resolving | unknown configuration file '//usr/bin/share/texmf/web2c/texmfcnf.lua'
resolvers | resolving | unknown configuration file '//usr/bin/texmf-site/web2c/texmfcnf.lua'
resolvers | resolving | unknown configuration file '//usr/bin/texmf/web2c/texmfcnf.lua'
resolvers | resolving | unknown configuration file '//usr/texmfcnf.lua'
resolvers | resolving | unknown configuration file '//usr/share/texmf-site/web2c/texmfcnf.lua'
resolvers | resolving | unknown configuration file '//usr/share/texmf/web2c/texmfcnf.lua'
resolvers | resolving | unknown configuration file '//usr/texmf-site/web2c/texmfcnf.lua'
resolvers | resolving | unknown configuration file '//usr/texmf/web2c/texmfcnf.lua'
resolvers | resolving | unknown configuration file '//usr/usr/texmfcnf.lua'
resolvers | resolving | unknown configuration file '//usr/usr/share/texmf-site/web2c/texmfcnf.lua'
resolvers | resolving | unknown configuration file '//usr/usr/share/texmf/web2c/texmfcnf.lua'
resolvers | resolving | unknown configuration file '//usr/usr/texmf-site/web2c/texmfcnf.lua'
resolvers | resolving | unknown configuration file '//usr/usr/texmf/web2c/texmfcnf.lua'
resolvers | resolving | unknown configuration file '/texmf-site/web2c/texmfcnf.lua'
resolvers | resolving | unknown configuration file '/./texmfcnf.lua'
resolvers | resolving | unknown configuration file '/./share/texmf-site/web2c/texmfcnf.lua'
resolvers | resolving | unknown configuration file '/./share/texmf/web2c/texmfcnf.lua'
resolvers | resolving | unknown configuration file '/./texmf-site/web2c/texmfcnf.lua'
resolvers | resolving | unknown configuration file '/./texmf/web2c/texmfcnf.lua'
resolvers | resolving |
resolvers | resolving | warning: no lua configuration files found
resolvers | resolving | no texmf paths are defined (using TEXMF)
resolvers | resolving |
mtxrun | the resolver databases are not present or outdated
resolvers | resolving | using suffix based filetype 'lua'
resolvers | resolving | remembering file 'mtx-context.lua'
resolvers | resolving | using suffix based filetype 'lua'
resolvers | resolving | remembering file 'mtx-contexts.lua'
resolvers | resolving | remembered file 'mtx-context.lua'
resolvers | resolving | using suffix based filetype 'lua'
resolvers | resolving | remembering file 'mtx-t-context.lua'
resolvers | resolving | using suffix based filetype 'lua'
resolvers | resolving | remembering file 'mtx-t-contexts.lua'
resolvers | resolving | remembered file 'mtx-t-context.lua'
resolvers | resolving | using suffix based filetype 'lua'
resolvers | resolving | remembering file 'context.lua'
mtxrun | unknown script 'context.lua' or 'mtx-context.lua'
但是,texmfcnf.lua
系统上存在该文件:
$ ls -l /usr/share/texmf/web2c/texmfcnf.lua
-rw-r--r-- 1 xxx Domain Users 8356 6 août 2012 /usr/share/texmf/web2c/texmfcnf.lua
我不明白为什么脚本尝试访问//usr
而不是/usr
。在 mtxrun 源代码中,我卡在函数identify_configuration_files()
行 12711 中:
local realname = resolvers.resolve(filename)
转化/selfautodir:/share/texmf/web2c/texmfcnf.lua
为//usr/share/texmf/web2c/texmfcnf.lua
关于最后一个错误,似乎请求的文件也存在:
$ ls -l /usr/share/texmf-dist/scripts/context/lua/mtx-context.lua
-rw-r--r-- 1 xxx Domain Users 65606 2 juil. 2012 /usr/share/texmf-dist/scripts/context/lua/mtx-context.lua
编辑1
从 ~/texmf 到 /usr/share/texmf 的符号链接解决了大多数问题!
lrwxrwxrwx 1 xxx Domain Users 16 12 avr. 16:28 texmf -> /usr/share/texmf
lrwxrwxrwx 1 xxx Domain Users 22 12 avr. 16:36 texmf-dist -> /usr/share/texmf-dist/
lrwxrwxrwx 1 xxx Domain Users 22 12 avr. 16:36 texmf-site -> /usr/share/texmf-site/
$ context test.tex
只是挂起(每次网络访问超时的时间)并退出,出现一个新的、非常长的错误日志(甚至在之后mtxrun --generate
):
[snip]
resolvers | resolving | using given filetype 'tex'
resolvers | expansions | using caches scan of path '/home/a865111/texmf/tex/generic', branch '/home/xxx/texmf/tex/generic'
resolvers | resolving | remembering file '/home/xxx/.texlive2012/texmf-var/luatex-cache/context/74fde8c492a75a0a124aaeb6119048d0/formats/texmf-dist/tex/context/base/context.lus'
resolvers | formats | unknown stub specification: /home/xxx/.texlive2012/texmf-var/luatex-cache/context/74fde8c492a75a0a124aaeb6119048d0/formats/texmf-dist/tex/context/base/context.lus
mtx-context | error, no format found with name: cont-en, aborting
system | total runtime: 15.453
哦哦
编辑2
正如这篇文章中所说:TeXLive 2011 ConTeXt 问题
texexec test.tex
似乎现在可以了