I\'m building OpenLDAP on a RHEL 5; I used instructions found at http://www.linux.com/archive/feature/113607.
All went well, until running \'./configure\' for OpenLDAP -
apt-get install libdb-dev worked for me in Ubuntu Server.