Compile with ./script.sh

To observe it attempting to load dynamic libraries, add ldap to the beginning of your passwd or hosts line in /etc/nsswitch.conf.