Merge patch for better installs on POSIX platforms.

git-svn-id: https://svn.code.sf.net/p/nsis/code/NSIS/trunk@4486 212acab6-be3b-0410-9dea-997c60f758d6
This commit is contained in:
pabs3 2006-01-21 09:54:23 +00:00
parent c16ca4f9fc
commit 0913023f33
25 changed files with 286 additions and 134 deletions

View file

@ -390,8 +390,17 @@ int main(int argc, char **argv)
if (!g_noconfig)
{
g_noconfig=1;
string main_conf = get_executable_dir(argv[0]) + PLATFORM_PATH_SEPARATOR_STR + "nsisconf.nsh";
string main_conf;
char* env_var = getenv("NSISCONFDIR");
if(env_var == NULL)
#ifndef NSIS_CONFIG_CONST_DATA_PATH
main_conf = get_executable_dir(argv[0]);
#else
main_conf = CONST_STR(PREFIX_CONF);
#endif
else main_conf = env_var;
main_conf += PLATFORM_PATH_SEPARATOR_STR;
main_conf += "nsisconf.nsh";
if (process_config(build, main_conf))
return 1;