git-gui: Created makefile to install the program.
[git/git.git] / Makefile
CommitLineData
b3678bac
SP
1all: git-gui
2
3gitexecdir := $(shell git --exec-path)
4INSTALL = install
5
6DESTDIR_SQ = $(subst ','\'',$(DESTDIR))
7gitexecdir_SQ = $(subst ','\'',$(gitexecdir))
8
9GITGUI_BUILTIN = git-citool
10
11install: all
12 $(INSTALL) -d -m755 '$(DESTDIR_SQ)$(gitexecdir_SQ)'
13 $(INSTALL) git-gui '$(DESTDIR_SQ)$(gitexecdir_SQ)'
14 $(foreach p,$(GITGUI_BUILTIN), rm -f '$(DESTDIR_SQ)$(gitexecdir_SQ)/$p' && ln '$(DESTDIR_SQ)$(gitexecdir_SQ)/git-gui' '$(DESTDIR_SQ)$(gitexecdir_SQ)/$p' ;)