[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Mysterious gzipped images

From: Eli Zaretskii
Subject: Re: Mysterious gzipped images
Date: Mon, 12 Aug 2013 15:21:07 +0300

> Date: Mon, 12 Aug 2013 15:13:49 +0300
> From: Eli Zaretskii <address@hidden>
> Cc: address@hidden
>   decompress.o(.text+0x16): In function `unwind_decompress':
>   d:\gnu\bzr\emacs\trunk\src/decompress.c:40: undefined reference to 
> `inflateEnd'
>   decompress.o(.text+0xf7): In function `Fdecompress_gzipped_region':
>   d:\gnu\bzr\emacs\trunk\src/decompress.c:83: undefined reference to 
> `inflateInit2_'
>   decompress.o(.text+0x242):d:\gnu\bzr\emacs\trunk\src/decompress.c:114: 
> undefined reference to `inflate'
>   collect2: ld returned 1 exit status
>   Makefile:677: recipe for target `temacs.exe' failed
>   make[1]: *** [temacs.exe] Error 1
> Looks like -lz is missing from the link command line.

I see the problem in configure.ac:

  if test "${with_zlib}" != "no"; then
    if test "${HAVE_PNG}" = "yes"; then
      ### PNG depends on zlib, so if we have PNG, we have zlib.
      HAVE_ZLIB=yes               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
      ### No PNG, so check zlib ourselves.

Your assumption that if PNG is being compiled in, the link command
line will necessarily include -lz is false.  In particular, on Windows
libpng is loaded dynamically, so no -lFOO link arguments are used
during the link, even though the PNG support is being compiled.

(I don't really understand why you needed to take this shortcut
anyway: what's wrong with having two -lz switches passed to the

reply via email to

[Prev in Thread] Current Thread [Next in Thread]