I&#39;m trying to build on mingw on Windows, and I am having a lot of trouble getting a shared library to be built.  In theory, this is in the same configuration with the same dependencies as I&#39;ve successfully built cairo before, so I gather something may have changed.  (I&#39;m building from the current git sources.)<br>
<br>First, a word about my setup.  I&#39;m building cairo &amp; its dependencies in a local, temporary directory, with environment variables &amp; --prefix set up so this local path is searched first.  Among other things, this avoids pulling in certain system libraries, like, say, the wrong version of pixman (though that&#39;s not an issue on win32 I suppose).  Anyway, among these is zlib, which I build statically, intending that the cairo DLL will link statically with it.  This has worked in the past, as recently as 1.8.X.  But now, libtool seems to choke on zlib.  Here&#39;s the command &amp; result of it:<br>
<br>/bin/sh ../libtool --tag=CXX   --mode=link g++  -g -O2  -version-info 10905:0:10903 -no-undefined -export-symbols cairo.def -L/tmp/pango-build-23492fskdja/install/lib  -o <a href="http://libcairo.la">libcairo.la</a> -rpath /tmp/pango-build-23492fskdja/install/lib                                             cairo-analysis-surface.lo cairo-arc.lo cairo-array.lo cairo-atomic.lo cairo-base85-stream.lo cairo-bentley-ottmann.lo cairo.lo cairo-cache.lo cairo-clip.lo cairo-color.lo cairo-debug.lo cairo-fixed.lo cairo-font-face.lo cairo-font-face-twin.lo cairo-font-face-twin-data.lo cairo-font-options.lo cairo-freelist.lo cairo-gstate.lo cairo-hash.lo cairo-hull.lo cairo-image-info.lo cairo-image-surface.lo cairo-lzw.lo cairo-matrix.lo cairo-meta-surface.lo cairo-misc.lo cairo-mutex.lo cairo-output-stream.lo cairo-paginated-surface.lo cairo-path-bounds.lo cairo-path.lo cairo-path-fill.lo cairo-path-fixed.lo cairo-path-in-fill.lo cairo-path-stroke.lo cairo-pattern.lo cairo-pen.lo cairo-polygon.lo cairo-rectangle.lo cairo-region.lo cairo-scaled-font.lo cairo-skiplist.lo cairo-slope.lo cairo-spans.lo cairo-spline.lo cairo-stroke-style.lo cairo-surface.lo cairo-surface-fallback.lo cairo-tor-scan-converter.lo cairo-system.lo cairo-traps.lo cairo-toy-font-face.lo cairo-unicode.lo cairo-user-font.lo cairo-version.lo cairo-wideint.lo cairo-cff-subset.lo cairo-scaled-font-subsets.lo cairo-truetype-subset.lo cairo-type1-fallback.lo cairo-type1-subset.lo cairo-type3-glyph-surface.lo cairo-pdf-operators.lo        cairo-win32-surface.lo cairo-win32-printing-surface.lo cairo-win32-font.lo         cairo-ps-surface.lo cairo-pdf-surface.lo cairo-deflate-stream.lo    -LC:/DOCUME~1/damianf/LOCALS~1/Temp/pango-build-23492fskdja/install/lib -lpixman-1      -lgdi32 -lmsimg32     -lz -lz    -lm<br>
<br>*** Warning: linker path does not have real file for library -lz.<br>*** I have the capability to make that library automatically link in when<br>*** you link to this library.  But I can only do this if you have a<br>
*** shared version of the library, which you do not appear to have<br>*** because I did check the linker path looking for a file starting<br>*** with libz and none of the candidates passed a file format test<br>*** using a file magic. Last file checked: C:/DOCUME~1/damianf/LOCALS~1/Temp/pango-build-23492fskdja/install/lib/libz.a<br>
*** The inter-library dependencies that have been dropped here will be<br>*** automatically added whenever a program is linked with this library<br>*** or is declared to -dlopen it.<br><br>*** Since this library must not contain undefined symbols,<br>
*** because either the platform does not support them or<br>*** it was explicitly requested with -no-undefined,<br>*** libtool will only create a static version of it.<br><br><br>Just to be sure, that libz.a does exist, and is valid.<br>
<br>$ file C:/DOCUME~1/damianf/LOCALS~1/Temp/pango-build-23492fskdja/install/lib/li<br>bz.a<br>C:/DOCUME~1/damianf/LOCALS~1/Temp/pango-build-23492fskdja/install/lib/libz.a: current ar archive<br><br>Can anyone please offer me advice on getting this to link a shared library?<br>
<br>Damian<br><br>