Android build failed

I followed the instructions here . After $ repo syncI tried to build it using $ make, but got this error:

host SharedLib: libneo_cgi (out/host/linux-x86/obj/lib/libneo_cgi.so) 
/usr/bin/ld: skipping incompatible /usr/lib/gcc/i486-linux-gnu/4.4.3/../../../libz.so when searching for -lz 
/usr/bin/ld: skipping incompatible /usr/lib/gcc/i486-linux-gnu/4.4.3/../../../libz.a when searching for -lz 
/usr/bin/ld: skipping incompatible /usr/lib/libz.so when searching for -lz 
/usr/bin/ld: skipping incompatible /usr/lib/libz.a when searching for -lz 
/usr/bin/ld: cannot find -lz 
collect2: ld returned 1 exit status 
make: *** [out/host/linux-x86/obj/lib/libneo_cgi.so] Error 1 

Using Ubuntu 10.04 LTS. Any help was appreciated.

UPD: I found a discussion that claims that the problem may be that I have 64-bit libraries on my 32-bit system.

$ ls -l /usr/lib/libz.so 
lrwxrwxrwx 1 root root 20 2010-07-07 17:08 /usr/lib/libz.so -> /lib/libz.so.1.2.3.3

$ file /lib/libz.so.1.2.3.3
/lib/libz.so.1.2.3.3: ELF 32-bit LSB shared object, Intel 80386, version 1 (SYSV), dynamically linked, stripped

How can I find out if libz.so.1.2.3.3 is the correct lib, and in case I have to replace it with the correct one, how can I do this?

Also $ archsays that I have an i686 architecture. Machine, I am using a Lenovo ThinkPad SL500 with a Core 2 DUO processor.

+5
3

, lib64z1-dev:

sudo apt-get install lib64z1-dev

: ClearSilver, .

+3

libz.

sudo apt-get install libz-dev
+1

Libz library has a different name in different distributions

lib32z1 on debian system

+1
source

All Articles