从源代码构建 xetex+dvipdfmx 的最简约方法是什么?
我目前的问题是,我无法可靠地禁用所有其他(不必要的?)texlive 程序的构建,所以--disable-all-pkgs
似乎不起作用。理想情况下,我会得到一些尽可能小的东西https://github.com/TeX-Live/xetex/tree/master/source/texk/web2c+https://github.com/TeX-Live/texlive-source/tree/master/texk/dvipdfm-x。
有什么建议可以使这个构造更加紧凑吗?
谢谢!
我咨询了http://www.linuxfromscratch.org/blfs/view/svn/pst/texlive.html和https://www.tug.org/texlive/doc/tlbuild.html#Build-one-engine。当我尝试cd texlive-20200406-source/texlive-build/texk/web2c && make xetex
而不是 时make
,它会失败并且找不到xetex
目标。我不太明白如何使用标准的树外构建来仅构建一些程序。也许配置参数有问题。
# does not include yet final steps with tlpd and texmf
wget ftp://tug.org/texlive/historic/2020/texlive-20200406-source.tar.xz
tar -xf texlive-20200406-source.tar.xz
MAKEFLAGS=-j20
PREFIX=$PWD/prefix
mkdir -p $PREFIX
CACHE=$PWD/config.cache
pushd texlive-20200406-source
mkdir -p texlive-build
pushd texlive-build
../configure \
--cache-file=$CACHE \
--prefix=$PREFIX \
--disable-dvisvgm \
--disable-luatex \
--disable-luajittex \
--disable-luahbtex \
--disable-luajithbtex \
--disable-mflua \
--disable-mfluajit \
--disable-biber \
--disable-etex \
--disable-detex \
--disable-dvi2tty \
--disable-dvipng \
--disable-dvisvgm \
--disable-lcdf-typetools \
--disable-ps2eps \
--disable-psutils \
--disable-t1utils \
--disable-texinfo \
--disable-xindy \
--disable-all-pkgs \
--disable-multiplatform \
--enable-static \
--disable-shared \
--enable-web2c \
--enable-xetex \
--enable-dvipdfm-x \
--without-x \
--without-system-cairo \
--without-system-gmp \
--without-system-graphite2 \
--without-system-harfbuzz \
--without-system-libgs \
--without-system-libpaper \
--without-system-mpfr \
--without-system-pixman \
--without-system-poppler \
--without-system-xpdf \
--without-system-icu \
--without-system-fontconfig \
--without-system-freetype2 \
--without-system-libpng \
--without-system-zlib \
--with-banner-add=" - BLFS"
make $MAKEFLAGS
make $MAKEFLAGS install
ls prefix/bin
aleph cweave ebb inimf mf-nowin odvitype ovf2ovp pdvitype ptex teckit_compile updvitype weave
bibtex dvicopy eptex initex mfplain ofm2opl ovp2ovf pktogf ptftopl tex upmpost wofm2opl
ctangle dvipdfm euptex kpseaccess mft omfonts patgen pktype r-mpost tftopl uppltotf wopl2ofm
ctie dvipdfmx extractbb kpsereadlink mkocp opl2ofm pbibtex pltotf r-pmpost tie uptex wovf2ovp
ctwill dvipdft gftodvi kpsestat mkofm otangle pdftex pmpost r-upmpost ttf2afm uptftopl wovp2ovf
ctwill-refsort dvitomp gftopk kpsewhich mpost otp2ocp pdftosrc pooltype synctex upbibtex vftovp xdvipdfmx
ctwill-twinx dvitype gftype mf odvicopy outocp pdvitomp ppltotf tangle updvitomp vptovf xetex
ls prefix/lib
libkpathsea.a libkpathsea.la libptexenc.a libptexenc.la libsynctex.a pkgconfig
当仅使用以下方式构建时--disable-all-pkgs
:
../configure \
--cache-file=$CACHE \
--prefix=$PREFIX \
--enable-static \
--disable-shared \
--disable-multiplatform \
--disable-native-texlive-build \
--disable-all-pkgs \
--without-x \
--without-system-cairo \
--without-system-gmp \
--without-system-graphite2 \
--without-system-harfbuzz \
--without-system-libgs \
--without-system-libpaper \
--without-system-mpfr \
--without-system-pixman \
--without-system-poppler \
--without-system-xpdf \
--without-system-icu \
--without-system-fontconfig \
--without-system-freetype2 \
--without-system-libpng \
--without-system-zlib \
--with-banner-add=" - BLFS"
ls prefix
share
--disable-all-pkgs --enable-xetex --enable-dvipdfm-x
使用(不使用)构建时--enable-web2c
:
../configure \
--cache-file=$CACHE \
--prefix=$PREFIX \
--enable-static \
--enable-xetex \
--enable-dvipdfm-x \
--disable-shared \
--disable-multiplatform \
--disable-native-texlive-build \
--disable-all-pkgs \
--disable-dvipng \
--disable-dvisvgm \
--disable-dvi2tty \
--disable-luatex \
--disable-luajittex \
--disable-luahbtex \
--disable-luajithbtex \
--disable-mflua \
--disable-mfluajit \
--disable-etex \
--disable-detex \
--disable-lcdf-typetools \
--disable-ps2eps \
--disable-psutils \
--disable-t1utils \
--disable-texinfo \
--disable-xindy \
--disable-biber \
--without-x \
--without-system-cairo \
--without-system-gmp \
--without-system-graphite2 \
--without-system-harfbuzz \
--without-system-libgs \
--without-system-libpaper \
--without-system-mpfr \
--without-system-pixman \
--without-system-poppler \
--without-system-xpdf \
--without-system-icu \
--without-system-fontconfig \
--without-system-freetype2 \
--without-system-libpng \
--without-system-zlib \
--with-banner-add=" - BLFS"
ls prefix/bin
dvipdfm dvipdfmx dvipdft ebb extractbb kpseaccess kpsereadlink kpsestat kpsewhich xdvipdfmx
我设法从 TexLive 编译了 xetex 和 dvipdfm-x。但是创建格式文件失败:
TEXLIVE_BASE_URL=http://mirrors.ctan.org/macros/latex/base.zip
TEXLIVE_INSTALLER_URL=http://mirror.ctan.org/systems/texlive/tlnet/install-tl-unx.tar.gz
mkdir -p texlive
echo selected_scheme scheme-basic > texlive/profile.input
echo TEXDIR $PWD/texlive >> texlive/profile.input
echo TEXMFLOCAL $PWD/texlive/texmf-local >> texlive/profile.input
echo TEXMFSYSVAR $PWD/texlive/texmf-var >> texlive/profile.input
echo TEXMFSYSCONFIG $PWD/texlive/texmf-config >> texlive/profile.input
echo TEXMFVAR $PWD/home/texmf-var >> texlive/profile.input
wget $TEXLIVE_INSTALLER_URL
pushd texlive
tar xzvf ../install-tl-unx.tar.gz
./install-tl-*/install-tl -profile profile.input
rm -rf bin readme* tlpkg install* *.html texmf-dist/doc texmf-var/web2c
echo "Done! Please run 'make texlive.lst' now!"
popd
wget $TEXLIVE_BASE_URL
mkdir -p latex_format
pushd latex_format
unzip -o ../base.zip
pushd base
$XELATEX_EXE -ini -etex unpack.ins
$XELATEX_EXE -ini -etex latex.ltx
Local config file preload.cfg used
=====================================
(base/preload.cfg (base/preload.ltx
kpathsea: Running mktextfm cmex10
mktextfm: No such file or directory
kpathsea: Appending font creation commands to missfont.log.
! Font \OMX/cmex/m/n/10=cmex10 not loadable: Metric (TFM) file or installed fon
t not found.
<to be read again>
\relax
l.41 ...ame OMX/cmex/m/n/10\endcsname=cmex10\relax
答案1
您现在遇到的问题是缺少字体文件。我认为您将会遇到许多尝试和错误步骤,逐个安装东西。您需要从字体/厘米并将它们安装在适合 TeX 安装的目录中(大多数人只进行 TeXlive 安装是有原因的)。
出于好奇,您通过这个过程的目的是什么?我认为修剪完整安装可能比尝试逐个构建选择性安装更容易。