From 4921a5853b323e9c19f192220a94cf4a7cd077ff Mon Sep 17 00:00:00 2001 From: Andrew Bartlett Date: Mon, 10 Aug 2009 21:51:08 +1000 Subject: s4:selftest Make OpenLDAP guess it's own modules from now on In the releases of OpenLDAP we require (2.4.17) it can guess this much itself, so no need for us to do it. Andrew Bartlett --- selftest/target/Samba4.pm | 46 ---------------------------------------------- 1 file changed, 46 deletions(-) (limited to 'selftest/target') diff --git a/selftest/target/Samba4.pm b/selftest/target/Samba4.pm index da627cd42f..a4e3c58835 100644 --- a/selftest/target/Samba4.pm +++ b/selftest/target/Samba4.pm @@ -233,52 +233,6 @@ sub mk_openldap($$$) my $slapd_conf = "$ldapdir/slapd.conf"; my $pidfile = "$ldapdir/slapd.pid"; - my $modconf = "$ldapdir/modules.conf"; - - my $oldpath = $ENV{PATH}; - my $olpath = ""; - my $olroot = ""; - if (defined $ENV{OPENLDAP_ROOT}) { - $olroot = "$ENV{OPENLDAP_ROOT}"; - $olpath = "$olroot/libexec:$olroot/sbin:"; - } - $ENV{PATH} = "$olpath/usr/local/sbin:/usr/sbin:/sbin:$ENV{PATH}"; - - unlink($modconf); - - #This code tries to guess what modules we need to load (if any) by trying different combinations in the modules.conf - - # Try without any slapd modules - open(CONF, ">$modconf"); close(CONF); - - if (system("slaptest -u -f $slapd_conf >&2") != 0) { - open(CONF, ">$modconf"); - # enable slapd modules - print CONF " -moduleload syncprov -moduleload memberof -moduleload refint -moduleload deref -"; - close(CONF); - } - if (system("slaptest -u -f $slapd_conf >&2") != 0) { - open(CONF, ">$modconf"); - # enable slapd modules, and the module for back_hdb - print CONF " -moduleload back_hdb -moduleload syncprov -moduleload memberof -moduleload refint -moduleload deref -"; - close(CONF); - } - - system("slaptest -u -f $slapd_conf") == 0 or die("slaptest still fails after adding modules"); - - - $ENV{PATH} = $oldpath; return ($slapd_conf, $pidfile); } -- cgit