I've been tasked with compiling openldap for Windows, using Visual Studio. I am comfortable doing configure > make > make install in POSIX environments, but I have never used VS and am not sure how to even generate a useable makefile using what's in the openldap source tarball.
I have Visual C++ 10 Express installed on a Windows 7 box, and I've also installed MinGW to try to run the configure script, but I'm afraid that's going to then insert MinGW libraries, instead of whatever native Windows libs VC would use.
I would be grateful for any clues.
I would stop the bleeding right now and download the Windows port from here. I've been using it in production for over a year and nary a problem.
The KDE guys have CMake-based build system for openldap. You could follow the instructions on http://techbase.kde.org/Getting_Started/Build/Windows/emerge to set up the build environment. The main steps would be something like:
This will build more than just openldap (it pulls in dependencies like cyrus-sasl and openssl). There are a number of patches that are applied for the KDE builds, that may or may not be relevant outside of the KDE environment.
But the nice thing is that CMake supports generating a Visual Studio project file, so you'd be able to generate that and do builds in VS.