All tests run through without failures on OS X El Capitan / 10.11.1 with the following configuration:
export CC="gcc -isystem /usr/local/opt/berkeley-db4/include -L/usr/local/opt/berkeley-db4/lib -L/usr/local/opt/berkeley-db4/lib”
./configure --enable-overlays --enable-ldap --enable-meta
BerkeleyDB is version 4.8.30 from Homebrew.
jens