9

I have a short latex program that fails to compile when I use the following:

\usepackage[scaled]{helvet}

I suspect that this is an issue with using BasicTeX on the Mac because I have seen this construct shown in so many places that I believe that it should work under normal conditions.

Here is the program.

\documentclass{article}
%
\usepackage[T1]{fontenc}
\usepackage{textcomp}
\usepackage[scaled]{helvet}
%
% change the default font to sans-serif
%
\renewcommand{\familydefault}{\sfdefault}
\begin{document}
Hello World!
\end{document}

And here is error output.

This is pdfTeX, Version 3.1415926-2.5-1.40.14 (TeX Live 2013)
 restricted \write18 enabled.
entering extended mode
(./hello.tex
LaTeX2e <2011/06/27>
Babel <3.9f> and hyphenation patterns for 21 languages loaded.
(/usr/local/texlive/2013basic/texmf-dist/tex/latex/base/article.cls
Document Class: article 2007/10/19 v1.4h Standard LaTeX document class
(/usr/local/texlive/2013basic/texmf-dist/tex/latex/base/size10.clo))
(/usr/local/texlive/2013basic/texmf-dist/tex/latex/base/fontenc.sty
(/usr/local/texlive/2013basic/texmf-dist/tex/latex/base/t1enc.def))
(/usr/local/texlive/2013basic/texmf-dist/tex/latex/base/textcomp.sty
(/usr/local/texlive/2013basic/texmf-dist/tex/latex/base/ts1enc.def))
(/usr/local/texlive/2013basic/texmf-dist/tex/latex/psnfss/helvet.sty
(/usr/local/texlive/2013basic/texmf-dist/tex/latex/graphics/keyval.sty))
(./hello.aux) (/usr/local/texlive/2013basic/texmf-dist/tex/latex/base/ts1cmr.fd
) (/usr/local/texlive/2013basic/texmf-dist/tex/latex/psnfss/t1phv.fd)
kpathsea: Running mktextfm phvr8t
/usr/local/texlive/2013basic/texmf-dist/web2c/mktexnam: Could not map source abbreviation  for phvr8t.
/usr/local/texlive/2013basic/texmf-dist/web2c/mktexnam: Need to update ?
mktextfm: Running mf-nowin -progname=mf \mode:=ljfour; mag:=1; nonstopmode; input phvr8t
This is METAFONT, Version 2.718281 (TeX Live 2013)


kpathsea: Running mktexmf phvr8t
! I can't find file `phvr8t'.
<*> ...:=ljfour; mag:=1; nonstopmode; input phvr8t

Please type another input file name
! Emergency stop.
<*> ...:=ljfour; mag:=1; nonstopmode; input phvr8t

Transcript written on mfput.log.
grep: phvr8t.log: No such file or directory
mktextfm: `mf-nowin -progname=mf \mode:=ljfour; mag:=1; nonstopmode; input phvr8t' failed to make phvr8t.tfm.
kpathsea: Appending font creation commands to missfont.log.

! Font T1/phv/m/n/10=phvr8t at 9.49997pt not loadable: Metric (TFM) file not found.
<to be read again> 
                   relax 
l.10 \begin{document}

The following gist suggests installing texlive-fonts-extra or urw-base35, but not sure how to do that on Mac.

https://gist.github.com/fernandomantoan/3751190

Thanks.

  • You can install additional packages using tlmgr. tlmgr help will explain the options. [Although I wouldn't bother for 'Hello World!' Just comment out the requirement for helvet...] – cfr Feb 13 '14 at 2:02
  • 1
    I have tried the following: tlmgr install texlive-fonts-extra, tlmgr install urw-base35, tlmgr install helvetica, and tlmgr install helvet. All of these respond that package <package> not present in package repository. – Carl Parker Feb 13 '14 at 2:08
  • Use tlmgr info collections to get information about the collections available. Then you can use tlmgr --list with a likely-sounding collection name to get a list of the available packages. – cfr Feb 13 '14 at 2:16
  • By the way, BasicTeX is precisely what its name means: a minimal TeX distribution. As such, it contains only the two standard fonts: Computer Modern and Latin Modern. Other fonts must be downloaded and installed by the user (e.g. via the TeX Live Utility). pages.uoregon.edu/koch/BasicTeX.pdf – Franck Pastor Feb 14 '14 at 12:52
12

TeX Live provides tlmgr to update, maintain and manage the installation. If you do not initially install a full TeX installation, you can use it to upgrade to a larger scheme or to install particular collections or packages.

TeX Live package names will not generally correspond to those used by e.g. distros when packaging TL. So you need to do some detective work to figure out what to tell tlmgr to install.

tlmgr help

gives the full details of this facility in all its glory. You can just say

tlmgr info

to get a listing of packages. However, this will be huge. Instead, try

tlmgr info collections

to get a listing of collections (groups of related packages). On my system, I get

tlmgr: package repository http://mirror.ox.ac.uk/sites/ctan.org/systems/texlive/tlnet
i collection-basic: Essential programs and files
i collection-bibtexextra: BibTeX additional styles
i collection-binextra: TeX auxiliary programs
i collection-context: ConTeXt and packages
i collection-fontsextra: Additional fonts
i collection-fontsrecommended: Recommended fonts
i collection-fontutils: Graphics and font utilities
i collection-formatsextra: Additional formats
i collection-games: Games typesetting
i collection-genericextra: Generic additional packages
i collection-genericrecommended: Generic recommended packages
i collection-htmlxml: HTML/SGML/XML support
i collection-humanities: Humanities packages
i collection-langafrican: African scripts
i collection-langarabic: Arabic
i collection-langcjk: Chinese/Japanese/Korean
i collection-langcyrillic: Cyrillic
i collection-langczechslovak: Czech/Slovak
i collection-langenglish: US and UK English
i collection-langeuropean: Other European languages
i collection-langfrench: French
i collection-langgerman: German
i collection-langgreek: Greek
i collection-langindic: Indic scripts
i collection-langitalian: Italian
i collection-langother: Other languages
i collection-langpolish: Polish
i collection-langportuguese: Portuguese
i collection-langspanish: Spanish
i collection-latex: LaTeX fundamental packages
i collection-latexextra: LaTeX additional packages
i collection-latexrecommended: LaTeX recommended packages
i collection-luatex: LuaTeX packages
i collection-mathextra: Mathematics packages
i collection-metapost: MetaPost and Metafont packages
i collection-music: Music packages
i collection-omega: Omega packages
i collection-pictures: Graphics, pictures, diagrams
i collection-plainextra: Plain TeX packages
i collection-pstricks: PSTricks
i collection-publishers: Publisher styles, theses, etc.
i collection-science: Natural and computer sciences
i collection-texworks: TeXworks editor
  collection-wintools: Windows-only support programs
i collection-xetex: XeTeX and packages

This shows me which repository I'm using, which collections are available and which are installed (marked with i). Almost all are installed here as I installed a full version of TeX. If you installed a smaller version, you will have fewer is. There are several collections which mention fonts:

i collection-fontsextra: Additional fonts
i collection-fontsrecommended: Recommended fonts
i collection-fontutils: Graphics and font utilities

The last sounds less likely. The first two are possibilities. Helvetica is pretty standard so it may well be recommended. So it makes sense to start there. To get information about the collection and a listing of the packages it includes:

tlmgr info --list collection-fontsrecommended

This gives me

package:     collection-fontsrecommended
category:    Collection
shortdesc:   Recommended fonts
longdesc:    Recommended fonts, including the base 35 PostScript fonts, Latin Modern, TeX Gyre, and T1 and other encoding support for Computer Modern, in outline form.
installed:   Yes
revision:    32620
sizes:       
relocatable: No
depends:
        collection-basic
        avantgar
        bookman
        charter
        cm-super
        cmextra
        courier
        ec
        euro
        euro-ce
        eurosym
        fpl
        helvetic
        lm
        lm-math
        marvosym
        mathpazo
        ncntrsbk
        palatino
        pxfonts
        rsfs
        symbol
        tex-gyre
        tex-gyre-math
        times
        tipa
        txfonts
        utopia
        wasy
        wasysym
        zapfchan
        zapfding
Included files, by type:

So now you can decide whether to install the entire collection or selected packages. Alternatively, you can of course request further information about a particular package:

tlmgr info helvetic

which tells me:

package:     helvetic
category:    Package
shortdesc:   URW "Base 35" font pack for LaTeX.
longdesc:    A set of fonts for use as "drop-in" replacements for Adobe's basic set, comprising: - Century Schoolbook (substituting for Adobe's New Century Schoolbook); - Dingbats (substituting for Adobe's Zapf Dingbats); - Nimbus Mono L (substituting for Abobe's Courier); - Nimbus Roman No9 L (substituting for Adobe's Times); - Nimbus Sans L (substituting for Adobe's Helvetica); - Standard Symbols L (substituting for Adobe's Symbol); - URW Bookman; - URW Chancery L Medium Italic (substituting for Adobe's Zapf Chancery); - URW Gothic L Book (substituting for Adobe's Avant Garde); and - URW Palladio L (substituting for Adobe's Palatino).
installed:   Yes
revision:    31835
sizes:       run: 2377k
relocatable: No
cat-date:    2012-06-06 22:57:48 +0200
cat-license: gpl
collection:  collection-fontsrecommended
  • 2
    I installed collection-fontsrecommended and that resolved the issue. BasicTeX (surprisingly) does not include Helvetica(!). Here is the exact command that I used: sudo tlmgr install collection-fontsrecommended. Thanks for your help. – Carl Parker Feb 13 '14 at 21:14
  • 2
    @CarlParker As I understand it, BasicTeX really is intended to be just the essential core of things which you would need pretty much whatever you want to compile. So these fonts are excluded because you can use TeX perfectly well without them. On the other hand, they are recommended because most people will want to install them as they are required for fairly standard tasks. If you have any further problems with missing fonts, check for inclusion in collection-fontsextra though you might prefer to install specific packages in that case since you presumably are short of space. – cfr Feb 13 '14 at 23:19
6

I also have trouble finding the right packages when it comes to fonts. On a Mac I recommend using the GUI program “TeX Live Utility” (TLU):

enter image description here

The search field makes the process (usually) quite simple. The other answers here suggesting tlmgr do provide more options/possibilities than are available with TLU so it's good to be aware of both.

  • 2
    Also, if you learn tlmgr, you know how to manage TL on any platform. My attitude to GUIs is that they are best used when you don't depend on them. That is, if you know your system, go ahead and use a GUI. If not, you will be better served in the end learning about what's going on underneath. (Also, I've never used TLU even when on a Mac so my answer reflected what I know. But there is a reason I eschewed GUI wrappers when using a Mac!) – cfr Feb 13 '14 at 23:23

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.