Windows: Use the Windows style PATH separator ';'.

Signed-off-by: Johannes Sixt <johannes.sixt@telecom.at>
This commit is contained in:
Johannes Sixt 2007-12-03 21:55:57 +01:00
parent f4626df51f
commit 80ba074f41
5 changed files with 15 additions and 5 deletions

View File

@ -409,9 +409,9 @@ git so take care if using Cogito etc.
'GIT_ALTERNATE_OBJECT_DIRECTORIES':: 'GIT_ALTERNATE_OBJECT_DIRECTORIES'::
Due to the immutable nature of git objects, old objects can be Due to the immutable nature of git objects, old objects can be
archived into shared, read-only directories. This variable archived into shared, read-only directories. This variable
specifies a ":" separated list of git object directories which specifies a ":" separated (on Windows ";" separated) list
can be used to search for git objects. New objects will not be of git object directories which can be used to search for git
written to these directories. objects. New objects will not be written to these directories.
'GIT_DIR':: 'GIT_DIR'::
If the 'GIT_DIR' environment variable is set then it If the 'GIT_DIR' environment variable is set then it

View File

@ -132,3 +132,9 @@ int getpagesize(void); /* defined in MinGW's libgcc.a */
struct passwd *getpwuid(int uid); struct passwd *getpwuid(int uid);
int setitimer(int type, struct itimerval *in, struct itimerval *out); int setitimer(int type, struct itimerval *in, struct itimerval *out);
int sigaction(int sig, struct sigaction *in, struct sigaction *out); int sigaction(int sig, struct sigaction *in, struct sigaction *out);
/*
* git specific compatibility
*/
#define PATH_SEP ';'

View File

@ -37,7 +37,7 @@ static void add_path(struct strbuf *out, const char *path)
else else
strbuf_addstr(out, make_absolute_path(path)); strbuf_addstr(out, make_absolute_path(path));
strbuf_addch(out, ':'); strbuf_addch(out, PATH_SEP);
} }
} }

View File

@ -110,6 +110,10 @@
#define PRIuMAX "llu" #define PRIuMAX "llu"
#endif #endif
#ifndef PATH_SEP
#define PATH_SEP ':'
#endif
#ifdef __GNUC__ #ifdef __GNUC__
#define NORETURN __attribute__((__noreturn__)) #define NORETURN __attribute__((__noreturn__))
#else #else

View File

@ -392,7 +392,7 @@ void prepare_alt_odb(void)
if (!alt) alt = ""; if (!alt) alt = "";
alt_odb_tail = &alt_odb_list; alt_odb_tail = &alt_odb_list;
link_alt_odb_entries(alt, alt + strlen(alt), ':', NULL, 0); link_alt_odb_entries(alt, alt + strlen(alt), PATH_SEP, NULL, 0);
read_info_alternates(get_object_directory(), 0); read_info_alternates(get_object_directory(), 0);
} }