Compiling busybox for Android on Freerunner

2del 2del at maryhit.com
Sun Aug 16 14:27:57 CEST 2009


update:

I tried to run the busybox bins I found on the web for Android, but it seems
were not compiled for Freerunner.
I tried also to use the busybox bin from the openmoko distrib, failed again
with "not found" error.
My last solution seems to be to compile it myself.
 a) followed http://trac.koolu.org/ and http://source.android.com/download
 b) I took the busybox branch from koolu (
http://git.koolu.org/?p=platform/external/busybox.git;a=summary), but it
seems that it's not configured for freerunner(does not have Android.mk file
and arch is ARCH=i386 without arm option).
 c) I checked the busybox.net and it seems they also do not have conf for
arm.
Now I modified the Makefile of the busybox downloaded at step b above, to
have:
[code]ARCH            ?= arm
CROSS_COMPILE   ?=
/mnt/D/moko/openmoko/arm/bin/arm-angstrom-linux-gnueabi-[/code]
and I get:
[code]  SPLIT   include/autoconf.h -> include/config/*
  GEN     include/bbconfigopts.h
  HOSTCC  applets/usage
applets/usage.c: In function a? maina??:
applets/usage.c:16: warning: ignoring return value of a? writea??, declared
with attribute warn_unused_result
  GEN     include/usage_compressed.h
  HOSTCC  applets/applet_tables
  GEN     include/applet_tables.h
  CC      applets/applets.o
as: unrecognized option '-mfloat-abi=soft'
make[1]: *** [applets/applets.o] Error 1
make: *** [applets] Error 2[/code]
PS: the toolchain
(openmoko-i686-20090323-armv4t-linux-gnueabi-toolchain-openmoko.tar.bz2) was
downloaded from openmoko.org.
2nd try:
I downloaded the deb package with chaintool from koolu
(android-toolchain_20081019-koolu1_i386.deb) and was installed under
/opt/android-toolchain/...
[code]ARCH            ?= arm
CROSS_COMPILE   ?= /opt/android-toolchain/bin/armv4t-android-eabi-[/code]
and now it seems the include is not correct (see below). I checked the
/opt/android-toolchain/ and indeed it does not have the header files inside,
like openmoko toolchain. Could this be the issue?
[code]
  SPLIT   include/autoconf.h -> include/config/*
  GEN     include/bbconfigopts.h
  HOSTCC  applets/usage
applets/usage.c: In function 'main':
applets/usage.c:16: warning: ignoring return value of 'write', declared with
attribute warn_unused_result
  GEN     include/usage_compressed.h
  HOSTCC  applets/applet_tables
  GEN     include/applet_tables.h
  CC      applets/applets.o
applets/applets.c:10:20: error: assert.h: No such file or directory
In file included from include/libbb.h:13,
                 from include/busybox.h:10,
                 from applets/applets.c:11:
include/platform.h:107:23: error: byteswap.h: No such file or directory
include/platform.h:108:21: error: endian.h: No such file or directory
include/platform.h:114:7: warning: "__BYTE_ORDER" is not defined
include/platform.h:114:23: warning: "__BIG_ENDIAN" is not defined
include/platform.h:140:24: error: arpa/inet.h: No such file or directory
include/platform.h:187:5: warning: "__BIG_ENDIAN__" is not defined
In file included from include/busybox.h:10,
                 from applets/applets.c:11:
include/libbb.h:15:19: error: ctype.h: No such file or directory
include/libbb.h:16:20: error: dirent.h: No such file or directory
include/libbb.h:17:19: error: errno.h: No such file or directory
include/libbb.h:18:19: error: fcntl.h: No such file or directory
include/libbb.h:19:22: error: inttypes.h: No such file or directory
include/libbb.h:20:19: error: netdb.h: No such file or directory
include/libbb.h:21:20: error: setjmp.h: No such file or directory
include/libbb.h:22:20: error: signal.h: No such file or directory
include/libbb.h:23:19: error: stdio.h: No such file or directory
include/libbb.h:24:20: error: stdlib.h: No such file or directory
include/libbb.h:27:20: error: string.h: No such file or directory
[/code]
I noticed that the bionic project has these files in it's include dir.
Of course I tried to copy those from there and it fails with various errors.
For sure this is not the way...
Now,
can anyone explain how to configure this project to be buildable ? I think
an Android.mk file has to be created but could not find how to tranform the
existing Makefile to Andorid.mk.

Thanks.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.openmoko.org/pipermail/devel/attachments/20090816/67623351/attachment.htm 


More information about the devel mailing list