--- Makefile.orig~ 2017-03-13 02:27:26.000000000 -0600 +++ Makefile 2017-03-14 09:49:40.000000000 -0600 @@ -1,5 +1,5 @@ -gitexecdir = ${shell git --exec-path} -gitmanpath = ${shell git --man-path} +gitexecdir = (destroot)${shell (prefix)/bin/git --exec-path} +gitmanpath = (destroot)${shell (prefix)/bin/git --man-path} -include ./config.mak @@ -8,8 +8,7 @@ endif BASH_PATH_SQ = $(subst ','\'',$(BASH_PATH)) -GIT_LATEXDIFF_VERSION=${shell git describe --tags HEAD 2>/dev/null || \ - echo unknown-version} +GIT_LATEXDIFF_VERSION=v(version) gitexecdir_SQ = $(subst ','\'',$(gitexecdir)) gitmanpath_SQ = $(subst ','\'',$(gitmanpath)) @@ -31,6 +30,7 @@ install: install-bin install-doc install-bin: + mkdir -p ${gitexecdir} sed -e '1s|#!.*/bash|#!$(BASH_PATH_SQ)|' \ -e 's|@GIT_LATEXDIFF_VERSION@|$(GIT_LATEXDIFF_VERSION)|' \ $(SCRIPT) > '$(gitexecdir_SQ)/$(SCRIPT)'