1.2.6 Installation for non-privileged users
Often people without system administration privileges want to install software for their private use. In that case you need to pass more options to the configure
script.
The main expedient is using the β--prefix
β option to the βconfigure
β script, and let it point to the personal home directory. In that way, resulting binaries will be installed under the βbin
β subdirectory of your home directory, manual pages under βman
β and so on. It is reasonably easy to maintain a bunch of personal software, since the prefix argument is supported by most βconfigure
β scripts.
You often need to specify β--with-lispdir
β option as well. If you havenβt installed Emacs under your home directory and use Emacs installed in system directories, the βconfigure
β script might not be able to figure out suitable place to install lisp files under your home directory. In that case, the βconfigure
β script would silently choose, by default, the βsite-lisp
β directory within βload-path
β for the place, where administration privileges are usually required to put relevant files. Thus you will have to tell the βconfigure
β script explicitly where to put those files by, e.g., β--with-lispdir=β/home/myself/share/emacs/site-lispβ
β.
Youβll have to add something like β/home/myself/share/emacs/site-lisp
β to your load-path
variable, if it isnβt there already.
In addition, you will have to tell βconfigure
β script where to install TeX-related files such as βpreview.sty
β if preview-latex isnβt disabled. It is enough to specify β--with-texmf-dir=β$HOME/texmfβ
β for most typical cases, but you have to create the direcotry β$HOME/texmf
β in advance if it doesnβt exist. If this prescription doesnβt work, consider using one or more of the options β--with-texmf-dir=/dir
β, β--without-texmf-dir
β, β--with-tex-dir=/dir
β and β--with-doc-dir=/dir
β. See Configure for detail of these options.
Now here is another thing to ponder: perhaps you want to make it easy for other users to share parts of your personal Emacs configuration. In general, you can do this by writing β~myself/
β anywhere where you specify paths to something installed in your personal subdirectories, not merely β~/
β, since the latter, when used by other users, will point to non-existent files.
For yourself, it will do to manipulate environment variables in your β.profile
β resp. β.login
β files. But if people will be copying just Elisp files, their copies will not work. While it would in general be preferable if the added components where available from a shell level, too (like when you call the standalone info reader, or try using βpreview.sty
β for functionality besides of Emacs previews), it will be a big help already if things work from inside of Emacs.
Here is how to do the various parts:
Making the Elisp availableβ
In GNU Emacs, it should be sufficient if people just do
(load "~myself/share/emacs/site-lisp/auctex.el" nil t t) (load "~myself/share/emacs/site-lisp/preview-latex.el" nil t t)
where the path points to your personal installation. The rest of the package should be found relative from there without further ado.
Making the Info files availableβ
For making the info files accessible from within Elisp, something like the following might be convenient to add into your or other peopleβs startup files:
(eval-after-load 'info '(add-to-list 'Info-directory-list "~myself/info"))
Making the LaTeX style availableβ
If you want others to be able to share your installation, you should configure it using β--without-texmf-dir
β, in which case things should work as well for them as for you.