Sign up ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

I have Mac OS X 10.7.5 and TeX Live 2012, and "XeTeX, Version 3.1415926-2.4-0.9998". How do I install the mcq package?

share|improve this question
What is the mcq package? It is not found on CTAN. –  daleif Dec 29 '13 at 17:20
I think this. –  marczellm Dec 29 '13 at 17:23
Yes that's it. How do I run on Terminal? If I just type it says -bash: command not found, and if I type latex, it says ! You can't use 'macro parameter character #' in vertical mode. l.1 # !/usr/bin/env python And my Mac has no such directory as /Users/michelegorini/Library/texmf which is given by the command kpsewhich -var-value TEXMFHOME. Could it be hidden? How do I show it? –  MickG Dec 29 '13 at 18:00
Does not any answer in Where do I place my own .sty files, to make them available to all my .tex files? help you? Is a font involved? Then see Manual font installation. –  Speravir Dec 30 '13 at 2:31
If it ends with .py, it's probably a python file. Maybe ./ or python –  Stephan Lehmke Dec 30 '13 at 5:29

2 Answers 2

up vote 2 down vote accepted

To download the Linux Libertine font, the link is Be sure to download Libertine and not Biolinum. The rest is done by following the instructions on, bearing in mind that .py is the extension for python files which are run by python on the Terminal. The file is created by that program, then you open it in your TeX editor, put the questions and answers in the designated areas and typeset normally. Be sure to use XeTeX or LuaTeX as plain pdfTeX won't work. The strange thing is I never had to move the .sty file from my Downloads folder, so that kpsewhich -var-value TEXMFHOME command was pretty useless for me. Besides, the result of that was /Users/michelegorini/Library/texmf, which I can't access because it does not show up, neither in the Finder, nor in the Terminal where the Library does show up. The only problem now is that mcq.sty is found only if the .tex file using it is in the Downloads folder.

Update: I stumbled again upon this question while searching for examples to link to from the answer to this meta SX question, and there are two ways to fix this "only" problem:

  1. Find the directory where LaTeX looks for packages (where the packages from the installed distribution are) and put the mcq folder into it, and then go on terminal and use sudo texhash; this isn't tested but it worked when I tried to install my own package.
  2. Place the .sty in the appropriate "local" directory, as indicated here; well, perhaps the indications there are not accurate for your computer; in my case, if ~ is the home directory, they are accurate, but note that my Library was invisible; the Finder has a Go to Library command which becomes visible under the Go menu when pressing the Option key.
share|improve this answer
NO! First: The original source for Linux Libertine is Second: It is already installed or can be so in all big TeX distributions, also in opentype version - the according package is libertine. –  Speravir Dec 30 '13 at 23:40

Just two comments (I wrote

If you create, in the directory /Users/michelegorini/Library/texmf/, a TEXMF tree, there you can install your own packages (or tex files, or image files, or bibtex files... ) - out of the official texlive/* distribution.

Example: /Users/michelegorini/Library/texmf/tex/latex/mcq.sty

texhash might be needed after.

About the proper place where to put, it depends on your $PATH. A typical place might be /usr/local/bin, after making sure that something like export PATH=/usr/local/bin:$PATH is in your ~/.bashrc or ~/.profile . Also, it needs to be executable (check file permissions).

From the "Linux Libertine font" comment I reckon that you could already run it: Linux Libertine is the default font. You can change it to any other font with the proper glyphs (by changing the commands \squarebox, \Ufont, and setting a different \setmainfont), but you should first make sure that there are no missing symbols (check the logfile).

share|improve this answer
A tip: If you indent lines by 4 spaces or enclose words in backticks `, they'll be marked as code, as can be seen in my edit. You can also highlight the code and click the "code" button (with "{}" on it) or use the keystroke <Ctrl> + <K>. –  Speravir Jan 15 '14 at 2:32

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

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