* [PATCH 1/6] Move computation of absolute paths from Makefile to runtime and compute prefix on the fly if RUNTIME_PREFIX set
@ 2009-01-10 13:50 Steffen Prohaska
2009-01-10 13:50 ` [PATCH 2/6] Refactor git_set_argv0_path() to git_extract_argv0_path() Steffen Prohaska
2009-01-13 19:43 ` [PATCH 1/6] Move computation of absolute paths from Makefile to runtime and compute prefix on the fly if RUNTIME_PREFIX set Johannes Sixt
0 siblings, 2 replies; 16+ messages in thread
From: Steffen Prohaska @ 2009-01-10 13:50 UTC (permalink / raw)
To: Junio C Hamano; +Cc: git, Johannes Schindelin, Johannes Sixt, Steffen Prohaska
This is the first commit of a series that adds support for
relocatable binaries (called RUNTIME_PREFIX). Such binaries can be
moved together with the system configuration files to a different
directory, as long as the relative paths from the binary to the
configuration files is preserved. This functionality is essential
on Windows where we deliver git binaries with an installer that
allows to freely choose the installation location. The commit
series implements RUNTIME_PREFIX only on Windows. Adding support
on Unix should not be too hard, though.
This first commits makes all paths relative in the Makefile and
teaches system_path() to add the prefix instead. We used to
compute absolute paths in the Makefile and passed them to C as
defines. We now pass relative paths to C and call system_path() to
add the prefix at runtime.
If RUNTIME_PREFIX is unset we use the static prefix. This will be
the default on Unix. Thus, the behavior on Unix will stay
identical to the old implementation, which added the prefix in the
Makefile.
If RUNTIME_PREFIX is set the prefix is computed from the location
of the executable. In this case, system_path() tries to strip
known directories that executables can be located in from the path
of the executable. If the path is successfully stripped it is used
as the prefix. For example, if the executable is
"/msysgit/bin/git" and BINDIR is "bin", then the prefix computed is
"/msysgit".
If the runtime prefix computation fails, we fall back to the static
prefix specified in the makefile. This can be the case if the
executable is not installed at a known location. Note that our
test system sets GIT_CONFIG_NOSYSTEM to tell git to ignore global
configuration files during testing. Hence testing does not trigger
the fall back.
Note that the implementation requires argv0_path to be set to an
absolute path, which is currently the case only on Windows.
argv0_path must point to the directory of the executable. We use
assert() to verify this in debug builds. On Windows, the wrapper
for main() (see compat/mingw.h) guarantees that argv0_path is
correctly initialized. On Unix, further work is required before
RUNTIME_PREFIX can be enabled.
Signed-off-by: Steffen Prohaska <prohaska@zib.de>
---
Makefile | 45 +++++++++++++++++++++++++++++----------------
builtin-help.c | 4 ++--
exec_cmd.c | 54 ++++++++++++++++++++++++++++++++++++++++++++++++++----
3 files changed, 81 insertions(+), 22 deletions(-)
diff --git a/Makefile b/Makefile
index dee97c1..a7728a3 100644
--- a/Makefile
+++ b/Makefile
@@ -179,28 +179,32 @@ STRIP ?= strip
# Among the variables below, these:
# gitexecdir
# template_dir
+# mandir
+# infodir
# htmldir
# ETC_GITCONFIG (but not sysconfdir)
-# can be specified as a relative path ../some/where/else (which must begin
-# with ../); this is interpreted as relative to $(bindir) and "git" at
+# can be specified as a relative path some/where/else;
+# this is interpreted as relative to $(prefix) and "git" at
# runtime figures out where they are based on the path to the executable.
# This can help installing the suite in a relocatable way.
prefix = $(HOME)
-bindir = $(prefix)/bin
-mandir = $(prefix)/share/man
-infodir = $(prefix)/share/info
-gitexecdir = $(prefix)/libexec/git-core
+bindir_relative = bin
+bindir = $(prefix)/$(bindir_relative)
+mandir = share/man
+infodir = share/info
+gitexecdir = libexec/git-core
sharedir = $(prefix)/share
-template_dir = $(sharedir)/git-core/templates
-htmldir=$(sharedir)/doc/git-doc
+template_dir = share/git-core/templates
+htmldir = share/doc/git-doc
ifeq ($(prefix),/usr)
sysconfdir = /etc
+ETC_GITCONFIG = $(sysconfdir)/gitconfig
else
sysconfdir = $(prefix)/etc
+ETC_GITCONFIG = etc/gitconfig
endif
lib = lib
-ETC_GITCONFIG = $(sysconfdir)/gitconfig
# DESTDIR=
# default configuration for gitweb
@@ -1027,6 +1031,9 @@ ifdef INTERNAL_QSORT
COMPAT_CFLAGS += -DINTERNAL_QSORT
COMPAT_OBJS += compat/qsort.o
endif
+ifdef RUNTIME_PREFIX
+ COMPAT_CFLAGS += -DRUNTIME_PREFIX
+endif
ifdef NO_PTHREADS
THREADED_DELTA_SEARCH =
@@ -1086,6 +1093,7 @@ ETC_GITCONFIG_SQ = $(subst ','\'',$(ETC_GITCONFIG))
DESTDIR_SQ = $(subst ','\'',$(DESTDIR))
bindir_SQ = $(subst ','\'',$(bindir))
+bindir_relative_SQ = $(subst ','\'',$(bindir_relative))
mandir_SQ = $(subst ','\'',$(mandir))
infodir_SQ = $(subst ','\'',$(infodir))
gitexecdir_SQ = $(subst ','\'',$(gitexecdir))
@@ -1251,7 +1259,12 @@ git.o git.spec \
$(QUIET_CC)$(CC) -o $*.o -c $(ALL_CFLAGS) $<
exec_cmd.o: exec_cmd.c GIT-CFLAGS
- $(QUIET_CC)$(CC) -o $*.o -c $(ALL_CFLAGS) '-DGIT_EXEC_PATH="$(gitexecdir_SQ)"' $<
+ $(QUIET_CC)$(CC) -o $*.o -c $(ALL_CFLAGS) \
+ '-DGIT_EXEC_PATH="$(gitexecdir_SQ)"' \
+ '-DBINDIR="$(bindir_relative_SQ)"' \
+ '-DPREFIX="$(prefix_SQ)"' \
+ $<
+
builtin-init-db.o: builtin-init-db.c GIT-CFLAGS
$(QUIET_CC)$(CC) -o $*.o -c $(ALL_CFLAGS) -DDEFAULT_GIT_TEMPLATE_DIR='"$(template_dir_SQ)"' $<
@@ -1400,17 +1413,17 @@ remove-dashes:
### Installation rules
-ifeq ($(firstword $(subst /, ,$(template_dir))),..)
-template_instdir = $(bindir)/$(template_dir)
-else
+ifeq ($(abspath $(template_dir)),$(template_dir))
template_instdir = $(template_dir)
+else
+template_instdir = $(prefix)/$(template_dir)
endif
export template_instdir
-ifeq ($(firstword $(subst /, ,$(gitexecdir))),..)
-gitexec_instdir = $(bindir)/$(gitexecdir)
-else
+ifeq ($(abspath $(gitexecdir)),$(gitexecdir))
gitexec_instdir = $(gitexecdir)
+else
+gitexec_instdir = $(prefix)/$(gitexecdir)
endif
gitexec_instdir_SQ = $(subst ','\'',$(gitexec_instdir))
export gitexec_instdir
diff --git a/builtin-help.c b/builtin-help.c
index f076efa..9b57a74 100644
--- a/builtin-help.c
+++ b/builtin-help.c
@@ -329,7 +329,7 @@ static void setup_man_path(void)
* old_path, the ':' at the end will let 'man' to try
* system-wide paths after ours to find the manual page. If
* there is old_path, we need ':' as delimiter. */
- strbuf_addstr(&new_path, GIT_MAN_PATH);
+ strbuf_addstr(&new_path, system_path(GIT_MAN_PATH));
strbuf_addch(&new_path, ':');
if (old_path)
strbuf_addstr(&new_path, old_path);
@@ -375,7 +375,7 @@ static void show_man_page(const char *git_cmd)
static void show_info_page(const char *git_cmd)
{
const char *page = cmd_to_page(git_cmd);
- setenv("INFOPATH", GIT_INFO_PATH, 1);
+ setenv("INFOPATH", system_path(GIT_INFO_PATH), 1);
execlp("info", "info", "gitman", page, NULL);
}
diff --git a/exec_cmd.c b/exec_cmd.c
index cdd35f9..669b82e 100644
--- a/exec_cmd.c
+++ b/exec_cmd.c
@@ -9,11 +9,57 @@ static const char *argv0_path;
const char *system_path(const char *path)
{
- if (!is_absolute_path(path) && argv0_path) {
- struct strbuf d = STRBUF_INIT;
- strbuf_addf(&d, "%s/%s", argv0_path, path);
- path = strbuf_detach(&d, NULL);
+ static const char *prefix;
+
+ if (is_absolute_path(path)) {
+ return path;
+ }
+
+#ifdef RUNTIME_PREFIX
+ assert(argv0_path);
+ assert(is_absolute_path(argv0_path));
+
+ if (!prefix) {
+ const char *strip[] = {
+ GIT_EXEC_PATH,
+ BINDIR,
+ 0
+ };
+ const char **s;
+
+ for (s = strip; *s; s++) {
+ const char *sargv = argv0_path + strlen(argv0_path);
+ const char *ss = *s + strlen(*s);
+ while (argv0_path < sargv && *s < ss
+ && (*sargv == *ss ||
+ (is_dir_sep(*sargv) && is_dir_sep(*ss)))) {
+ sargv--;
+ ss--;
+ }
+ if (*s == ss) {
+ struct strbuf d = STRBUF_INIT;
+ /* We also skip the trailing directory separator. */
+ assert(sargv - argv0_path - 1 >= 0);
+ strbuf_add(&d, argv0_path, sargv - argv0_path - 1);
+ prefix = strbuf_detach(&d, NULL);
+ break;
+ }
+ }
}
+
+ if (!prefix) {
+ prefix = PREFIX;
+ fprintf(stderr, "RUNTIME_PREFIX requested, "
+ "but prefix computation failed. "
+ "Using static fallback '%s'.\n", prefix);
+ }
+#else
+ prefix = PREFIX;
+#endif
+
+ struct strbuf d = STRBUF_INIT;
+ strbuf_addf(&d, "%s/%s", prefix, path);
+ path = strbuf_detach(&d, NULL);
return path;
}
--
1.6.1.85.g32c5d
^ permalink raw reply related [flat|nested] 16+ messages in thread
* [PATCH 2/6] Refactor git_set_argv0_path() to git_extract_argv0_path()
2009-01-10 13:50 [PATCH 1/6] Move computation of absolute paths from Makefile to runtime and compute prefix on the fly if RUNTIME_PREFIX set Steffen Prohaska
@ 2009-01-10 13:50 ` Steffen Prohaska
2009-01-10 13:50 ` [PATCH 3/6] Glean libexec path from argv[0] for git-upload-pack and git-receive-pack Steffen Prohaska
2009-01-13 19:37 ` [PATCH 2/6] Refactor git_set_argv0_path() to git_extract_argv0_path() Johannes Sixt
2009-01-13 19:43 ` [PATCH 1/6] Move computation of absolute paths from Makefile to runtime and compute prefix on the fly if RUNTIME_PREFIX set Johannes Sixt
1 sibling, 2 replies; 16+ messages in thread
From: Steffen Prohaska @ 2009-01-10 13:50 UTC (permalink / raw)
To: Junio C Hamano
Cc: git, Johannes Schindelin, Johannes Sixt, Steve Haslam,
Steffen Prohaska
From: Steve Haslam <shaslam@lastminute.com>
This commit moves the code that computes the dirname of argv[0]
from git.c's main() to git_set_argv0_path() and renames the function
to git_extract_argv0_path(). This makes the code in git.c's main
less cluttered, and we can use the dirname computation from other
main() functions too.
[ spr:
- split Steve's original commit and wrote new commit message.
- Integrated Johannes Schindelin's
cca1704897e7fdb182f68d4c48a437c5d7bc5203 while rebasing onto master.
]
Signed-off-by: Steve Haslam <shaslam@lastminute.com>
Signed-off-by: Steffen Prohaska <prohaska@zib.de>
---
exec_cmd.c | 14 ++++++++++++--
exec_cmd.h | 2 +-
git.c | 19 +++++--------------
3 files changed, 18 insertions(+), 17 deletions(-)
diff --git a/exec_cmd.c b/exec_cmd.c
index 669b82e..576c9ae 100644
--- a/exec_cmd.c
+++ b/exec_cmd.c
@@ -63,9 +63,19 @@ const char *system_path(const char *path)
return path;
}
-void git_set_argv0_path(const char *path)
+const char *git_extract_argv0_path(const char *argv0)
{
- argv0_path = path;
+ const char *slash = argv0 + strlen(argv0);
+
+ while (argv0 <= slash && !is_dir_sep(*slash))
+ slash--;
+
+ if (slash >= argv0) {
+ argv0_path = xstrndup(argv0, slash - argv0);
+ return slash + 1;
+ }
+
+ return argv0;
}
void git_set_argv_exec_path(const char *exec_path)
diff --git a/exec_cmd.h b/exec_cmd.h
index 594f961..392e903 100644
--- a/exec_cmd.h
+++ b/exec_cmd.h
@@ -2,7 +2,7 @@
#define GIT_EXEC_CMD_H
extern void git_set_argv_exec_path(const char *exec_path);
-extern void git_set_argv0_path(const char *path);
+extern const char* git_extract_argv0_path(const char *path);
extern const char* git_exec_path(void);
extern void setup_path(void);
extern const char **prepare_git_cmd(const char **argv);
diff --git a/git.c b/git.c
index a53e24f..b99b1b2 100644
--- a/git.c
+++ b/git.c
@@ -419,22 +419,13 @@ static void execv_dashed_external(const char **argv)
int main(int argc, const char **argv)
{
- const char *cmd = argv[0] && *argv[0] ? argv[0] : "git-help";
- char *slash = (char *)cmd + strlen(cmd);
+ const char *cmd;
int done_alias = 0;
- /*
- * Take the basename of argv[0] as the command
- * name, and the dirname as the default exec_path
- * if we don't have anything better.
- */
- while (cmd <= slash && !is_dir_sep(*slash))
- slash--;
- if (cmd <= slash) {
- *slash++ = 0;
- git_set_argv0_path(cmd);
- cmd = slash;
- }
+ if (argv[0] && *argv[0])
+ cmd = git_extract_argv0_path(argv[0]);
+ else
+ cmd = "git-help";
/*
* "git-xxxx" is the same as "git xxxx", but we obviously:
--
1.6.1.85.g32c5d
^ permalink raw reply related [flat|nested] 16+ messages in thread
* [PATCH 3/6] Glean libexec path from argv[0] for git-upload-pack and git-receive-pack.
2009-01-10 13:50 ` [PATCH 2/6] Refactor git_set_argv0_path() to git_extract_argv0_path() Steffen Prohaska
@ 2009-01-10 13:50 ` Steffen Prohaska
2009-01-10 13:50 ` [PATCH 4/6] Add calls to git_extract_argv0_path() in programs that call git_config_* Steffen Prohaska
` (2 more replies)
2009-01-13 19:37 ` [PATCH 2/6] Refactor git_set_argv0_path() to git_extract_argv0_path() Johannes Sixt
1 sibling, 3 replies; 16+ messages in thread
From: Steffen Prohaska @ 2009-01-10 13:50 UTC (permalink / raw)
To: Junio C Hamano
Cc: git, Johannes Schindelin, Johannes Sixt, Steve Haslam,
Steffen Prohaska
From: Steve Haslam <shaslam@lastminute.com>
If the user specified the full path to git-upload-pack as the -u option to
"git clone" when cloning a remote repository, and git was not on the default
PATH on the remote machine, git-upload-pack was failing to exec
git-pack-objects.
By making the argv[0] path (if any) available to setup_path(), this will
allow finding the "git" executable in the same directory as
"git-upload-pack". The default built in to exec_cmd.c is to look for "git"
in the ".../libexec/git-core" directory, but it is not installed there (any
longer).
Much the same applies to invoking git-receive-pack from a non-PATH location
using the "--exec" argument to "git push".
[ spr: split Steve's original commit into two commits. ]
Signed-off-by: Steve Haslam <shaslam@lastminute.com>
Signed-off-by: Steffen Prohaska <prohaska@zib.de>
---
builtin-receive-pack.c | 3 +++
upload-pack.c | 3 +++
2 files changed, 6 insertions(+), 0 deletions(-)
diff --git a/builtin-receive-pack.c b/builtin-receive-pack.c
index db67c31..bbedcfe 100644
--- a/builtin-receive-pack.c
+++ b/builtin-receive-pack.c
@@ -579,6 +579,9 @@ int cmd_receive_pack(int argc, const char **argv, const char *prefix)
int i;
char *dir = NULL;
+ if (argv[0] && *argv[0])
+ git_extract_argv0_path(argv[0]);
+
argv++;
for (i = 1; i < argc; i++) {
const char *arg = *argv++;
diff --git a/upload-pack.c b/upload-pack.c
index e5adbc0..c469a60 100644
--- a/upload-pack.c
+++ b/upload-pack.c
@@ -616,6 +616,9 @@ int main(int argc, char **argv)
int i;
int strict = 0;
+ if (argv[0] && *argv[0])
+ git_extract_argv0_path(argv[0]);
+
for (i = 1; i < argc; i++) {
char *arg = argv[i];
--
1.6.1.85.g32c5d
^ permalink raw reply related [flat|nested] 16+ messages in thread
* [PATCH 4/6] Add calls to git_extract_argv0_path() in programs that call git_config_*
2009-01-10 13:50 ` [PATCH 3/6] Glean libexec path from argv[0] for git-upload-pack and git-receive-pack Steffen Prohaska
@ 2009-01-10 13:50 ` Steffen Prohaska
2009-01-10 13:50 ` [PATCH 5/6] Modify setup_path() to only add git_exec_path() to PATH Steffen Prohaska
2009-01-10 14:34 ` [PATCH 3/6] Glean libexec path from argv[0] for git-upload-pack and git-receive-pack Johannes Schindelin
2009-01-13 19:36 ` Johannes Sixt
2 siblings, 1 reply; 16+ messages in thread
From: Steffen Prohaska @ 2009-01-10 13:50 UTC (permalink / raw)
To: Junio C Hamano; +Cc: git, Johannes Schindelin, Johannes Sixt, Steffen Prohaska
Programs that use git_config need to find the global configuration.
When runtime prefix computation is enabled, this requires that
git_extract_argv0_path() is called early in the program's main().
This commit adds the necessary calls.
Signed-off-by: Steffen Prohaska <prohaska@zib.de>
---
daemon.c | 3 +++
fast-import.c | 4 ++++
hash-object.c | 4 ++++
http-push.c | 3 +++
imap-send.c | 4 ++++
index-pack.c | 4 ++++
merge-index.c | 4 ++++
merge-tree.c | 4 ++++
mktag.c | 4 ++++
mktree.c | 4 ++++
pack-redundant.c | 4 ++++
patch-id.c | 4 ++++
unpack-file.c | 4 ++++
update-server-info.c | 4 ++++
var.c | 4 ++++
15 files changed, 58 insertions(+), 0 deletions(-)
diff --git a/daemon.c b/daemon.c
index 540700e..1c5e604 100644
--- a/daemon.c
+++ b/daemon.c
@@ -937,6 +937,9 @@ int main(int argc, char **argv)
gid_t gid = 0;
int i;
+ if (argv[0] && *argv[0])
+ git_extract_argv0_path(argv[0]);
+
for (i = 1; i < argc; i++) {
char *arg = argv[i];
diff --git a/fast-import.c b/fast-import.c
index a6bce66..7762205 100644
--- a/fast-import.c
+++ b/fast-import.c
@@ -150,6 +150,7 @@ Format of STDIN stream:
#include "refs.h"
#include "csum-file.h"
#include "quote.h"
+#include "exec_cmd.h"
#define PACK_ID_BITS 16
#define MAX_PACK_ID ((1<<PACK_ID_BITS)-1)
@@ -2405,6 +2406,9 @@ int main(int argc, const char **argv)
{
unsigned int i, show_stats = 1;
+ if (argv[0] && *argv[0])
+ git_extract_argv0_path(argv[0]);
+
setup_git_directory();
git_config(git_pack_config, NULL);
if (!pack_compression_seen && core_compression_seen)
diff --git a/hash-object.c b/hash-object.c
index 846e91a..a689cc6 100644
--- a/hash-object.c
+++ b/hash-object.c
@@ -8,6 +8,7 @@
#include "blob.h"
#include "quote.h"
#include "parse-options.h"
+#include "exec_cmd.h"
static void hash_fd(int fd, const char *type, int write_object, const char *path)
{
@@ -81,6 +82,9 @@ int main(int argc, const char **argv)
type = blob_type;
+ if (argv[0] && *argv[0])
+ git_extract_argv0_path(argv[0]);
+
git_config(git_default_config, NULL);
argc = parse_options(argc, argv, hash_object_options, hash_object_usage, 0);
diff --git a/http-push.c b/http-push.c
index a4b7d08..dd2b2b1 100644
--- a/http-push.c
+++ b/http-push.c
@@ -2179,6 +2179,9 @@ int main(int argc, char **argv)
struct ref *ref;
char *rewritten_url = NULL;
+ if (argv[0] && *argv[0])
+ git_extract_argv0_path(argv[0]);
+
setup_git_directory();
remote = xcalloc(sizeof(*remote), 1);
diff --git a/imap-send.c b/imap-send.c
index c3fa0df..6e92aee 100644
--- a/imap-send.c
+++ b/imap-send.c
@@ -23,6 +23,7 @@
*/
#include "cache.h"
+#include "exec_cmd.h"
#ifdef NO_OPENSSL
typedef void *SSL;
#endif
@@ -1389,6 +1390,9 @@ int main(int argc, char **argv)
int total, n = 0;
int nongit_ok;
+ if (argv[0] && *argv[0])
+ git_extract_argv0_path(argv[0]);
+
/* init the random number generator */
arc4_init();
diff --git a/index-pack.c b/index-pack.c
index 2931511..0df297b 100644
--- a/index-pack.c
+++ b/index-pack.c
@@ -8,6 +8,7 @@
#include "tree.h"
#include "progress.h"
#include "fsck.h"
+#include "exec_cmd.h"
static const char index_pack_usage[] =
"git index-pack [-v] [-o <index-file>] [{ ---keep | --keep=<msg> }] [--strict] { <pack-file> | --stdin [--fix-thin] [<pack-file>] }";
@@ -880,6 +881,9 @@ int main(int argc, char **argv)
struct pack_idx_entry **idx_objects;
unsigned char pack_sha1[20];
+ if (argv[0] && *argv[0])
+ git_extract_argv0_path(argv[0]);
+
/*
* We wish to read the repository's config file if any, and
* for that it is necessary to call setup_git_directory_gently().
diff --git a/merge-index.c b/merge-index.c
index 7827e87..5d89ead 100644
--- a/merge-index.c
+++ b/merge-index.c
@@ -1,5 +1,6 @@
#include "cache.h"
#include "run-command.h"
+#include "exec_cmd.h"
static const char *pgm;
static const char *arguments[9];
@@ -93,6 +94,9 @@ int main(int argc, char **argv)
if (argc < 3)
usage("git-merge-index [-o] [-q] <merge-program> (-a | [--] <filename>*)");
+ if (argv[0] && *argv[0])
+ git_extract_argv0_path(argv[0]);
+
setup_git_directory();
read_cache();
diff --git a/merge-tree.c b/merge-tree.c
index 2d1413e..165ccfc 100644
--- a/merge-tree.c
+++ b/merge-tree.c
@@ -2,6 +2,7 @@
#include "tree-walk.h"
#include "xdiff-interface.h"
#include "blob.h"
+#include "exec_cmd.h"
static const char merge_tree_usage[] = "git-merge-tree <base-tree> <branch1> <branch2>";
static int resolve_directories = 1;
@@ -344,6 +345,9 @@ int main(int argc, char **argv)
if (argc != 4)
usage(merge_tree_usage);
+ if (argv[0] && *argv[0])
+ git_extract_argv0_path(argv[0]);
+
setup_git_directory();
buf1 = get_tree_descriptor(t+0, argv[1]);
diff --git a/mktag.c b/mktag.c
index ba3d495..ff32f8a 100644
--- a/mktag.c
+++ b/mktag.c
@@ -1,5 +1,6 @@
#include "cache.h"
#include "tag.h"
+#include "exec_cmd.h"
/*
* A signature file has a very simple fixed format: four lines
@@ -159,6 +160,9 @@ int main(int argc, char **argv)
if (argc != 1)
usage("git-mktag < signaturefile");
+ if (argv[0] && *argv[0])
+ git_extract_argv0_path(argv[0]);
+
setup_git_directory();
if (strbuf_read(&buf, 0, 4096) < 0) {
diff --git a/mktree.c b/mktree.c
index 514fd9b..8ac0d57 100644
--- a/mktree.c
+++ b/mktree.c
@@ -6,6 +6,7 @@
#include "cache.h"
#include "quote.h"
#include "tree.h"
+#include "exec_cmd.h"
static struct treeent {
unsigned mode;
@@ -70,6 +71,9 @@ int main(int ac, char **av)
unsigned char sha1[20];
int line_termination = '\n';
+ if (av[0] && *av[0])
+ git_extract_argv0_path(av[0]);
+
setup_git_directory();
while ((1 < ac) && av[1][0] == '-') {
diff --git a/pack-redundant.c b/pack-redundant.c
index e93eb96..8ff119b 100644
--- a/pack-redundant.c
+++ b/pack-redundant.c
@@ -7,6 +7,7 @@
*/
#include "cache.h"
+#include "exec_cmd.h"
#define BLKSIZE 512
@@ -601,6 +602,9 @@ int main(int argc, char **argv)
unsigned char *sha1;
char buf[42]; /* 40 byte sha1 + \n + \0 */
+ if (argv[0] && *argv[0])
+ git_extract_argv0_path(argv[0]);
+
setup_git_directory();
for (i = 1; i < argc; i++) {
diff --git a/patch-id.c b/patch-id.c
index 871f1d2..ff460e2 100644
--- a/patch-id.c
+++ b/patch-id.c
@@ -1,4 +1,5 @@
#include "cache.h"
+#include "exec_cmd.h"
static void flush_current_id(int patchlen, unsigned char *id, git_SHA_CTX *c)
{
@@ -79,6 +80,9 @@ int main(int argc, char **argv)
if (argc != 1)
usage(patch_id_usage);
+ if (argv[0] && *argv[0])
+ git_extract_argv0_path(argv[0]);
+
generate_id_list();
return 0;
}
diff --git a/unpack-file.c b/unpack-file.c
index bcdc8bb..f8bfda7 100644
--- a/unpack-file.c
+++ b/unpack-file.c
@@ -1,5 +1,6 @@
#include "cache.h"
#include "blob.h"
+#include "exec_cmd.h"
static char *create_temp_file(unsigned char *sha1)
{
@@ -25,6 +26,9 @@ int main(int argc, char **argv)
{
unsigned char sha1[20];
+ if (argv[0] && *argv[0])
+ git_extract_argv0_path(argv[0]);
+
if (argc != 2)
usage("git-unpack-file <sha1>");
if (get_sha1(argv[1], sha1))
diff --git a/update-server-info.c b/update-server-info.c
index 7e8209e..286a4dd 100644
--- a/update-server-info.c
+++ b/update-server-info.c
@@ -1,4 +1,5 @@
#include "cache.h"
+#include "exec_cmd.h"
static const char update_server_info_usage[] =
"git update-server-info [--force]";
@@ -19,6 +20,9 @@ int main(int ac, char **av)
if (i != ac)
usage(update_server_info_usage);
+ if (av[0] && *av[0])
+ git_extract_argv0_path(av[0]);
+
setup_git_directory();
return !!update_server_info(force);
diff --git a/var.c b/var.c
index f1eb314..33457dc 100644
--- a/var.c
+++ b/var.c
@@ -4,6 +4,7 @@
* Copyright (C) Eric Biederman, 2005
*/
#include "cache.h"
+#include "exec_cmd.h"
static const char var_usage[] = "git var [-l | <variable>]";
@@ -56,6 +57,9 @@ int main(int argc, char **argv)
usage(var_usage);
}
+ if (argv[0] && *argv[0])
+ git_extract_argv0_path(argv[0]);
+
setup_git_directory_gently(&nongit);
val = NULL;
--
1.6.1.85.g32c5d
^ permalink raw reply related [flat|nested] 16+ messages in thread
* [PATCH 5/6] Modify setup_path() to only add git_exec_path() to PATH
2009-01-10 13:50 ` [PATCH 4/6] Add calls to git_extract_argv0_path() in programs that call git_config_* Steffen Prohaska
@ 2009-01-10 13:50 ` Steffen Prohaska
2009-01-10 13:50 ` [PATCH 6/6] Windows: Revert to default paths and convert them by RUNTIME_PREFIX Steffen Prohaska
0 siblings, 1 reply; 16+ messages in thread
From: Steffen Prohaska @ 2009-01-10 13:50 UTC (permalink / raw)
To: Junio C Hamano; +Cc: git, Johannes Schindelin, Johannes Sixt, Steffen Prohaska
Searching git programs only in the highest priority location is
sufficient. It does not make sense that some of the required
programs are located at the highest priority location but other
programs are picked up from a lower priority exec-path. If
exec-path is overridden a complete set of commands should be
provided, otherwise several different versions could get mixed,
which is likely to cause confusion.
If a user explicitly overrides the default location (by --exec-path
or GIT_EXEC_PATH), we now expect that all the required programs are
found there. Instead of adding the directories "argv_exec_path",
"getenv(EXEC_PATH_ENVIRONMENT)", and "system_path(GIT_EXEC_PATH)"
to PATH, we now rely on git_exec_path(), which implements the same
order, but only returns the highest priority location to search for
executables.
Accessing only the location with highest priority is also required
for testing executables built with RUNTIME_PREFIX. The call to
system_path() should be avoided if RUNTIME_PREFIX is set and the
executable is not installed at its final destination. Because we
test before installing, we want to avoid calling system_path()
during tests. The modifications in this commit avoid calling
system_path(GIT_EXEC_PATH) if a higher-priority location is
provided, which is the case when running the tests.
Signed-off-by: Steffen Prohaska <prohaska@zib.de>
---
exec_cmd.c | 4 +---
1 files changed, 1 insertions(+), 3 deletions(-)
diff --git a/exec_cmd.c b/exec_cmd.c
index 576c9ae..ec38b0a 100644
--- a/exec_cmd.c
+++ b/exec_cmd.c
@@ -117,9 +117,7 @@ void setup_path(void)
const char *old_path = getenv("PATH");
struct strbuf new_path = STRBUF_INIT;
- add_path(&new_path, argv_exec_path);
- add_path(&new_path, getenv(EXEC_PATH_ENVIRONMENT));
- add_path(&new_path, system_path(GIT_EXEC_PATH));
+ add_path(&new_path, git_exec_path());
add_path(&new_path, argv0_path);
if (old_path)
--
1.6.1.85.g32c5d
^ permalink raw reply related [flat|nested] 16+ messages in thread
* [PATCH 6/6] Windows: Revert to default paths and convert them by RUNTIME_PREFIX
2009-01-10 13:50 ` [PATCH 5/6] Modify setup_path() to only add git_exec_path() to PATH Steffen Prohaska
@ 2009-01-10 13:50 ` Steffen Prohaska
0 siblings, 0 replies; 16+ messages in thread
From: Steffen Prohaska @ 2009-01-10 13:50 UTC (permalink / raw)
To: Junio C Hamano; +Cc: git, Johannes Schindelin, Johannes Sixt, Steffen Prohaska
The RUNTIME_PREFIX mechanism allows us to use the default paths on
Windows too. Defining RUNTIME_PREFIX explicitly requests for
translation of paths relative to the executable at runtime.
Signed-off-by: Steffen Prohaska <prohaska@zib.de>
---
Makefile | 4 +---
1 files changed, 1 insertions(+), 3 deletions(-)
diff --git a/Makefile b/Makefile
index a7728a3..a5f6cad 100644
--- a/Makefile
+++ b/Makefile
@@ -789,6 +789,7 @@ ifneq (,$(findstring MINGW,$(uname_S)))
SNPRINTF_RETURNS_BOGUS = YesPlease
NO_SVN_TESTS = YesPlease
NO_PERL_MAKEMAKER = YesPlease
+ RUNTIME_PREFIX = YesPlease
NO_POSIX_ONLY_PROGRAMS = YesPlease
NO_ST_BLOCKS_IN_STRUCT_STAT = YesPlease
COMPAT_CFLAGS += -D__USE_MINGW_ACCESS -DNOGDI -Icompat -Icompat/regex -Icompat/fnmatch
@@ -797,9 +798,6 @@ ifneq (,$(findstring MINGW,$(uname_S)))
COMPAT_OBJS += compat/mingw.o compat/fnmatch/fnmatch.o compat/regex/regex.o compat/winansi.o
EXTLIBS += -lws2_32
X = .exe
- gitexecdir = ../libexec/git-core
- template_dir = ../share/git-core/templates/
- ETC_GITCONFIG = ../etc/gitconfig
endif
ifneq (,$(findstring arm,$(uname_M)))
ARM_SHA1 = YesPlease
--
1.6.1.85.g32c5d
^ permalink raw reply related [flat|nested] 16+ messages in thread
* Re: [PATCH 3/6] Glean libexec path from argv[0] for git-upload-pack and git-receive-pack.
2009-01-10 13:50 ` [PATCH 3/6] Glean libexec path from argv[0] for git-upload-pack and git-receive-pack Steffen Prohaska
2009-01-10 13:50 ` [PATCH 4/6] Add calls to git_extract_argv0_path() in programs that call git_config_* Steffen Prohaska
@ 2009-01-10 14:34 ` Johannes Schindelin
2009-01-10 15:55 ` Steffen Prohaska
2009-01-10 16:01 ` Steffen Prohaska
2009-01-13 19:36 ` Johannes Sixt
2 siblings, 2 replies; 16+ messages in thread
From: Johannes Schindelin @ 2009-01-10 14:34 UTC (permalink / raw)
To: Steffen Prohaska; +Cc: Junio C Hamano, git, Johannes Sixt, Steve Haslam
Hi,
On Sat, 10 Jan 2009, Steffen Prohaska wrote:
> From: Steve Haslam <shaslam@lastminute.com>
>
> If the user specified the full path to git-upload-pack as the -u option to
> "git clone" when cloning a remote repository, and git was not on the default
> PATH on the remote machine, git-upload-pack was failing to exec
> git-pack-objects.
>
> By making the argv[0] path (if any) available to setup_path(), this will
> allow finding the "git" executable in the same directory as
> "git-upload-pack". The default built in to exec_cmd.c is to look for "git"
> in the ".../libexec/git-core" directory, but it is not installed there (any
> longer).
>
> Much the same applies to invoking git-receive-pack from a non-PATH location
> using the "--exec" argument to "git push".
>
> [ spr: split Steve's original commit into two commits. ]
I think you do not want to have that [ ... ] in the commit message, but
after the "--".
Further, it would make sense to have these 2 patches independently,
provided that a test is added with which we could verify that the patches
are actually necessary for upload-pack/receive-pack.
Logically, and to avoid committing a broken revision, 1/6 should come
last, methinks.
Ciao,
Dscho
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [PATCH 3/6] Glean libexec path from argv[0] for git-upload-pack and git-receive-pack.
2009-01-10 14:34 ` [PATCH 3/6] Glean libexec path from argv[0] for git-upload-pack and git-receive-pack Johannes Schindelin
@ 2009-01-10 15:55 ` Steffen Prohaska
2009-01-10 16:01 ` Steffen Prohaska
1 sibling, 0 replies; 16+ messages in thread
From: Steffen Prohaska @ 2009-01-10 15:55 UTC (permalink / raw)
To: Steve Haslam
Cc: Junio C Hamano, Git Mailing List, Johannes Sixt,
Johannes Schindelin
On Jan 10, 2009, at 3:34 PM, Johannes Schindelin wrote:
> On Sat, 10 Jan 2009, Steffen Prohaska wrote:
>
>> From: Steve Haslam <shaslam@lastminute.com>
>>
>> If the user specified the full path to git-upload-pack as the -u
>> option to
>> "git clone" when cloning a remote repository, and git was not on
>> the default
>> PATH on the remote machine, git-upload-pack was failing to exec
>> git-pack-objects.
>>
>> By making the argv[0] path (if any) available to setup_path(), this
>> will
>> allow finding the "git" executable in the same directory as
>> "git-upload-pack". The default built in to exec_cmd.c is to look
>> for "git"
>> in the ".../libexec/git-core" directory, but it is not installed
>> there (any
>> longer).
>>
>> Much the same applies to invoking git-receive-pack from a non-PATH
>> location
>> using the "--exec" argument to "git push".
>>
>> [ spr: split Steve's original commit into two commits. ]
>
> I think you do not want to have that [ ... ] in the commit message,
> but
> after the "--".
>
> Further, it would make sense to have these 2 patches independently,
> provided that a test is added with which we could verify that the
> patches
> are actually necessary for upload-pack/receive-pack.
Steve,
could you comment on this. You are the original author of the patch.
Steffen
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [PATCH 3/6] Glean libexec path from argv[0] for git-upload-pack and git-receive-pack.
2009-01-10 14:34 ` [PATCH 3/6] Glean libexec path from argv[0] for git-upload-pack and git-receive-pack Johannes Schindelin
2009-01-10 15:55 ` Steffen Prohaska
@ 2009-01-10 16:01 ` Steffen Prohaska
2009-01-10 20:36 ` Junio C Hamano
1 sibling, 1 reply; 16+ messages in thread
From: Steffen Prohaska @ 2009-01-10 16:01 UTC (permalink / raw)
To: Johannes Schindelin
Cc: Junio C Hamano, Git Mailing List, Johannes Sixt, Steve Haslam
On Jan 10, 2009, at 3:34 PM, Johannes Schindelin wrote:
> Logically, and to avoid committing a broken revision, 1/6 should come
> last, methinks.
RUNTIME_PREFIX is not defined before 6/6. But I agree,
1/6 should probably be moved after 5/6.
Steffen
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [PATCH 3/6] Glean libexec path from argv[0] for git-upload-pack and git-receive-pack.
2009-01-10 16:01 ` Steffen Prohaska
@ 2009-01-10 20:36 ` Junio C Hamano
2009-01-11 10:04 ` Steffen Prohaska
0 siblings, 1 reply; 16+ messages in thread
From: Junio C Hamano @ 2009-01-10 20:36 UTC (permalink / raw)
To: Steffen Prohaska
Cc: Johannes Schindelin, Git Mailing List, Johannes Sixt,
Steve Haslam
Steffen Prohaska <prohaska@zib.de> writes:
> On Jan 10, 2009, at 3:34 PM, Johannes Schindelin wrote:
>
>> Logically, and to avoid committing a broken revision, 1/6 should come
>> last, methinks.
>
> RUNTIME_PREFIX is not defined before 6/6. But I agree,
> 1/6 should probably be moved after 5/6.
>
> Steffen
Hmm, I actually was thinking about applying that (and that one only) early
to my tree, to make sure it is regression-free.
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [PATCH 3/6] Glean libexec path from argv[0] for git-upload-pack and git-receive-pack.
2009-01-10 20:36 ` Junio C Hamano
@ 2009-01-11 10:04 ` Steffen Prohaska
2009-01-11 10:21 ` Junio C Hamano
0 siblings, 1 reply; 16+ messages in thread
From: Steffen Prohaska @ 2009-01-11 10:04 UTC (permalink / raw)
To: Junio C Hamano
Cc: Johannes Schindelin, Git Mailing List, Johannes Sixt,
Steve Haslam
On Jan 10, 2009, at 9:36 PM, Junio C Hamano wrote:
> Steffen Prohaska <prohaska@zib.de> writes:
>
>> On Jan 10, 2009, at 3:34 PM, Johannes Schindelin wrote:
>>
>>> Logically, and to avoid committing a broken revision, 1/6 should
>>> come
>>> last, methinks.
>>
>> RUNTIME_PREFIX is not defined before 6/6. But I agree,
>> 1/6 should probably be moved after 5/6.
>>
> Hmm, I actually was thinking about applying that (and that one only)
> early
> to my tree, to make sure it is regression-free.
Does "early" mean that you want to wait and see how the discussion
about the other patches evolves before you consider applying them,
or does "and that one only" mean that you tend to not apply the
other patches at all?
Steffen
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [PATCH 3/6] Glean libexec path from argv[0] for git-upload-pack and git-receive-pack.
2009-01-11 10:04 ` Steffen Prohaska
@ 2009-01-11 10:21 ` Junio C Hamano
2009-01-11 12:57 ` Steffen Prohaska
0 siblings, 1 reply; 16+ messages in thread
From: Junio C Hamano @ 2009-01-11 10:21 UTC (permalink / raw)
To: Steffen Prohaska
Cc: Johannes Schindelin, Git Mailing List, Johannes Sixt,
Steve Haslam
Steffen Prohaska <prohaska@zib.de> writes:
>> Hmm, I actually was thinking about applying that (and that one only)
>> early
>> to my tree, to make sure it is regression-free.
>
> Does "early" mean that you want to wait and see how the discussion
> about the other patches evolves before you consider applying them,
> or does "and that one only" mean that you tend to not apply the
> other patches at all?
My initial impression after reading 1/6 was that no matter how the actual
runtime prefix detection logic that is implemented in the later parts of
the series for particular platform will turn out to be, the update to the
Makefile that is done by 1/6 won't have to change. If I apply 1/6 first
without applying anything else, we can make sure that it would not regress
for Unix people (and catch regressions early if any), while Windows people
polish the platform specific parts of the implementation in the later
parts of the series that can be replaced.
Because changes to Makefile variables tend to have unexpected side effects
(people have their own definition to override them in their build
procedures and you can easily break them unless you are careful), I wanted
to make sure the common part is solid before waiting for the other part.
But if you think it is better not to apply any one, until other parts
mature, it is Ok by me, too.
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [PATCH 3/6] Glean libexec path from argv[0] for git-upload-pack and git-receive-pack.
2009-01-11 10:21 ` Junio C Hamano
@ 2009-01-11 12:57 ` Steffen Prohaska
0 siblings, 0 replies; 16+ messages in thread
From: Steffen Prohaska @ 2009-01-11 12:57 UTC (permalink / raw)
To: Junio C Hamano
Cc: Johannes Schindelin, Git Mailing List, Johannes Sixt,
Steve Haslam
On Jan 11, 2009, at 11:21 AM, Junio C Hamano wrote:
> My initial impression after reading 1/6 was that no matter how the
> actual
> runtime prefix detection logic that is implemented in the later
> parts of
> the series for particular platform will turn out to be, the update
> to the
> Makefile that is done by 1/6 won't have to change. If I apply 1/6
> first
> without applying anything else, we can make sure that it would not
> regress
> for Unix people (and catch regressions early if any), while Windows
> people
> polish the platform specific parts of the implementation in the later
> parts of the series that can be replaced.
>
> Because changes to Makefile variables tend to have unexpected side
> effects
> (people have their own definition to override them in their build
> procedures and you can easily break them unless you are careful), I
> wanted
> to make sure the common part is solid before waiting for the other
> part.
>
> But if you think it is better not to apply any one, until other parts
> mature, it is Ok by me, too.
I think you should apply it.
Steffen
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [PATCH 3/6] Glean libexec path from argv[0] for git-upload-pack and git-receive-pack.
2009-01-10 13:50 ` [PATCH 3/6] Glean libexec path from argv[0] for git-upload-pack and git-receive-pack Steffen Prohaska
2009-01-10 13:50 ` [PATCH 4/6] Add calls to git_extract_argv0_path() in programs that call git_config_* Steffen Prohaska
2009-01-10 14:34 ` [PATCH 3/6] Glean libexec path from argv[0] for git-upload-pack and git-receive-pack Johannes Schindelin
@ 2009-01-13 19:36 ` Johannes Sixt
2 siblings, 0 replies; 16+ messages in thread
From: Johannes Sixt @ 2009-01-13 19:36 UTC (permalink / raw)
To: Steffen Prohaska; +Cc: Junio C Hamano, git, Johannes Schindelin, Steve Haslam
On Samstag, 10. Januar 2009, Steffen Prohaska wrote:
> diff --git a/builtin-receive-pack.c b/builtin-receive-pack.c
> index db67c31..bbedcfe 100644
> --- a/builtin-receive-pack.c
> +++ b/builtin-receive-pack.c
> @@ -579,6 +579,9 @@ int cmd_receive_pack(int argc, const char **argv, const
> char *prefix) int i;
> char *dir = NULL;
>
> + if (argv[0] && *argv[0])
> + git_extract_argv0_path(argv[0]);
> +
This is not necessary because receive-pack is meanwhile a builtin.
> diff --git a/upload-pack.c b/upload-pack.c
> index e5adbc0..c469a60 100644
> --- a/upload-pack.c
> +++ b/upload-pack.c
> @@ -616,6 +616,9 @@ int main(int argc, char **argv)
> int i;
> int strict = 0;
>
> + if (argv[0] && *argv[0])
> + git_extract_argv0_path(argv[0]);
> +
> for (i = 1; i < argc; i++) {
> char *arg = argv[i];
This hunk should be merged into 4/6.
-- Hannes
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [PATCH 2/6] Refactor git_set_argv0_path() to git_extract_argv0_path()
2009-01-10 13:50 ` [PATCH 2/6] Refactor git_set_argv0_path() to git_extract_argv0_path() Steffen Prohaska
2009-01-10 13:50 ` [PATCH 3/6] Glean libexec path from argv[0] for git-upload-pack and git-receive-pack Steffen Prohaska
@ 2009-01-13 19:37 ` Johannes Sixt
1 sibling, 0 replies; 16+ messages in thread
From: Johannes Sixt @ 2009-01-13 19:37 UTC (permalink / raw)
To: Steffen Prohaska; +Cc: Junio C Hamano, git, Johannes Schindelin, Steve Haslam
On Samstag, 10. Januar 2009, Steffen Prohaska wrote:
> @@ -63,9 +63,19 @@ const char *system_path(const char *path)
> return path;
> }
>
> -void git_set_argv0_path(const char *path)
> +const char *git_extract_argv0_path(const char *argv0)
> {
> - argv0_path = path;
Please insert the 'if (argv0 && *argv0)' here to simplify the call sites.
Or you could introduce this check later in 4/6 because the call site in
this patch (main() of git.c) is simpler if it keeps the check.
> + const char *slash = argv0 + strlen(argv0);
> +
> + while (argv0 <= slash && !is_dir_sep(*slash))
> + slash--;
> +
> + if (slash >= argv0) {
> + argv0_path = xstrndup(argv0, slash - argv0);
> + return slash + 1;
> + }
> +
> + return argv0;
> }
-- Hannes
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [PATCH 1/6] Move computation of absolute paths from Makefile to runtime and compute prefix on the fly if RUNTIME_PREFIX set
2009-01-10 13:50 [PATCH 1/6] Move computation of absolute paths from Makefile to runtime and compute prefix on the fly if RUNTIME_PREFIX set Steffen Prohaska
2009-01-10 13:50 ` [PATCH 2/6] Refactor git_set_argv0_path() to git_extract_argv0_path() Steffen Prohaska
@ 2009-01-13 19:43 ` Johannes Sixt
1 sibling, 0 replies; 16+ messages in thread
From: Johannes Sixt @ 2009-01-13 19:43 UTC (permalink / raw)
To: Steffen Prohaska; +Cc: Junio C Hamano, git, Johannes Schindelin
On Samstag, 10. Januar 2009, Steffen Prohaska wrote:
> This is the first commit of a series that adds support for
> relocatable binaries (called RUNTIME_PREFIX). Such binaries can be
> moved together with the system configuration files to a different
> directory, as long as the relative paths from the binary to the
> configuration files is preserved. This functionality is essential
> on Windows where we deliver git binaries with an installer that
> allows to freely choose the installation location. The commit
> series implements RUNTIME_PREFIX only on Windows. Adding support
> on Unix should not be too hard, though.
This series looks sane, and my comments on 2/6 and 3/6 certainly do not
indicate any showstoppers. I've just started using it; so far there are no
problems.
-- Hannes
^ permalink raw reply [flat|nested] 16+ messages in thread
end of thread, other threads:[~2009-01-13 19:44 UTC | newest]
Thread overview: 16+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-01-10 13:50 [PATCH 1/6] Move computation of absolute paths from Makefile to runtime and compute prefix on the fly if RUNTIME_PREFIX set Steffen Prohaska
2009-01-10 13:50 ` [PATCH 2/6] Refactor git_set_argv0_path() to git_extract_argv0_path() Steffen Prohaska
2009-01-10 13:50 ` [PATCH 3/6] Glean libexec path from argv[0] for git-upload-pack and git-receive-pack Steffen Prohaska
2009-01-10 13:50 ` [PATCH 4/6] Add calls to git_extract_argv0_path() in programs that call git_config_* Steffen Prohaska
2009-01-10 13:50 ` [PATCH 5/6] Modify setup_path() to only add git_exec_path() to PATH Steffen Prohaska
2009-01-10 13:50 ` [PATCH 6/6] Windows: Revert to default paths and convert them by RUNTIME_PREFIX Steffen Prohaska
2009-01-10 14:34 ` [PATCH 3/6] Glean libexec path from argv[0] for git-upload-pack and git-receive-pack Johannes Schindelin
2009-01-10 15:55 ` Steffen Prohaska
2009-01-10 16:01 ` Steffen Prohaska
2009-01-10 20:36 ` Junio C Hamano
2009-01-11 10:04 ` Steffen Prohaska
2009-01-11 10:21 ` Junio C Hamano
2009-01-11 12:57 ` Steffen Prohaska
2009-01-13 19:36 ` Johannes Sixt
2009-01-13 19:37 ` [PATCH 2/6] Refactor git_set_argv0_path() to git_extract_argv0_path() Johannes Sixt
2009-01-13 19:43 ` [PATCH 1/6] Move computation of absolute paths from Makefile to runtime and compute prefix on the fly if RUNTIME_PREFIX set Johannes Sixt
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).