1. download openldap openldap-stable-20100719.tgz

2. apt-get install db4.7-util

3. apt-get install libdb4.7-dev

4. apt-get install libdb4.7++-dev

5. extract openldap-stable-20100719.tgz

6. ./Configure

7. make depend

8. make

9. make install

AND