diff options
author | unknown <msvensson@neptunus.(none)> | 2006-04-10 15:14:47 +0200 |
---|---|---|
committer | unknown <msvensson@neptunus.(none)> | 2006-04-10 15:14:47 +0200 |
commit | f7af64abdabacff724115a1c5ddab0afeec9e47f (patch) | |
tree | 8af025f268fb99e269f0f59e6e134830dc72105a | |
parent | c4c9d4fb8cc4c5114728a150d6a075834f2a050d (diff) | |
parent | 7672a2264a67b419e702862edd5ec5dae6afe6a2 (diff) | |
download | mariadb-git-f7af64abdabacff724115a1c5ddab0afeec9e47f.tar.gz |
Merge 192.168.0.20:mysql/bug15069/my51-bug15069
into neptunus.(none):/home/msvensson/mysql/mysql-5.1
libmysql/Makefile.shared:
Auto merged
mysys/Makefile.am:
Auto merged
-rw-r--r-- | libmysql/Makefile.shared | 1 | ||||
-rw-r--r-- | mysys/Makefile.am | 1 | ||||
-rw-r--r-- | mysys/default.c | 10 |
3 files changed, 11 insertions, 1 deletions
diff --git a/libmysql/Makefile.shared b/libmysql/Makefile.shared index a641bdf2f10..c2d98a81042 100644 --- a/libmysql/Makefile.shared +++ b/libmysql/Makefile.shared @@ -85,6 +85,7 @@ DEFS = -DDEFAULT_CHARSET_HOME="\"$(MYSQLBASEdir)\"" \ -DDATADIR="\"$(MYSQLDATAdir)\"" \ -DDEFAULT_HOME_ENV=MYSQL_HOME \ -DDEFAULT_GROUP_SUFFIX_ENV=MYSQL_GROUP_SUFFIX \ + -DDEFAULT_SYSCONFDIR="\"$(sysconfdir)\"" \ -DSHAREDIR="\"$(MYSQLSHAREdir)\"" $(target_defs) if HAVE_YASSL diff --git a/mysys/Makefile.am b/mysys/Makefile.am index 51ea249bbf6..031e36a5909 100644 --- a/mysys/Makefile.am +++ b/mysys/Makefile.am @@ -73,6 +73,7 @@ DEFS = -DDEFAULT_BASEDIR=\"$(prefix)\" \ -DSHAREDIR="\"$(MYSQLSHAREdir)\"" \ -DDEFAULT_HOME_ENV=MYSQL_HOME \ -DDEFAULT_GROUP_SUFFIX_ENV=MYSQL_GROUP_SUFFIX \ + -DDEFAULT_SYSCONFDIR="\"$(sysconfdir)\"" \ @DEFS@ libmysys_a_DEPENDENCIES= @THREAD_LOBJECTS@ diff --git a/mysys/default.c b/mysys/default.c index edd02402a2a..90f8dc5f689 100644 --- a/mysys/default.c +++ b/mysys/default.c @@ -48,7 +48,7 @@ char *defaults_extra_file=0; /* Which directories are searched for options (and in which order) */ -#define MAX_DEFAULT_DIRS 6 +#define MAX_DEFAULT_DIRS 7 const char *default_directories[MAX_DEFAULT_DIRS + 1]; #ifdef __WIN__ @@ -959,11 +959,13 @@ static uint my_get_system_windows_directory(char *buffer, uint size) 4. getenv(DEFAULT_HOME_ENV) 5. Directory above where the executable is located 6. "" + 7. --sysconfdir=<path> On Novell NetWare, this is: 1. sys:/etc/ 2. getenv(DEFAULT_HOME_ENV) 3. "" + 4. --sysconfdir=<path> On OS/2, this is: 1. getenv(ETC) @@ -971,12 +973,14 @@ static uint my_get_system_windows_directory(char *buffer, uint size) 3. getenv(DEFAULT_HOME_ENV) 4. "" 5. "~/" + 6. --sysconfdir=<path> Everywhere else, this is: 1. /etc/ 2. getenv(DEFAULT_HOME_ENV) 3. "" 4. "~/" + 5. --sysconfdir=<path> */ @@ -1041,5 +1045,9 @@ static void init_default_directories() *ptr++= (char *)&config_dir; } #endif +#ifdef DEFAULT_SYSCONFDIR + if (DEFAULT_SYSCONFDIR != "") + *ptr++= DEFAULT_SYSCONFDIR; +#endif *ptr= 0; /* end marker */ } |