aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFlorian Dold <florian.dold@gmail.com>2016-04-22 13:55:52 +0000
committerFlorian Dold <florian.dold@gmail.com>2016-04-22 13:55:52 +0000
commit104cac085849940d33c706499ae7678273296caf (patch)
tree34a1bc27145af640214fe1e8a410b000a2a85fff
parentcd5084f02721786289459c0958537a6ffc24ac1e (diff)
Allow GNUNET_BASE_CONFIG to be customized.
Needed for GNU Taler.
-rw-r--r--src/util/configuration_loader.c5
-rw-r--r--src/util/os_installation.c1
2 files changed, 5 insertions, 1 deletions
diff --git a/src/util/configuration_loader.c b/src/util/configuration_loader.c
index 2caad8c051..07eeb98f07 100644
--- a/src/util/configuration_loader.c
+++ b/src/util/configuration_loader.c
@@ -43,8 +43,11 @@ GNUNET_CONFIGURATION_load (struct GNUNET_CONFIGURATION_Handle *cfg,
const char *filename)
{
char *baseconfig;
+ const char *base_config_varname;
- if (NULL != (baseconfig = getenv ("GNUNET_BASE_CONFIG")))
+ base_config_varname = GNUNET_OS_project_data_get ()->base_config_varname;
+
+ if (NULL != (baseconfig = getenv (base_config_varname)))
{
baseconfig = GNUNET_strdup (baseconfig);
}
diff --git a/src/util/os_installation.c b/src/util/os_installation.c
index 45f5052aad..161b0535f6 100644
--- a/src/util/os_installation.c
+++ b/src/util/os_installation.c
@@ -58,6 +58,7 @@ static const struct GNUNET_OS_ProjectData default_pd = {
.project_dirname = "gnunet",
.binary_name = "gnunet-arm",
.env_varname = "GNUNET_PREFIX",
+ .base_config_varname = "GNUNET_BASE_CONFIG",
.bug_email = "gnunet-developers@gnu.org",
.homepage = "http://www.gnu.org/s/gnunet/",
.config_file = "gnunet.conf",