[poppler] PATCH: Add includes to pdftocairo to compile in mingw
Albert Astals Cid
aacid at kde.org
Sun Aug 27 10:52:37 UTC 2017
El divendres, 25 d’agost de 2017, a les 21:55:12 CEST, Adrian Johnson va
> On 25/08/17 03:54, Albert Astals Cid wrote:
> > Hi, i need this patch to be able to compile pdftocairo with mingw.
> > Any reason not to commit it?
> I managed to get a cmake mingw cross compile working and also got the
> same error on pdftocairo-win32.cc. I compiled this file with verbose on
> with both autotools and cmake and compared the options.
> The reason the cmake builds needs these includes is it is defining
> -DWIN32_LEAN_AND_MEAN which causes windows.h to include only a subset of
> the windows API. So adding these includes is fine.
According to someone that knows much more about windows than me
WIN32_LEAN_AND_MEAN "is the way to go", so i'll commit the includes.
> I also noticed another difference between autotools and cmake. Autotools
> is compiling with -std=c++11. Cmake is using -std=gnu++11. I think
> -std=c++11 is better so as to avoid using anything that won't work with
> Visual Studio.
> There is also some additional mingw stuff in configure.ac:
> win32_libs="-lgdi32 -lwinspool -lcomdlg32"
> I could not see this in cmake. It seems to compile without it. Not sure
> if it is needed for anything.
This seems like very old stuff, unless we have a reason to ad it, i'd rather
> poppler mailing list
> poppler at lists.freedesktop.org
More information about the poppler