[poppler] poppler ported to Mingw+MSys

carlo.bramix carlo.bramix at libero.it
Wed Sep 24 01:01:00 PDT 2008


Hello,
I tried to compile poppler under mingw+msys.
With some fixes I was able to compile it successfully.
I did my changes on the latest git checkout.
Description of changes into attached patch:

glib/Makefile.am
added support for shared library generation to libpoppler-glib.

/glib/demo/info.cc
Localtime_r is not existing under win32 so I made a conditional compilation with HAVE_LOCALTIME_R.

test/Makefile.am
The linking of pdf_inspector generated thousand of unresolved externals; I had to link with $(top_builddir)/glib/libpoppler-glib.la instead of $(top_builddir)/poppler/libpoppler-cairo.la for solving the trouble.

/test/gtk-cairo-test.cc
/test/pdf-inspector.cc
I could not compile these files because they included some X files (win32 have not gdk/gdkx.h, cairo-xlib.h and X11/Xutil.h) but hopefully poppler already defines X_DISPLAY_MISSING so I just limited those includes when that macro is undefined.

At the end everything seemed solved unless a little detail...
At the beginning libjpeg was not found at configure time; infact this happens because of this line into libjpeg.m4:

jpeg_incdirs="`eval echo $includedir` /usr/include /usr/local/include "

Since under mingw the include files are normally under /mingw/include and not under /usr/include or /usr/local/include, I had to add "--includedir=/mingw/include".
In that manner, it was able to find my libraries correctly but when I launch "make install" the include files of poppler are installed under /mingw/include instead of the location specified with "--prefix".
So, I'm wondering if it's possible to add an option to configure script like "--with-jpeg-include=<path>" so that an user could specify a libjpeg path without loosing the installation path.
Unfortunately I don't think I'm able to do it: I'm a (mainly) win32 developer and I'm not so expert yet on autoconf programming, so I hope somebody could help me on this task.

Sincerely,

Carlo Bramini.

-------------- next part --------------
A non-text attachment was scrubbed...
Name: poppler.patch
Type: application/octet-stream
Size: 2526 bytes
Desc: not available
Url : http://lists.freedesktop.org/archives/poppler/attachments/20080924/8b4d7fb3/attachment.obj 


More information about the poppler mailing list