通过 yum/dnf 提供的文件安装包

通过 yum/dnf 提供的文件安装包

至少在最近的 Fedora 系统上,可以通过指定 .sty 文件来安装 TeXLive 包,这很棒,例如

yum install 'tex(amsmath.sty)'

它还可以与 一起使用dnf,后者即将取代 yum。我找不到任何关于它应该如何工作的文档,除了“你可以做到”,yumdnf手册页都没有提到这一点。

这是使用了一些更通用的功能还是特定于 TeXLive 包的功能?它似乎与命令无关provide

答案1

正如您似乎已经猜到的那样,它通过提供机制工作 -通过询问 rpm 您可以看到该texlive-amsmath包具有提供功能:tex(amsmath.sty)

% rpm -q --provides texlive-amsmath
tex(amsbsy.sty) = 2013
tex(amscd.sty) = 2013
tex(amsgen.sty) = 2013
tex(amsmath.sty) = 2013
tex(amsopn.sty) = 2013
tex(amstex.sty) = 2013
tex(amstext.sty) = 2013
tex(amsxtra.sty) = 2013
tex-amsmath = 2013
texlive-amsmath = 3:svn30645.2.14-4.fc20

但是,spec 文件中可能没有明确的Provide标签,因为提供的内容可能是由脚本自动生成的。

相关内容