LINUX.ORG.RU

texlive-latex и русский язык


1

0

помогите настроить латех на русские буквы.

Ubuntu 8.04 dvd

поставил
sudo apt-get install texlive-latex-base
sudo apt-get install texlive-doc-ru
sudo apt-get install texlive-lang-cyrillic

$ cat test.tex\documentclass{article}
\usepackage[utf8]{inputenc}
\usepackage[russian]{babel}
\begin{document}
test тест $x^2$
\end{document}

после компиляции (пришлось нажать r) текст в dvi файле не отображается

$ latex test.tex
This is pdfTeXk, Version 3.141592-1.40.3 (Web2C 7.5.6)
%&-line parsing enabled.
entering extended mode
(./test.tex
LaTeX2e <2005/12/01>
Babel <v3.8h> and hyphenation patterns for english, usenglishmax, dumylang, noh
yphenation, ukrainian, russian, bulgarian, loaded.
(/usr/share/texmf-texlive/tex/latex/base/article.cls
Document Class: article 2005/09/16 v1.4f Standard LaTeX document class
(/usr/share/texmf-texlive/tex/latex/base/size10.clo))
(/usr/share/texmf-texlive/tex/latex/base/inputenc.sty
(/usr/share/texmf-texlive/tex/latex/base/utf8.def
(/usr/share/texmf-texlive/tex/latex/base/t1enc.dfu)
(/usr/share/texmf-texlive/tex/latex/base/ot1enc.dfu)
(/usr/share/texmf-texlive/tex/latex/base/omsenc.dfu)))
(/usr/share/texmf-texlive/tex/generic/babel/babel.sty
(/usr/share/texmf-texlive/tex/generic/babel/russianb.ldf
(/usr/share/texmf-texlive/tex/generic/babel/babel.def)
(/usr/share/texmf-texlive/tex/latex/cyrillic/t2aenc.def
(/usr/share/texmf-texlive/tex/latex/base/t2aenc.dfu)))) (./test.aux
(/usr/share/texmf-texlive/tex/latex/cyrillic/t2acmr.fd)kpathsea: Running mktextfm larm1000
mktextfm: Running mf-nowin -progname=mf \mode:=ljfour; mag:=1; nonstopmode; input larm1000
This is METAFONT, Version 2.71828 (Web2C 7.5.6)

(/home/dmitry/.texmf-var/fonts/source/lh/lh-t2a/larm1000.mf
(/usr/share/texmf-texlive/fonts/source/lh/base/fikparm.mf
(/usr/share/texmf-texlive/fonts/source/public/cm/cmbase.mf)
(/usr/share/texmf-texlive/fonts/source/lh/base/lcyrbeg.mf)
(/usr/share/texmf-texlive/fonts/source/lh/base/lkligtbl.mf)
>> 10
kpathsea: Running mktexmf ecrm
>> "input ecrm"
! I can't find file `ecrm'.
<scantokens> input ecrm

<to be read again>
;
use_driver->...#=pt#;pt#:=true_pt#;scantokens(ss);
pt#:=true_pt#;font_identif...
l.293 use_driver(fonteq)
;
Please type another input file name
! Emergency stop.
<scantokens> input ecrm

<to be read again>
;
use_driver->...#=pt#;pt#:=true_pt#;scantokens(ss);
pt#:=true_pt#;font_identif...
l.293 use_driver(fonteq)
;
Transcript written on larm1000.log.
mktextfm: `mf-nowin -progname=mf \mode:=ljfour; mag:=1; nonstopmode; input larm1000' failed.
kpathsea: Appending font creation commands to missfont.log.

! Font T2A/cmr/m/n/10=larm1000 at 10.0pt not loadable: Metric (TFM) file not fo
und.
<to be read again>
relax
l.3 \select@language{russian}

? r
OK, entering nonstopmode...
) [1] (./test.aux) )
(see the transcript file for additional information)
Output written on test.dvi (1 page, 256 bytes).
Transcript written on test.log.

anonymous

Ответ на: комментарий от Sphinx

что достаить?

$ apt-cache search texlive
texlive-context - TeX Live: ConText macro package
texlive-chemistry - TeX Live: Chemical typesetting
texlive-pdfetex - TeX Live: pdfTeX
texlive-base - TeX Live: Essential programs and files
texlive-common - TeX Live: Base component
texlive-latex-base - TeX Live: Basic LaTeX packages
texlive-base-bin - TeX Live: Essential binaries
texlive-lang-indic - TeX Live: Indic
texlive-doc-base - TeX Live: Base documentation
texlive-doc-bg - TeX Live: Bulgarian documentation
texlive-doc-cs+sk - TeX Live: Czechslovak documentation
texlive-doc-de - TeX Live: German documentation
...
texlive-lang-african - TeX Live: African scripts
texlive-lang-all - TeX Live: Meta package depending on all TeX Live language packages
texlive-lang-arab - TeX Live: Arabic
...
texlive - TeX Live: A decent selection of the TeX Live packages
texlive-base-bin-doc - TeX Live: Documentation files for texlive-base-bin
texlive-bibtex-extra - TeX Live: Extra BibTeX styles
texlive-extra-utils - TeX Live: TeX auxiliary programs
texlive-font-utils - TeX Live: TeX font-related programs
texlive-fonts-extra - TeX Live: Extra fonts
texlive-fonts-extra-doc - TeX Live: Documentation files for texlive-fonts-extra
texlive-fonts-recommended - TeX Live: Recommended fonts
texlive-fonts-recommended-doc - TeX Live: Documentation files for texlive-fonts-recommended
texlive-generic-recommended - TeX Live: Miscellaneous generic macros
texlive-humanities-doc - TeX Live: Documentation files for texlive-humanities
texlive-latex-base-doc - TeX Live: Documentation files for texlive-latex-base
texlive-latex-extra - TeX Live: LaTeX supplementary packages
texlive-latex-extra-doc - TeX Live: Documentation files for texlive-latex-extra
texlive-latex-recommended - TeX Live: LaTeX recommended packages
texlive-latex-recommended-doc - TeX Live: Documentation files for texlive-latex-recommended
texlive-math-extra - TeX Live: Advanced math typesetting
texlive-metapost-doc - TeX Live: Documentation files for texlive-metapost
texlive-pictures - TeX Live: Packages for drawings graphics
texlive-pictures-doc - TeX Live: Documentation files for texlive-pictures
texlive-pstricks - TeX Live: PSTricks packages
texlive-pstricks-doc - TeX Live: Documentation files for texlive-pstricks
texlive-publishers - TeX Live: Support for publishers
texlive-publishers-doc - TeX Live: Documentation files for texlive-publishers
texlive-science-doc - TeX Live: Documentation files for texlive-science
cl-qbook - create HTML/LaTeX versions of Common Lisp source code
context - powerful TeX format
feynmf - set of LaTeX macros for creating Feynman diagrams
libmaruku-ruby1.8 - a Markdown-superset interpreter for Ruby
texlive-formats-extra - TeX Live: Extra formats
texlive-full - TeX Live: meta package pulling in all components of TeX Live
texlive-games - TeX Live: Games typesetting (chess, etc)
texlive-generic-extra - TeX Live: Miscellaneous extra generic macros
texlive-humanities - TeX Live: LaTeX support for the humanities
texlive-latex3 - TeX Live: LaTeX3 packages
texlive-metapost - TeX Live: MetaPost (and Metafont) drawing packages
texlive-music - TeX Live: Music typesetting
texlive-omega - TeX Live: Omega
texlive-plain-extra - TeX Live: Plain TeX supplementary packages
texlive-science - TeX Live: Typesetting for natural and computer sciences
texlive-xetex - TeX Live: XeTeX macros
therion - Cave surveying - 2D and 3D drawing software

anonymous
()

Всё правильно, нужно использовать другой пакет:

\usepackage[utf8x]{inputenc}

anonymous
()
Ответ на: комментарий от anonymous

>> texlive-lang-cyrillic, очевидно
> см. первое сообщение: этот пакет стоит.


Тогда странно... У меня с
\usepackage[utf8]{inputenc}
\usepackage[russian]{babel}
всё хорошо работает.

Полный список пакетов у меня:
$ dpkg -l \*texlive\* | grep ^ii
ii texlive 2007.dfsg.1-3 TeX Live: A decent selection of the TeX Live packages
ii texlive-base 2007.dfsg.1-3 TeX Live: Essential programs and files
ii texlive-base-bin 2007.dfsg.2-3 TeX Live: Essential binaries
ii texlive-common 2007.dfsg.1-3 TeX Live: Base component
ii texlive-doc-base 2007.dfsg.1-1 TeX Live: Base documentation
ii texlive-doc-ru 2007.dfsg.1-1 TeX Live: Russian documentation
ii texlive-fonts-recommended 2007.dfsg.1-3 TeX Live: Recommended fonts
ii texlive-generic-extra 2007.dfsg.3-2 TeX Live: Miscellaneous extra generic macros
ii texlive-lang-cyrillic 2007.dfsg.3-3 TeX Live: Cyrillic
ii texlive-latex-base 2007.dfsg.1-3 TeX Live: Basic LaTeX packages
ii texlive-latex-recommended 2007.dfsg.1-3 TeX Live: LaTeX recommended packages
ii texlive-math-extra 2007.dfsg.3-2 TeX Live: Advanced math typesetting

gaa ★★
()

Точно, пример у меня компилируется нормально, даже без

\usepackage{ucs}

\usepackage[utf8x]{inputenc}

Хотя, в новых версиях texlive лучше писать utf8x вместо utf8.

Возможно проблема в недостатке некоторых пакетов. У меня (arch):

pacman -Qs texlive

local/texlive-bin 2007.2-2

TeX Live binaries

local/texlive-core 2007.2-2 (texlive-most)

TeX Live core distribution

local/texlive-langcyrillic 2007.1-2 (texlive-lang)

TeX Live - Fonts and macro packages to typeset Cyrillic texts

Всего три, но они явно больше дебиановских.

anonymous
()
Ответ на: комментарий от anonymous

>\usepackage[russian]{babel}

Где-то я читал, что нужно использовать

\usepackage[english,russian]{babel}

Возможно, это устаревшее требование, но попробовать стоит.

DiGital
()
Вы не можете добавлять комментарии в эту тему. Тема перемещена в архив.