Adding a CTAN package to a MacPorts-maintained TeX installation
Your question is a good one, but reveals one of the fundamental flaws in the way Linux-like (and I include here MacPorts) package management systems work when it comes to TeX distributions. The problem is that packages (in the TeX sense) are qualitatively different from packages in the Linux sense, but the Linux packagers don't seem to recognize the distinction, and so you are left with a situation in which if you use a Linux-based distribution of TeX, you are usually left with no simple way to update the TeX packages.
The qualitative difference between a TeX package and a regular software package is that TeX packages are simple text files which are not compiled and in fact not executable. A regular software package, on the other hand is usually a compiled piece of software or a bunch of scripts. Now of course in a TeX distribution as a whole, there are definitely compiled binaries and scripts, but these are not the pieces that are updated so frequently as TeX packages since, generally they are updated only once a year anyway. But new TeX packages and updates to existing ones happen all the time, and TeXLive (and MikTeX) users have constant access to these updates.
So an ideal Linux-based package would install only the TeX binaries and support software, including tlmgr
and then allow tlmgr
to deal with the installation of the TeX packages, rather than have the Linux package manager do this. However, for reasons that are not entirely clear to me, this is not the route that Linux based systems have taken (thus leading to many outdated TeX distributions; Ubuntu is a known culprit in this respect.) Since this is not the case, most experienced TeX users install their own version of TeXLive and bypass the package manager; (see How to install "vanilla" TeXLive on Debian or Ubuntu?) similarly Mac users use the MacTeX distribution.
MacPorts does seem to be keeping up-to-date, but unless it recognizes the "TeX-package" vs. "Linux-package" distinction and actually installs tlmgr
I don't think there is a way to answer your question 2.2.
There is one possibility, I suppose: install both the MacPorts version and MacTeX and then make sure the TeX packages in /usr/local/texlive
are found even if the MacPorts binaries are used.
Option 2
2.1: Go to packages.ubuntu.com, look for "Search the contents of packages", enter lipsum.sty
and press search.
The result:
2.2: sudo port install texlive-latex-extra
I used to hate MacPorts for its limited search capabilites until I figured out that in 99 percent of all cases the MacPorts packages are named identically to the respective Ubuntu packages. This does not only hold if one looks for LaTeX stuff, but basically anything: Someone recommended pdfnup
to generate slide handouts and you want to get that for your Mac? Just enter it in "Search the contests of packages" and you will figure out that the MacPorts package to install is pdfjam
.
lipsum
is part of the package texlive-latex-extra
. You can install by
sudo port install texlive-latex-extra
You can find the package that you need by indexing the name in https://trac.macports.org/wiki/TeXLivePackages