I have managed to install the Netscape C SDK on a Solaris machine and have
gotten some scripts with perldap to run with it. Now, however, I am
trying to get perldap to run on a Digital Unix machine and cannot make it
work. I downloaded the SDK from the iPlanet site and put the include
elements in /usr/local/include and the lib elements in /usr/local/lib.
Then I ran the build on the perldap (1.4.1) and the build and "make test"
went ok. But when I try to connect with the server, it fails. None of
the code examples really go into how to figure out why the initial instance
creation might fail, does anyone know how I could investigate this? The
script I am trying to run is this:
#!/usr/local/bin/perl
use Mozilla::LDAP::Conn;
print"about to connect\n";
$ldap = Mozilla::LDAP::Conn->new("info2.uah.edu",389);
unless ($ldap) { die "No connection\n" }
print"connected, about to search\n";
$entry = $ldap->search("dc=uah,dc=edu","sub","uid=mccullj");
print"back from search\n";
if (! $entry) {
print"search failed\n";
} else {
while ($entry){
$entry->printLDIF;
$entry = $ldap->nextEntry();
}
}
I cant call any of the getError functions because $ldap is not defined. This
script works from a Solaris host on our network, so I know the server is
functioning. A couple of things I should mention, though. On the Compaq
host, I am running OSF 4.0F and the SDK is for 4.0D (I think). Also, my
directory server version is 4.13, but there was not a SDK for that version
so I downloaded the one for 4.14. Could the version mismatches be the cause
of my not being able to connect?