[Python-Dev] zlib module doesn't build - inflateCopy() not found
Tim Peters
tim.peters at gmail.com
Fri May 19 23:43:39 CEST 2006
[Guido]
> I'm having trouble getting the zlib module to build (SVN HEAD). The error is:
>
> building 'zlib' extension
> gcc -pthread -fPIC -fno-strict-aliasing -DNDEBUG -g -O3 -Wall
> -Wstrict-prototypes -I. -I/home/guido/projects/python/trunk/./Include
> -I../Include -I. -I/usr/local/include
> -I/home/guido/projects/python/trunk/Include
> -I/home/guido/projects/python/trunk/linux -c
> /home/guido/projects/python/trunk/Modules/zlibmodule.c -o
> build/temp.linux-i686-2.5/zlibmodule.o
> /home/guido/projects/python/trunk/Modules/zlibmodule.c: In function
> `PyZlib_uncopy':
> /home/guido/projects/python/trunk/Modules/zlibmodule.c:723: warning:
> implicit declaration of function `inflateCopy'
> gcc -pthread -shared build/temp.linux-i686-2.5/zlibmodule.o
> -L/usr/local/lib -lz -o build/lib.linux-i686-2.5/zlib.so
> *** WARNING: renaming "zlib" since importing it failed:
> build/lib.linux-i686-2.5/zlib.so: undefined symbol: inflateCopy
>
> It seems I have libz 1.1.4. Is this no longer supported?
That's very peculiar. Python has its own copy of the zlib code now,
under Modules/zlib/. That's version 1.2.3.
http://mail.python.org/pipermail/python-dev/2005-December/058873.html
inflateCopy() is exported by Modules/zlib/inflate.c. I wonder why the
last gcc line above has "-lz" in it? Upgrade to Windows and
everything will be fine :-)
More information about the Python-Dev
mailing list