[Olsr-dev] Problem with compiling olsrd-0.6.1 source code using Android NDK r4

Nai-Shuo Jheng (spam-protected)
Mon Jun 20 20:13:58 CEST 2011


Hi all,

I''m a newbie of android development & trying to port olsrd-0.6.1 to my HTC
Desire phone.
I have been download android NDK version 4 & move the NDK folder to /opt/,
just like Makefile.android said:

NDK = /opt/android-ndk-r4b
NDK_ARCH = $(NDK)/build/platforms/android-3/arch-arm

Then, I start to compile it with:

sudo make OS=android DEBUG=0 build_all

However, it suddenly show many error message below:

/opt/android-ndk-r4b/build/prebuilt/linux-x86/arm-eabi-4.2.1/bin/../lib/gcc/arm-eabi/4.2.1/include/stdio.h:50:23:
error: sys/cdefs.h: No such file or directory
/opt/android-ndk-r4b/build/prebuilt/linux-x86/arm-eabi-4.2.1/bin/../lib/gcc/arm-eabi/4.2.1/include/stdio.h:51:24:
error: sys/_types.h: No such file or directory
src/unix/misc.c:43:20: error: unistd.h: No such file or directory
......

It seems like it could't find these header files, and those are
in /opt/android-ndk-r4b/build/platforms/android-3/arch-arm/usr/include
folder.
But Makefile.android have been already setup the external path of header
files:

CFLAGS += -I$(NDK_ARCH)/usr/include
CFLAGS += -I$(TOPDIR)/android

Does anyone have the same problem or solution? Thanks.

Regards,
--
Jeff Jheng
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.olsr.org/pipermail/olsr-dev/attachments/20110621/2c65e3b9/attachment.html>


More information about the Olsr-dev mailing list