How to use the package manager on Unix-like operating systems

by CSchenk10. August 2005 21:38

MPM (MiKTeX Package Manager) was originally intended to be a tool for MiKTeX/Windows users.  But the program can be helpful for users of other TeX systems too, because many of the MiKTeX packages are system-independent.

Installing the package database

First of all you should install the package database files on your computer. To do this, run

> sudo mpm --update-db

This command retrieves the package database files from a remote package repository and installs them in the installation directory.

To list the contents of the just installed package database, run

> mpm --list

To get datailed information about a package, run

> mpm --print-package-info=PACKAGE

Setting the installation directory

The installation directory is the root of a TDS-compliant TEXMF directectory hierarchy. The location of the installation directory is determined by the configure script.

The --install-root option lets you set the installation directory at run-time. For example, the following command installs the package database files in your home TEXMF:

> sudo mpm --install-root=~/texmf --update-db

Installing and updating packages

Use the --install option to install a package. For example, run

> sudo mpm --install=a0poster

to install the a0poster package.

The --update option can be used to update installed packages. Run

> sudo mpm --update

to update all installed packages. Run

> sudo mpm --update=PACKAGE

to update a certain package.


Comments (6) -

John Wohlbier
John Wohlbier
3/8/2006 1:15:06 AM #

Add a comment that MIKTEK_INSTALLROOT should be set so that
one doesn't have to use --install-root for each command.

Jonathan Underwood
Jonathan Underwood
5/22/2006 11:39:16 PM #

Hello Christian,

This looks like interesting work. I have a question for you:

Most linux distributions have a package management system (eg. rpm) for the entire system, and usually the tetex distribution is installed as a package. As far as I can work out, mpm will short circuit the system package manager by updating components of the texmf tree, overwriting the files installed as part of the tetex package, or adding files which don't get registered with the system package manager.

Of course, the massive advantage of mpm is the fine grained management of individual latex packages, but I wonder if there's a way to integrate it with the system package manager, somehow.


5/23/2006 10:03:11 PM #

MPM will install new packages in the local TeXMF tree, i.e., it will not get into the way of the system package manager. The local TeXMF tree is traditionally reserved for local user additions.

Luca Cerone
Luca Cerone
6/30/2006 11:58:03 AM #

I think it would be useful a GUI for MikTex Tolls in Linux, like the one tha is used under Win. I also have a problem: though some packages result as "already installed" I can't compile my document because they are not recognized... What should I do???

ahmet nurlu
ahmet nurlu
7/19/2006 4:35:37 PM #


I was a user of miktex in Windows . When I switched to Linux(apperently to TeTeX for Latex), ı was shocked that there is no a package manager for TeTeX. Now I am a happy TeTeX user because of  a miktex package manager.

Thanking you Christian Schenk

Ahmet Nurlu

Anthony Tate
Anthony Tate
8/9/2006 3:17:29 AM #

Is there a way to use MPM  under linux from behind a proxy server which requires authentification.

Comments are closed