]> git.ipfire.org Git - thirdparty/ccache.git/commitdiff
Split installation instructions into from-repo and from-archive cases
authorJoel Rosdahl <joel@rosdahl.net>
Sat, 27 Aug 2016 07:55:53 +0000 (09:55 +0200)
committerJoel Rosdahl <joel@rosdahl.net>
Sat, 27 Aug 2016 14:09:06 +0000 (16:09 +0200)
See discussion in #125.

INSTALL-from-release-archive.md [new file with mode: 0644]
INSTALL.md
dev.mk.in

diff --git a/INSTALL-from-release-archive.md b/INSTALL-from-release-archive.md
new file mode 100644 (file)
index 0000000..98b7059
--- /dev/null
@@ -0,0 +1,51 @@
+ccache installation
+===================
+
+Prerequisites
+-------------
+
+To build ccache, you need:
+
+- A C compiler (for instance GCC)
+
+It is also recommended that you have:
+
+- [zlib](http://www.zlib.net) (if you don't have zlib installed, ccache will
+  use a bundled copy)
+
+
+Installation
+------------
+
+To compile and install ccache, run these commands:
+
+    ./configure
+    make
+    make install
+
+You may set the installation directory and other parameters by options to
+`./configure`. To see them, run `./configure --help`.
+
+There are two ways to use ccache. You can either prefix your compilation
+commands with `ccache` or you can create a symbolic link (named as your
+compiler) to ccache. The first method is most convenient if you just want to
+try out ccache or wish to use it for some specific projects. The second method
+is most useful for when you wish to use ccache for all your compilations.
+
+To install for usage by the first method just copy ccache to somewhere in your
+path.s
+
+To install for the second method, do something like this:
+
+    cp ccache /usr/local/bin/
+    ln -s ccache /usr/local/bin/gcc
+    ln -s ccache /usr/local/bin/g++
+    ln -s ccache /usr/local/bin/cc
+    ln -s ccache /usr/local/bin/c++
+
+And so forth. This will work as long as `/usr/local/bin` comes before the path
+to the compiler (which is usually in `/usr/bin`). After installing you may wish
+to run `which gcc` to make sure that the correct link is being used.
+
+NOTE: Do not use a hard link, use a symbolic link. A hard link will cause
+"interesting" problems.
index de7d5aadb903de762feeafc09e5e8e45e956881a..a860eaa7ed7aff17c7f250c6fa3dba77fbc88fef 100644 (file)
@@ -1,26 +1,33 @@
 ccache installation
 ===================
 
+Prerequisites
+-------------
 
-Building code from a release archive
-------------------------------------
-
-### Prerequisites
-
-To build ccache, you need:
+To build ccache from the source repository, you need:
 
 - A C compiler (for instance GCC)
+- [AsciiDoc](http://www.methods.co.nz/asciidoc/) to build the documentation.
+- [Autoconf](http://www.gnu.org/software/autoconf/)
+- [gperf](http://www.gnu.org/software/gperf/)
+- [xsltproc](http://xmlsoft.org/XSLT/xsltproc2.html)
 
 It is also recommended that you have:
 
 - [zlib](http://www.zlib.net) (if you don't have zlib installed, ccache will
   use a bundled copy)
 
+To debug and run the performance test suite you'll also need:
+
+- [Python](http://www.python.org)
 
-### Installation
+
+Installation
+------------
 
 To compile and install ccache, run these commands:
 
+    ./autogen.sh
     ./configure
     make
     make install
@@ -51,21 +58,3 @@ to run `which gcc` to make sure that the correct link is being used.
 
 NOTE: Do not use a hard link, use a symbolic link. A hard link will cause
 "interesting" problems.
-
-
-Building code from the source code repository
----------------------------------------------
-
-In addition to the prerequisites mentioned above, you also need:
-
-- [AsciiDoc](http://www.methods.co.nz/asciidoc/) to build the documentation.
-- [Autoconf](http://www.gnu.org/software/autoconf/)
-- [gperf](http://www.gnu.org/software/gperf/)
-- [xsltproc](http://xmlsoft.org/XSLT/xsltproc2.html)
-
-To debug and run the performance test suite you'll also need:
-
-- [Python](http://www.python.org)
-
-Run `./autogen.sh` and then follow the steps mentioned under "Installation"
-above.
index c6331729c885668721a52d569bc45138a3ff089d..d141b78509f5d44c2a223d97d4016d096ee29332 100644 (file)
--- a/dev.mk.in
+++ b/dev.mk.in
@@ -59,7 +59,6 @@ source_dist_files = \
     AUTHORS.txt \
     GPL-3.0.txt \
     HACKING.txt \
-    INSTALL.md \
     LICENSE.txt \
     MANUAL.txt \
     Makefile.in \
@@ -111,6 +110,7 @@ $(dist_archives): $(dist_files)
        mkdir $$dir && \
        (cd $(srcdir) && \
         rsync -r --relative $(source_dist_files) $$dir) && \
+       cp $(srcdir)/INSTALL-from-release-archive.md $$dir/INSTALL.md && \
        cp $(built_dist_files) $$dir && \
        echo "Remove this file to enable developer mode." >$$dir/dev_mode_disabled && \
        (cd $$tmpdir && \