This is an old revision of the document!
Overview
How to clone, build and install Git as a non-root user.
The recipe
Clone:
$ git clone https://github.com/git/git.git
Configure for personal destination directory:
$ make configure $ ./configure --prefix=/home/rpjday/newgit
Build and install:
$ make all install $ make doc install-doc install-html
The end results
All installed under your home directory:
- bin/
- git
- git-cvsserver
- gitk
- git-receive-pack
- git-shell
- git-upload-archive
- git-upload-pack
- libexec/
- git-core/
- … LOTS here …
- share/
- git-core/
- templates/
- git-gui/
- gitk/
- gitweb/
Finally:
PATH=~/bin:$PATH
and away you go.
Documentation
.PHONY: doc man man-perl html info pdf
doc: man-perl
$(MAKE) -C Documentation all
man: man-perl
$(MAKE) -C Documentation man
man-perl: perl/build/man/man3/Git.3pm
html:
$(MAKE) -C Documentation html
info:
$(MAKE) -C Documentation info
pdf:
$(MAKE) -C Documentation pdf