Fixing guile 2.2 compatibility
[geiser.git] / doc / install.texi
blobd88a22b52d0207932c74654966ee02a0f95f1caf
1 @node Installation, The REPL, Introduction, Top
2 @chapter Installation
4 @menu
5 * Must needs::
6 * The easy and quick way::
7 * From the source's mouth::
8 * Friends::
9 @end menu
11 @node Must needs, The easy and quick way, Installation, Installation
12 @section Must needs
14 @cindex supported versions
15 @cindex versions supported
16 If Geiser came with any guarantees, you'd break all of them by not using
17 GNU Emacs @value{EMACS_VERSION} (or better: i regularly use it with a
18 recent Emacs snapshot) and at least one of the supported Schemes,
19 namely:
21 @itemize @bullet
22 @item
23 @uref{http://www.racket-lang.org, Racket} @value{RACKET_VERSION} or better
24 @item
25 @uref{http://www.gnu.org/software/guile, Guile} @value{GUILE_VERSION} or
26 better
27 @item
28 @uref{http://call-cc.org, Chicken} @value{CHICKEN_VERSION} or better
29 @end itemize
31 Since Geiser supports multiple REPLs, having both of them will just add
32 to the fun.
34 You'll also need Geiser itself.  The quickest installation is via its
35 ELPA package, as described in the next section.  If you prefer to use
36 the source code directly, it's not that difficult either: just keep on
37 reading.
39 @node The easy and quick way, From the source's mouth, Must needs, Installation
40 @section The easy and quick way
42 @cindex quick install
43 @cindex ELPA
44 Did i mention that the easiest way of installing Geiser is using its
45 @uref{http://emacswiki.org/emacs/ELPA, ELPA} package?  If you're using
46 Emacs 24, @uref{http://emacswiki.org/emacs/ELPA, ELPA} is already there;
47 for earlier versions, the page i just linked to twice will tell you
48 where to find the goodies.
50 ELPA packages live in repositories accessible via HTTP.  You can find
51 Geiser's package in either
52 @uref{http://melpa-stable.org/#/geiser, MELPA stable} or, if you
53 like living on the bleeding edge,
54 @uref{http://melpa.org/#/geiser, MELPA} (directly from the git
55 repo).  To tell Emacs that an ELPA repo exists, you add it to
56 @code{package-archives}:
58 @example
59 (require 'package)
60 ;;; either the stable version:
62 (add-to-list 'package-archives
63   ;; choose either the stable or the latest git version:
64   ;; '("melpa-stable" . "http://melpa-stable.org/packages/")
65   '("melpa-unstable" . "http://melpa.org/packages/"))
67 (package-initialize)
68 @end example
70 And then installing Geiser is as easy as:
72 @example
73 M-x package-install RET geiser RET
74 @end example
76 Alternatively, you can manually download the @uref{@value{PACKAGE},
77 package file}, and install from your local disk with @kbd{M-x
78 package-install-file}.
80 @cindex Chicken
81 @cindex Chicken installation
82 If you plan to use Chicken, you'll need also to fire a terminal and
83 configure a couple of Chicken eggs:
84 @example
85 $ chicken-install -s apropos chicken-doc
86 $ cd `csi -p '(chicken-home)'`
87 $ curl http://3e8.org/pub/chicken-doc/chicken-doc-repo.tgz | sudo tar zx
88 @end example
90 With that, you are pretty much all set up.  See @ref{The REPL} to start
91 using Geiser.
93 @ifnotinfo
94 And, by the way, if you prefer to keep reading this manual within Emacs,
95 @kbd{C-h i m Geiser RET} will bring you to the info version of it that
96 you just installed!
97 @end ifnotinfo
99 @node From the source's mouth, Friends, The easy and quick way, Installation
100 @section Installing from source
102 @subsubheading Downloading Geiser
104 @cindex use the source, Luke
105 The latest release tarball can be found @downfile{, here}.  Just
106 download @downfile{@value{TARBALL}, @value{TARBALL}} and untar it in a
107 directory of your choice.
109 If you feel like living on the bleeding edge, just grab Geiser from its
110 Git repository @uref{http://git.savannah.nongnu.org/cgit/geiser.git/, over
111 at Savannah}, either with the following incantation:
113 @example
114 git clone git://git.sv.gnu.org/geiser.git
115 @end example
117 @noindent or, if you happen to live behind a firewall, with the alternative:
119 @example
120 git clone http://git.sv.gnu.org/r/geiser.git
121 @end example
123 @noindent
124 You can also follow Geiser's development in
125 @uref{https://github.com/jaor/geiser, one}
126 @uref{http://repo.or.cz/w/geiser.git, or}
127 @uref{http://gitorious.org/geiser, three} mirrors that are kept
128 synchronized with the one at Savannah.
130 Either way, you'll now be in possession of a copy of Geiser's libre
131 code.  I'll follow you into its directory and the next section.
133 @subsubheading Setting it up
135 Geiser is ready to be used out of the box without much more ado.  For the
136 sake of concreteness, let's assume you put its source in the directory
137 @file{~/lisp/geiser}.  All you need to do is to add the following
138 line to your Emacs initialisation file (be it @file{~/.emacs} or any of
139 its moral equivalents):
141 @example
142 (load-file "~/lisp/geiser/elisp/geiser.el")
143 @end example
145 @noindent
146 or simply evaluate that form inside Emacs (you wouldn't kill a friend
147 just to start using Geiser, would you?).  That's it: you're ready to
148 @ifhtml
149 @ref{quick-start,,go}.
150 @end ifhtml
151 @ifnothtml
152 go (@pxref{The REPL}).
153 @end ifnothtml
155 @ifnotinfo
156 If you obtained the Geiser source tree from a release tarball, you can
157 even continue to read this fine manual inside Emacs by opening
158 @file{doc/geiser.info} using @kbd{C-u C-h i}.  The manual is also
159 available in PDF format @downfile{geiser-manual-@value{VERSION}.pdf,
160 here}.
161 @end ifnotinfo
163 @cindex byte-compilation
164 What?  You still here?  I promise the above is all that's needed to start
165 using Geiser.  But, in case you are missing your @t{configure/make all
166 install} routine, by all means, you can go through those motions to byte
167 compile and install Geiser too.  That is, you enter the source directory
168 and (since we grabbed the development tree) run the customary
169 @i{autogen} script:
171 @example
172 $ cd ~/lisp/geiser
173 $ ./autogen.sh
174 @end example
176 @noindent
177 I recommend that you compile Geiser in a separate directory:
179 @example
180 $ mkdir build && cd build
181 $ ../configure
182 <some drivel here>
183 $ make all
184 <more of the above>
185 @end example
187 Now you have two options: loading the byte-compiled Geiser from the
188 @file{elisp} subdirectory, or installing it system-wide.  To load the
189 byte-code from here, add this line to your initialisation file:
191 @example
192 (load "~/lisp/geiser/build/elisp/geiser-load")
193 @end example
195 @noindent
196 and eval that form and you're done (you could also restart Emacs, but
197 killing your friends is widely considered bad form).  Yes, that's
198 @code{load} and @file{geiser-load} instead of @code{load-file} and
199 @file{geiser.el}.
201 If you prefer a system-wide installation, just type:
203 @example
204 $ sudo make install
205 @end example
207 With the above spell, Geiser will be compiled and installed in a safe
208 place inside Emacs load path.  To load it into Emacs you'll need,
209 @i{instead} of the @code{load-file} form above, the following line in
210 your initialisation file:
212 @example
213 (require 'geiser-install)
214 @end example
216 @noindent
217 Please note that we're requiring @code{geiser-install}, and @i{not}
218 @code{geiser}, and that there's no @code{load-file} to be seen this
219 time.  There are some ways of fine-tuning this process, mainly by
220 providing additional arguments in the call to @t{configure}: you'll find
221 those gory details in the file called @file{INSTALL}, right at the root
222 of the source tree.  The installation will also take care of placing this
223 manual, in Info format, where Emacs can find it, so you can continue to
224 learn about Geiser inside its natural habitat.  See you there and into
225 the next chapter!
227 @node Friends,  , From the source's mouth, Installation
228 @section Friends
230 Although Geiser does not need them, it plays well with (and is enhanced
231 by) the following Emacs packages:
233 @cindex ac-geiser
234 @cindex autocomplete
235 @cindex paredit
236 @cindex company
237 @cindex quack
238 @itemize @bullet
239 @item @uref{http://www.emacswiki.org/emacs/ParEdit, Paredit}.
240 @anchor{paredit}
241 Regardless of whether you use Geiser or not, you shouldn't be coding
242 in any Lisp dialect without the aid of Taylor Campbell's structured
243 editing mode.
244 @item @uref{http://company-mode.github.io/, Company}.
245 Nikolaj Schumacher's and Dmitry Gutov's @code{company-mode} provides a
246 generic front-end for completion engines (such as Geiser's), with pretty
247 and automatic completion lists.
248 @item @uref{https://github.com/xiaohanyu/ac-geiser/, ac-geiser}
249 If you prefer @code{auto-complete-mode} to @code{company-mode}, Xiao
250 Hanyu's @code{ac-geiser}, which provides a Geiser plugin for the
251 popular @uref{http://cx4a.org/software/auto-complete/, Emacs Auto
252 Completion Mode}, is the package for you.  Like Geiser,
253 @code{ac-geiser} is available in Marmalade and MELPA, and also as an
254 @code{el-get} package.
255 @item @uref{http://www.neilvandyke.org/quack/, Quack}.
256 You can still use the many goodies provided by Neil van Dyke's
257 @code{quack-mode}, since most of them are not (yet) available in Geiser.
258 The only caveat might be a conflict between Quack's and Geiser's default
259 key bindings, which i'm sure you'll manage to tackle just fine.  It's
260 also probably a good idea to require @code{quack} @i{after} loading
261 @file{geiser.el} (or requiring a compiled version).
262 @end itemize
264 @noindent
265 You just need to install and setup them as usual, for every package's
266 definition of usual.  Geiser will notice their presence and react
267 accordingly.
269 @c Local Variables:
270 @c mode: texinfo
271 @c TeX-master: "geiser"
272 @c End: