git.iko.soy/typeable/pandoc
on master help sign in
Updated INSTALL instructions.

git-svn-id: https://pandoc.googlecode.com/svn/trunk@903 788f1e2b-df1e-0410-8736-df70ead52e1b

commit3bdce3cfb8529bb668431aaad8a806320cd6070e authorfiddlosopher <fiddlosopher@788f1e2b-df1e-0410-8736-df70ead52e1b> dateSun 26 Aug 2007, 15:34 (19 years ago) parent670ea95
1 file changed+102−17
INSTALL+102−17
INSTALL+102−17
@@ -1,12 +1,18 @@
11% Installing pandoc
22
3−The following instructions are for installing pandoc from source.
4−Packages are also available for Windows, MacOS X, Linux (Debian and
5−derivatives), and FreeBSD. See the [pandoc home page] for more details.
3+Installing from Source
4+======================
65
7−[pandoc home page]: http://sophos.berkeley.edu/macfarlane/pandoc/
6+This method will work on all architectures, but requires that you first
7+install the GHC compiler and some build tools: [GNU `make`], `sed`,
8+`bash`, and `perl`. These are standard on unix systems (including MacOS
9+X). If you're using Windows, you can install [Cygwin].
810
9−# Installing GHC
11+[Cygwin]: http://www.cygwin.com/
12+[GNU `make`]: http://www.gnu.org/software/make/
13+
14+Installing GHC
15+--------------
1016
1117To compile Pandoc, you'll need [GHC] version 6.6 or greater. If
1218you don't have GHC already, you can get it from the [GHC Download]
@@ -18,14 +24,18 @@ page. If you're running MacOS X, you can also install GHC using
1824[MacPorts]: http://macports.org
1925[Fink]: http://finkproject.org
2026
21−You'll also need standard build tools: [GNU `make`], `sed`, `bash`,
22−and `perl`. These are standard on unix systems (including MacOS
23−X). If you're using Windows, you can install [Cygwin].
27+Getting the source
28+------------------
2429
25−[Cygwin]: http://www.cygwin.com/
26−[GNU `make`]: http://www.gnu.org/software/make/
30+Download the source tarball from pandoc's [pandoc's google code site].
31+Extract the contents into a subdirectory:
32+
33+ tar xvzf pandoc-0.xy.tar.gz
2734
28−# Installing Pandoc
35+[pandoc's google code site]: http://pandoc.googlecode.com
36+
37+Installing Pandoc
38+-----------------
2939
30401. Change to the directory containing the Pandoc distribution.
3141
@@ -76,7 +86,8 @@ X). If you're using Windows, you can install [Cygwin].
7686
7787[haddock]: http://www.haskell.org/haddock/
7888
79−# Removing Pandoc
89+Removing Pandoc
90+---------------
8091
8192Each of the installation steps described above can be reversed:
8293
@@ -86,12 +97,13 @@ Each of the installation steps described above can be reversed:
8697
8798 sudo make uninstall-all
8899
89−# Other targets
100+Other targets
101+-------------
90102
91103The following 'make' targets should not be needed by the average user,
92104but are documented here for packagers and developers:
93105
94−## Building and installing
106+### Building and installing
95107
96108* `configure`: Performs the needed preprocessing to create a proper
97109 Cabal package for Pandoc:
@@ -113,18 +125,18 @@ but are documented here for packagers and developers:
113125* `install-exec`, `uninstall-exec`: Installs/uninstalls programs
114126 (`pandoc` and wrappers).
115127
116−## Testing
128+### Testing
117129
118130* `test`: Runs Pandoc's test suite. (All tests should pass.)
119131* `test-markdown`: Runs the Markdown regression test suite, using
120132 `pandoc --strict`. (Three of the tests will fail.)
121133
122−## Cleaning
134+### Cleaning
123135
124136* `clean`: Restores directory to pre-build state, removing generated files.
125137* `distclean`: Like clean, but also cleans up files created by `make deb`.
126138
127−## Packaging
139+### Packaging
128140
129141* `tarball`: Creates a source tarball for distribution.
130142* `deb`: Creates debian packages in `..` directory.
@@ -139,3 +151,76 @@ but are documented here for packagers and developers:
139151 which must be created by building Pandoc on a Windows machine).
140152* `website`: Creates Pandoc's website in `web/pandoc` directory.
141153
154+Installing pandoc using MacPorts
155+================================
156+
157+This is an alternative to compiling from source on MacOS X.
158+[MacPorts] is a system for building and maintaining \*nix software
159+on MacOS X computers. If you don't already have MacPorts, follow
160+[these instructions for installing
161+it](http://trac.macosforge.org/projects/macports/wiki/InstallingMacPorts).
162+Note that you'll need OSX 10.4 and the latest version of XCode Tools.
163+
164+Once you've installed MacPorts, you'll need to create a local ports
165+repository and copy the [pandoc `Portfile`](Portfile) into it:
166+
167+ mkdir -p ~/ports/textproc/pandoc
168+ cp Portfile ~/ports/textproc/pandoc/
169+
170+Then (as root) open `/opt/local/etc/macports/sources.conf` in an editor
171+and insert the line
172+
173+ file:///Users/yourusername/ports
174+
175+before the line beginning `rsync:`, so MacPorts will know about your
176+local repository.
177+
178+Now you should be able to install pandoc by typing
179+
180+ sudo port install pandoc
181+
182+Since pandoc requires GHC to build, the process may take a long time.
183+
184+Installing the Windows binary
185+=============================
186+
187+Simply download the zip file from [pandoc's google code site].
188+Extract the files from the archive, and put `pandoc.exe` somewhere
189+in your PATH.
190+
191+Note that the Windows binary distribution does not include the shell
192+scripts `markdown2pdf`, `html2markdown`, or `hsmarkdown`. If you need
193+these, compile from source.
194+
195+Installing pandoc on Debian
196+===========================
197+
198+This method will work on Debian linux and derivatives (including Ubuntu).
199+Download the latest debian package from the [pandoc home page].
200+To install it, just type
201+
202+ sudo dpkg -i pandoc_0.xx_i386.deb
203+
204+where `pandoc_0.xx_i386.deb` is the filename of the debian package.
205+To uninstall later, use
206+
207+ sudo apt-get remove pandoc
208+
209+[pandoc home page]: http://sophos.berkeley.edu/macfarlane/pandoc/
210+
211+Installing pandoc on FreeBSD
212+============================
213+
214+Pandoc is in the FreeBSD ports repository (`textproc/pandoc`) and can be
215+installed in the normal way:
216+
217+ cd /usr/ports/textproc/pandoc
218+ make install clean # as root
219+
220+Alternatively, you can use `pkg_add`:
221+
222+ pkg_add -r pandoc
223+
224+Note that the version of pandoc in FreeBSD's official repository may be
225+somewhat older than the most recent version.
226+