From: Andrew Bartlett Date: Mon, 10 Aug 2009 11:51:08 +0000 (+1000) Subject: s4:selftest Make OpenLDAP guess it's own modules from now on X-Git-Tag: tevent-0.9.8~440 X-Git-Url: http://git.samba.org/?p=samba.git;a=commitdiff_plain;h=4921a5853b323e9c19f192220a94cf4a7cd077ff 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 --- diff --git a/selftest/target/Samba4.pm b/selftest/target/Samba4.pm index da627cd42f3..a4e3c58835c 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); }