こんにちは
VScode で TeX ファイルを処理したところ,エラーが出て作業が途中で止まります.
何となく makeindex 関係のトラブルではないかと思えるのですが,正確なところが理解できないため,ヒント等頂戴できればと存じます.
当方の設定は,PCは Windows 10 Home edition
TeX は TeX Live 2023 を minimal スキームでインストール.
チェックしたコレクションはLaTeX基本パッケージ,LaTeX推奨パッケージ,LuaTeXパッケージ,Windows専用プログラム(最初からチェックあり),必須プログラムとファイル(最初からチェックあり),推奨フォント,数学・自然科学・計算機科学パッケージ,画像と図表
普段は LuaLaTeX を使っています.
VScode の settings.json に追記した内容は
// レシピ
"latex-workshop.latex.recipes": [
{
"name": "latexmk (lualatex)",
"tools": [
"lualatexmk"
]
}
],
// レシピ用のパーツ
"latex-workshop.latex.tools": [
{
"name": "lualatexmk",
"command": "latexmk",
"args": [
"-synctex=1",
"-interaction=nonstopmode",
"-file-line-error",
"-outdir=%OUTDIR%",
"%DOC%"
],
"env": {}
}
],
.latexmkrc の内容は
#!/usr/bin/env perl
$latex = 'lualatex -synctex=1 %O %S';
$bibtex = 'pbibtex %O %B';
$pdflatex = 'lualatex -shell-escape';
$makeindex = 'mendex %O -o %D %S';
$pvc_view_file_via_temporary = 0;
$max_repeat = 5;
以上です.この環境下で TeX ファイル
\documentclass[lualatex,a4j,9pt]{ltjsarticle}
\usepackage[haranoaji,bold,no-math,expert]{luatexja-preset}
\begin{document}
\begin{equation}
3+2=5\label{eq01}
\end{equation}
式(\ref{eq01})
\end{document}
をコンパイル(Build LaTeX project をクリック)したところ,まず途中で
Recipe terminated with error. Retry building the project.
という警告(黄色のビックリマーク)が出ます.しかし作業は続き,またしばらくして
Recepe terminated with error.
というメッセージ(赤い×)が出て,作業が止まります.この段階で一応 PDF ファイルはできていますが,相互参照は(??)となっています.
最後に,長くなりますが処理した際に出てきたログを写します.
Initial Win CP for (console input, console output, system): (CP932, CP932, CP932)
I changed them all to CP932
Rc files read:
C:/Users/user1/.latexmkrc
.latexmkrc
Latexmk: This is Latexmk, John Collins, 4 Apr. 2023. Version 4.80.
No specific requests made, so using default for latexmk.
No existing .aux file, so I'll make a simple one, and require run of *latex.
Latexmk: applying rule 'latex'...
Rule 'latex': Reasons for rerun
Category 'other':
Rerun of 'latex' forced or previously required
------------
Run number 1 of rule 'latex'
------------
------------
Running 'lualatex -synctex=1 -synctex=1 -interaction=nonstopmode -file-line-error -recorder "c:/Users/user1/Desktop/TexliveVscode/Sample.tex"'
------------
This is LuaHBTeX, Version 1.17.0 (TeX Live 2023)
restricted system commands enabled.
(c:/Users/user1/Desktop/TexliveVscode/Sample.tex
LaTeX2e <2023-06-01>
L3 programming layer <2023-06-05>
(c:/texlive/2023/texmf-dist/tex/luatex/luatexja/ltjsarticle.cls
Document Class: ltjsarticle 2022/09/12 ltjsclasses
(c:/texlive/2023/texmf-dist/tex/luatex/luatexja/luatexja.sty (c:/texlive/2023/texmf-dist/tex/luatex/luatexja/luatexja-core.sty (c:/texlive/2023/texmf-dist/tex/luatex/luatexbase/luatexbase.sty (c:/texlive/2023/texmf-dist/tex/luatex/ctablestack/ctablestack.sty)) (c:/texlive/2023/texmf-dist/tex/generic/ltxcmds/ltxcmds.sty) (c:/texlive/2023/texmf-dist/tex/generic/pdftexcmds/pdftexcmds.sty (c:/texlive/2023/texmf-dist/tex/generic/infwarerr/infwarerr.sty) (c:/texlive/2023/texmf-dist/tex/generic/iftex/iftex.sty)) (c:/texlive/2023/texmf-dist/tex/latex/xkeyval/xkeyval.sty (c:/texlive/2023/texmf-dist/tex/generic/xkeyval/xkeyval.tex (c:/texlive/2023/texmf-dist/tex/generic/xkeyval/xkvutils.tex (c:/texlive/2023/texmf-dist/tex/generic/xkeyval/keyval.tex)))) (c:/texlive/2023/texmf-dist/tex/latex/etoolbox/etoolbox.sty) (c:/texlive/2023/texmf-dist/tex/latex/everyhook/everyhook.sty (c:/texlive/2023/texmf-dist/tex/latex/svn-prov/svn-prov.sty)) (c:/texlive/2023/texmf-dist/tex/luatex/luatexja/ltj-base.sty) (c:/texlive/2023/texmf-dist/tex/luatex/luatexja/ltj-latex.sty (c:/texlive/2023/texmf-dist/tex/luatex/luatexja/patches/lltjfont.sty (c:/texlive/2023/texmf-dist/tex/latex/base/tuenc.def)) (c:/texlive/2023/texmf-dist/tex/luatex/luatexja/patches/lltjdefs.sty
(c:/texlive/2023/texmf-dist/tex/luatex/luatexja/jfm-ujisv.lua)
(c:/texlive/2023/texmf-dist/tex/luatex/luatexja/jfm-ujis.lua)) (c:/texlive/2023/texmf-dist/tex/luatex/luatexja/patches/lltjcore.sty (c:/texlive/2023/texmf-dist/tex/latex/l3kernel/expl3.sty (c:/texlive/2023/texmf-dist/tex/latex/l3backend/l3backend-luatex.def))) (c:/texlive/2023/texmf-dist/tex/luatex/luatexja/patches/lltjp-atbegshi.sty) (c:/texlive/2023/texmf-dist/tex/luatex/luatexja/patches/lltjp-geometry.sty (c:/texlive/2023/texmf-dist/tex/generic/iftex/ifluatex.sty)))) (c:/texlive/2023/texmf-dist/tex/luatex/luatexja/luatexja-compat.sty)) (c:/texlive/2023/texmf-dist/tex/platex/jsclasses/jslogo.sty)) (c:/texlive/2023/texmf-dist/tex/luatex/luatexja/addons/luatexja-preset.sty (c:/texlive/2023/texmf-dist/tex/latex/l3packages/l3keys2e/l3keys2e.sty) (c:/texlive/2023/texmf-dist/tex/luatex/luatexja/addons/luatexja-fontspec.sty (c:/texlive/2023/texmf-dist/tex/latex/fontspec/fontspec.sty (c:/texlive/2023/texmf-dist/tex/latex/l3packages/xparse/xparse.sty) (c:/texlive/2023/texmf-dist/tex/latex/fontspec/fontspec-luatex.sty (c:/texlive/2023/texmf-dist/tex/latex/base/fontenc.sty) (c:/texlive/2023/texmf-dist/tex/latex/fontspec/fontspec.cfg))) (c:/texlive/2023/texmf-dist/tex/luatex/luatexja/patches/lltjp-fontspec.sty) (c:/texlive/2023/texmf-dist/tex/luatex/luatexja/addons/luatexja-fontspec-27c.sty))
Package luatexja-preset Warning: Japanese fonts will be scaled by 0.924715.
Package luatexja-fontspec Warning: \addjfontfeature(s) ignored;
(luatexja-fontspec) it cannot be used with a font that wasn't
(luatexja-fontspec) selected by luatexja-fontspec.
)
LaTeX Warning: Unused global option(s):
[lualatex].
(./Sample.aux) (c:/texlive/2023/texmf-dist/tex/latex/base/ts1cmr.fd)
LaTeX Warning: Reference `eq01' on page 1 undefined on input line 9.
[1{c:/texlive/2023/texmf-var/fonts/map/pdftex/updmap/pdftex.map}] (./Sample.aux)
LaTeX Warning: There were undefined references.
LaTeX Warning: Label(s) may have changed. Rerun to get cross-references right.
)
840 words of node memory still in use:
7 hlist, 1 vlist, 4 rule, 2 glue, 3 kern, 1 glyph, 151 attribute, 49 glue_spec, 22 attribute_list, 1 write, 9 user_defined nodes
avail lists: 1:12,2:575,3:14,4:23,5:24,6:4,7:80,8:7,9:34
<c:/texlive/2023/texmf-dist/fonts/opentype/public/lm/lmroman10-bold.otf><c:/texlive/2023/texmf-dist/fonts/opentype/public/haranoaji/HaranoAjiMincho-Regular.otf><c:/texlive/2023/texmf-dist/fonts/opentype/public/lm/lmroman10-regular.otf><c:/texlive/2023/texmf-dist/fonts/type1/public/amsfonts/cm/cmr10.pfb>
Output written on Sample.pdf (1 page, 14714 bytes).
SyncTeX written on Sample.synctex.gz.
Transcript written on Sample.log.
Latexmk: ===For rule 'latex', the extensions differ between the
actual output file 'Sample.pdf',
and the expected output 'Sample.dvi'.
I could not accommodate the changed output extension
(either because the configuration does not allow it
or because there is a conflict with requested filetypes).
Latexmk: ====List of undefined refs and citations:
Reference `eq01' on page 1 undefined on input line 9
----------------------
This message may duplicate earlier message.
Latexmk: Failure in processing file 'c:/Users/user1/Desktop/TexliveVscode/Sample':
Could not handle change of output extension
----------------------
Latexmk: If appropriate, the -f option can be used to get latexmk
to try to force complete processing.
Latexmk: Getting log file 'Sample.log'
Latexmk: Examining 'Sample.fls'
Latexmk: Examining 'Sample.log'
Latexmk: References changed.
Latexmk: Log file says output to 'Sample.pdf'
Latexmk: Summary of warnings from last run of *latex:
Latex failed to resolve 1 reference(s)
Latexmk: Errors, so I did not complete making targets
Collected error summary (may duplicate other messages):
latex: failed to create output file
C:\texlive\2023\bin\windows\runscript.tlu:921: command failed with exit code 12:
perl.exe c:\texlive\2023\texmf-dist\scripts\latexmk\latexmk.pl -synctex=1 -interaction=nonstopmode -file-line-error -outdir=c:/Users/user1/Desktop/TexliveVscode c:/Users/user1/Desktop/TexliveVscode/Sample
この設定が間違っている,そもそも TeX Live インストール時に不足があったはず等のご指摘を賜れば幸いです.
山下