builtin/apply: move 'state' init into init_apply_state()
[git/gitweb.git] / wrap-for-bin.sh
blobdb0ec6a7370fd56e4e11c49a4b9e5e15f461e1f9
1 #!/bin/sh
3 # wrap-for-bin.sh: Template for git executable wrapper scripts
4 # to run test suite against sandbox, but with only bindir-installed
5 # executables in PATH. The Makefile copies this into various
6 # files in bin-wrappers, substituting
7 # @@BUILD_DIR@@ and @@PROG@@.
9 GIT_EXEC_PATH='@@BUILD_DIR@@'
10 if test -n "$NO_SET_GIT_TEMPLATE_DIR"
11 then
12 unset GIT_TEMPLATE_DIR
13 else
14 GIT_TEMPLATE_DIR='@@BUILD_DIR@@/templates/blt'
15 export GIT_TEMPLATE_DIR
17 GITPERLLIB='@@BUILD_DIR@@/perl/blib/lib'"${GITPERLLIB:+:$GITPERLLIB}"
18 GIT_TEXTDOMAINDIR='@@BUILD_DIR@@/po/build/locale'
19 PATH='@@BUILD_DIR@@/bin-wrappers:'"$PATH"
20 export GIT_EXEC_PATH GITPERLLIB PATH GIT_TEXTDOMAINDIR
22 if test -n "$GIT_TEST_GDB"
23 then
24 unset GIT_TEST_GDB
25 exec gdb --args "${GIT_EXEC_PATH}/@@PROG@@" "$@"
26 else
27 exec "${GIT_EXEC_PATH}/@@PROG@@" "$@"