From: Claudio Sacerdoti Coen Date: Thu, 21 Dec 2000 14:25:06 +0000 (+0000) Subject: configuration.pl.in configured X-Git-Tag: nogzip~72 X-Git-Url: http://matita.cs.unibo.it/gitweb/?a=commitdiff_plain;h=1b7c9907af7530d118f886d4844b0c9a8d2950ca;p=helm.git configuration.pl.in configured --- diff --git a/helm/configuration/configure.in b/helm/configuration/configure.in index 9a4d94cfd..c96778800 100644 --- a/helm/configuration/configure.in +++ b/helm/configuration/configure.in @@ -18,4 +18,4 @@ HELM_ETC_DIR=$RESOLVED_PREFIX/etc/helm AC_SUBST(HELM_LIB_DIR) AC_SUBST(HELM_ETC_DIR) -AC_OUTPUT([Makefile]) +AC_OUTPUT([Makefile lib/configuration.pl]) diff --git a/helm/configuration/lib/configuration.pl.in b/helm/configuration/lib/configuration.pl.in index e88d8fbe7..6c101d79e 100644 --- a/helm/configuration/lib/configuration.pl.in +++ b/helm/configuration/lib/configuration.pl.in @@ -1,11 +1,13 @@ use XML::Parser; use Env; -my $HELM_CONFIGURATION_PREFIX = $ENV{"HELM_CONFIGURATION_PREFIX"}; +my $HELM_CONFIGURATION_DIR = $ENV{"HELM_CONFIGURATION_DIR"}; +my $DEFAULT_HELM_CONFIGURATION_DIR = @HELM_ETC_DIR@; # this should be the only fixed constant -if (defined ($HELM_CONFIGURATION_PREFIX) { - $configuration_file = - $HELM_CONFIGURATION_PREFIX."/etc/helm/configuration.xml"; +if (defined ($HELM_CONFIGURATION_DIR) { + $configuration_file = $HELM_CONFIGURATION_DIR."/configuration.xml"; +} else { + $configuration_file = $DEFAULT_HELM_CONFIGURATION_DIR."/configuration.xml"; } $parser = new XML::Parser(Handlers => {Start => \&handle_start,