mapnik-org/mapnik — Issue #689: Patch - directly use LoadLibrary etc. on Windows, so that libldtl is not needed
Author: artemp
Created: 2011-10-11 08:08:23+00:00
State: open
Labels: Core_Library

Context of this patch is me trying to build mapnik on Windows with Visual Studio, including building all dependencies from scratch (so that I have debug binaries).

libldtl seems to be impossible to build without installing GNU make. At the same time, the functionality it provides seems minimal. The attached patch replaces libldtl with direct calls to LoadLibrary/GetProcAddress etc. on Windows. There are several way to do this, in the attached patch my goal was to minimize the code changes to the rest of the mapnik code, and not introduce more #ifdef than strictly necessary. Since the arguments to the libldtl and their equivalent direct calls are the same, I could get away with #defining the calls to libldtl so that they are substituted with the native call names.

The main disadvantage is that it #include's , causing some other (minor) issues, see my other patches. I'm not sure if it's that big a deal, and I'm also not sure if other libraries don't already do that, anyway.