[Q] Building an app from source [limbo-android] - Android Q&A, Help & Troubleshooting

Hi,
I've wanted to use the app "limbo-android" ( https://code.google.com/p/limbo-android/ ) on my Intel Atom (x86) android tablet.
Unfortunatly, I have only found an apk for arm devices that crashes when I start a VM in the app. So, I have tried to build the app myself (I was following this https://code.google.com/p/limbo-android/source/browse/README ).
So far, I have downloaded the tools (SDK, NDK r8e, Eclipse + Eclipse Android plugin) and the source ( https://code.google.com/p/limbo-android/source/browse/ ) and unpacked all of it. After that, I have tried to follow the README file. So, i have competed steps 3, 4a, but I am stuck at point 4b. (I have also copied the NDK to /usr/local/bin because even when i have configured the right folders in step 3, it sayed something like ndk-build not found)
now with that done, if i type 'make' into the terminal, this is what i have got:
Code:
mkdir -p /home/sobotkama/limbo-android/jni/..//obj/local/x86/
rm -rf /home/sobotkama/limbo-android/jni/..//libs/armeabi ../libs/armeabi-v7a ../libs/x86 ../libs/mips \
mkdir -p /home/sobotkama/limbo-android/jni/..//libs/x86/
cd /home/sobotkama/limbo-android/jni/../ && ndk-build V=1 LIMBO_JNI_ROOT=/home/sobotkama/limbo-android/jni
make[1]: Entering directory `/home/sobotkama/limbo-android'
jni/Application.mk:10: ARCH_CFLAGS = -std=gnu99 -ffunction-sections -O3 -fomit-frame-pointer -fstrict-aliasing -funswitch-loops -finline-limit=300 -DANDROID_X86
jni/Application.mk:11: LOCAL_ARM_MODE =
jni/Application.mk:12: LOCAL_ARM_NEON =
jni/Application.mk:13: NDK_DEBUG =
jni/Application.mk:14: APP_OPTIM =
jni/Application.mk:15: APP_ABI = x86
/usr/local/bin/build/gmsl/__gmsl:512: *** non-numeric second argument to `wordlist' function: ''. Stop.
make[1]: Leaving directory `/home/sobotkama/limbo-android'
make: *** [sdl] Error 2
Running both Ubuntu and Windows 8.1 on my PC, doing this on Ubuntu.
Any help like what should I do or is there anyone that would build it for me, please?
Thanks, Sobotkama

Anyone?

Related

[HOWTO] Build custom kernel, libraries and applications on your own

For building own custom stuff for my Gen8 Device I set up an Ubuntu 10.10 32bit Virtual Machine, so everything in here refers to it, may be different on other linux system.
[disclaimer]This is only a HowTo, if you brick your android device with some custom kernels or other stuff, don't blame me! I'm not responsible for anything you do![/disclaimer]
Notice: ** = you only have to do this step once
Prerequisites for Ubuntu 10.10 32 Bit: **
Code:
# sudo apt-get install git-core flex bison gperf libsdl-dev libesd0-dev libwxgtk2.6-dev build-essential zip curl automake autoconf libtool gettext texinfo libmpfr1ldbl
Prepare environment: **
Code:
# mkdir -pv $HOME/{archos,bin}
# echo export ARCHOS=\$HOME/archos >> ~/.bashrc
# echo export PATH=\$HOME/bin:\$PATH >> ~/.bashrc
# cd $HOME/archos
# wget -Oavos_env.tgz http://archos-gen8-dvb.googlecode.com/files/avos_env_20110415.tgz
# tar xzf avos_env.tgz
# install -m755 cross $HOME/bin/
# rm -f cross avos_env.tgz
RESTART CONSOLE OR REBOOT COMPUTER!
Toolchain: **
Code:
# cd $ARCHOS
# make all
Configure kernel:
Code:
# cd $ARCHOS
# make kernel-config
Restore kernel config:
Code:
# cd $ARCHOS
# make kernel-reset
Build kernel:
Code:
# cd $ARCHOS
# make kernel-build
CrossCompile: (this is just an example for if you want to build some linux libraries or tools)
Code:
# echo $ARCHOS
# cd ..xyz../..zyx../
# cross make
I followed your instructions, and I got all the way to the end, but when I did 'make kernel-build' it ended with this:
drivers/built-in.o: In function `archos_dpm_suspend':
/home/zyntax/archos/gen8-gpl-froyo/linux/drivers/usb/storage/archos_hdd.c:261: undefined reference to `usbsata_power'
make[3]: *** [.tmp_vmlinux1] Error 1
make[2]: *** [sub-make] Error 2
make[2]: Leaving directory `/home/zyntax/archos/gen8-gpl-froyo/linux'
make[1]: *** [/home/zyntax/archos/gen8-gpl-froyo/buildroot//linux/arch/arm/boot/zImage] Error 2
make[1]: Leaving directory `/home/zyntax/archos/gen8-gpl-froyo/buildroot'
make: *** [kernel-build] Error 2
[email protected]:~/archos$
This is on a fresh install of Ubuntu 10.10 32-bit in Virtualbox. I installed it, updated the OS, then started your steps. Not sure if this is normal and I'm holding off on the last step. I did do one extra step: in 'make kernal-config' I deselected all the Archos boards under System Type except for the A101IT since that's what I have.
jbradshw said:
This is on a fresh install of Ubuntu 10.10 32-bit in Virtualbox. I installed it, updated the OS, then started your steps. Not sure if this is normal and I'm holding off on the last step. I did do one extra step: in 'make kernal-config' I deselected all the Archos boards under System Type except for the A101IT since that's what I have.
Click to expand...
Click to collapse
can you please try again without modifying kernel config?
Did that, now I get this:
CC [M] drivers/usb/musb/omap2430.o
/home/zyntax/archos/gen8-gpl-froyo/linux/drivers/usb/musb/omap2430.c:221: warning: 'omap_phy_read' defined but not used
LD [M] drivers/usb/musb/musb_hdrc.o
LD drivers/built-in.o
make[2]: *** [sub-make] Error 2
make[2]: Leaving directory `/home/zyntax/archos/gen8-gpl-froyo/linux'
make[1]: *** [/home/zyntax/archos/gen8-gpl-froyo/buildroot//linux/arch/arm/boot/zImage] Error 2
make[1]: Leaving directory `/home/zyntax/archos/gen8-gpl-froyo/buildroot'
make: *** [kernel-build] Error 2
I don't believe I changed anything besides what I mentioned earlier. Is there anyway to get back a default kernel-config?
hehe, I thought you should try with default kernel-config
I added a section for restoring kernel config in the start posting :
chulri said:
[*]Restore kernel config:
Code:
# cd $ARCHOS
# tar xzf gen8-gpl-froyo.tgz gen8-gpl-froyo/linux/linux.config
Click to expand...
Click to collapse
Well I did poke around in the config, but as far as I remember I only removed those extra archos systems. I'll restore the default and run it again later tonight.
Thanks.
jbradshw said:
Well I did poke around in the config, but as far as I remember I only removed those extra archos systems. I'll restore the default and run it again later tonight.
Click to expand...
Click to collapse
You can't remove other devices (like A32, A101 etc) from Linux kernel config because Archos made bad dependencies for different parts of the kernel and even 70S requires some USB kernel code, it's only compiled when you choose A101 - so either you clean it up manually, or you are required to leave checked other archos devices :/
Thanks for this howto, this is gonna be useful for me, should be a sticky.
OK the make kernel-build worked without errors. Now I'm just questioning the command 'cd ..xyz../..zyx../' I don't have any files or directories called that, and running that reports the same. Can I just skip that and do the make cross?
@jbradshw that's just a sample if someone wants to crosscompile something (e.g. some linux library or application like linuxtv-dvb-apps or w_scan)
you don't have to do everything mentioned in the howto. it's a HowTo not a HaveTo
Ahh OK. So I guess I'm done then. I haven't installed the SDE on my Archos yet, but what's the final 'thing' that came out of this procedure that I'll be placing on the tablet?
Also I don't have an microSD card yet, and I know there was talk of putting stuff on there - can this be done using just the internal memory (8 GB for me)?
you have to install the SDE to install a custom kernel. follow this guide: http://forum.xda-developers.com/showthread.php?p=10157349#post10157349
Yeah I saw that guide, my question is where is the zImage and initramfs.cpio.gz that I assume was part of the compiling I just did? And also if a microSD card is needed for any of this?
no microsd is needed
initramfs.cpio.gz can be extracted from current installation ( /dev/mmcblk0p1 -> init ), read this: http://forum.xda-developers.com/showthread.php?t=880321&page=5
zImage is compiled at this location: $ARCHOS/gen8-gpl-froyo/buildroot/linux/arch/arm/boot/zImage
Shouldn't it be
Code:
cross make kernel-build
?
Here I have to use cross, which makes sense to find gcc arm binaries.
No you don't. In case of building stuff which comes with the gen8-gpl-froyo.tgz (e.g. kernel) the env vars are set up by the supplied makefiles
chulri said:
No you don't. In case of building stuff which comes with the gen8-gpl-froyo.tgz (e.g. kernel) the env vars are set up by the supplied makefiles
Click to expand...
Click to collapse
If I don't use cross, here is what I get:
[email protected]:~/archos$ make kernel-build
make -C gen8-gpl-froyo/linux mrproper
make[1]: arm-linux-gcc: Command not found
make[1]: Entering directory `/home/ubuntu/archos/gen8-gpl-froyo/linux'
make[3]: arm-linux-gcc: Command not found
But using cross it compiled fine, though I followed carefully your directions !
Apparently I was too frightened by the error messages, since it does work in the end
Thank you very much, hope some good things come from this !
Cheers !
desiresush said:
Apparently I was too frightened by the error messages, since it does work in the end
Click to expand...
Click to collapse
Yeah it's just an annoying bug, it doesn't hurt because "mrproper" only cleans the build directory and doesn't need compiler at all
2.6.29 kernel for Froyo?
Does anybody know, why Archos releases the SDK with a 2.6.29 kernel?
Shouldn't 2.2 Froyo be a 2.6.32 kernel?

[Q] Kernel Module Compiling Versioning..

I need help guys, I'm really new to this kernel compiling thing (I'm not really even a software engineer..) But anyway, so I have this mini wireless keyboard + mouse I'm trying to get to work on my MK802 II (Allwinner A10). From plugging the wireless dongle into my linux machine, I did an lsmod and determined the drivers to be hid-ortek.ko. And this driver happens to be absent on the MK802 II.
I set up my ubuntu with android sdk and ndk and all the other prereqs from thousands of other sites from googling.
Then I git cloned the Allwinner A10 kernel source from : https://github.com/amery/linux-allwinner and checked out the lichee 3.0.8+ to match the kernel version on my MK802 II.
So then I started off with:
Code:
make ARCH=arm sun4i_defconfig
make ARCH=arm menuconfig
And then I selected Ortek keyboard drivers from the UI and marked it as 'm'.
Because apparently Module.symver is only generated if you do a complete kernel build.. so I did
Code:
make ARCH=arm CROSS_COMPILE=~/Downloads/android-ndk-r8b/toolchains/arm-linux-androideabi-4.4.3/prebuilt/linux-x86/bin/arm-linux-androideabi- all
And Module.symver is created after this step.
But I looked in the ./drivers/hid folder to see if hid-ortek.ko was compiled and apparently not
so then I did:
Code:
make ARCH=arm CROSS_COMPILE=~/Downloads/android-ndk-r8b/toolchains/arm-linux-androideabi-4.4.3/prebuilt/linux-x86/bin/arm-linux-androideabi- M=./drivers/hid modules
And my "hid-ortek.ko" was still not created. The output from this was:
Code:
Building modules, stage 2.
MODPOST 0 modules
So I googled up tutorials and created a Makefile that looked like this:
Code:
VERSION = 3
PATCHLEVEL = 0
SUBLEVEL = 8
EXTRAVERSION =
obj-m += hid-ortek.o
KDIR=~/Documents/linux-allwinner
PWD := $(pwd)
default:
make -C $(KDIR) ARCH=arm CROSS_COMPILE=~/Downloads/android-ndk-r8b/toolchains/arm-linux-androideabi-4.4.3/prebuilt/linux-x86/bin/arm-linux-androideabi- SUBDIRS=$(PWD) modules
clean:
make -C $(KDIR) ARCH=arm CROSS_COMPILE=~/Downloads/android-ndk-r8b/toolchains/arm-linux-androideabi-4.4.3/prebuilt/linux-x86/bin/arm-linux-androideabi- SUBDIRS=$(PWD) clean
and did a make, that did the trick and hid-ortek.ko was created
So I did the adb push into my MK802 (into /system/vendor/modules folder) and tried insmod it.. but I kept getting
Code:
insmod: init_module 'hid-ortek.ko' failed (Exec format error)
and dmesg tells me that there is "no symbol version for module_layout". Which according to googling around means that Module.symver wasn't generated so I have to do a full build, but I did and I saw Module.symver generated in my kernel source directory. I did a modinfo on the compiled hid-ortek.ko and it shows
Code:
3.0.8+ preempt mod_unload modversions ARMv7
Which should be right. I did a modinfo on the other modules already loaded on the device and shows the exact same thing.
What am I doing wrong here? Please help.
Thanks!
chen_tso said:
I need help guys, I'm really new to this kernel compiling thing (I'm not really even a software engineer..) But anyway, so I have this mini wireless keyboard + mouse I'm trying to get to work on my MK802 II (Allwinner A10). From plugging the wireless dongle into my linux machine, I did an lsmod and determined the drivers to be hid-ortek.ko. And this driver happens to be absent on the MK802 II.
I set up my ubuntu with android sdk and ndk and all the other prereqs from thousands of other sites from googling.
Then I git cloned the Allwinner A10 kernel source from : https://github.com/amery/linux-allwinner and checked out the lichee 3.0.8+ to match the kernel version on my MK802 II.
So then I started off with:
Code:
make ARCH=arm sun4i_defconfig
make ARCH=arm menuconfig
And then I selected Ortek keyboard drivers from the UI and marked it as 'm'.
Because apparently Module.symver is only generated if you do a complete kernel build.. so I did
Code:
make ARCH=arm CROSS_COMPILE=~/Downloads/android-ndk-r8b/toolchains/arm-linux-androideabi-4.4.3/prebuilt/linux-x86/bin/arm-linux-androideabi- all
And Module.symver is created after this step.
But I looked in the ./drivers/hid folder to see if hid-ortek.ko was compiled and apparently not
so then I did:
Code:
make ARCH=arm CROSS_COMPILE=~/Downloads/android-ndk-r8b/toolchains/arm-linux-androideabi-4.4.3/prebuilt/linux-x86/bin/arm-linux-androideabi- M=./drivers/hid modules
And my "hid-ortek.ko" was still not created. The output from this was:
Code:
Building modules, stage 2.
MODPOST 0 modules
So I googled up tutorials and created a Makefile that looked like this:
Code:
VERSION = 3
PATCHLEVEL = 0
SUBLEVEL = 8
EXTRAVERSION =
obj-m += hid-ortek.o
KDIR=~/Documents/linux-allwinner
PWD := $(pwd)
default:
make -C $(KDIR) ARCH=arm CROSS_COMPILE=~/Downloads/android-ndk-r8b/toolchains/arm-linux-androideabi-4.4.3/prebuilt/linux-x86/bin/arm-linux-androideabi- SUBDIRS=$(PWD) modules
clean:
make -C $(KDIR) ARCH=arm CROSS_COMPILE=~/Downloads/android-ndk-r8b/toolchains/arm-linux-androideabi-4.4.3/prebuilt/linux-x86/bin/arm-linux-androideabi- SUBDIRS=$(PWD) clean
and did a make, that did the trick and hid-ortek.ko was created
So I did the adb push into my MK802 (into /system/vendor/modules folder) and tried insmod it.. but I kept getting
Code:
insmod: init_module 'hid-ortek.ko' failed (Exec format error)
and dmesg tells me that there is "no symbol version for module_layout". Which according to googling around means that Module.symver wasn't generated so I have to do a full build, but I did and I saw Module.symver generated in my kernel source directory. I did a modinfo on the compiled hid-ortek.ko and it shows
Code:
3.0.8+ preempt mod_unload modversions ARMv7
Which should be right. I did a modinfo on the other modules already loaded on the device and shows the exact same thing.
What am I doing wrong here? Please help.
Thanks!
Click to expand...
Click to collapse
Did you change the kernel itself ?
'no symbol version for module_layout'
Hello, I have the exact same issue (but using kernel "2.6.36-android+")
did you find a solution?
Im also in the same boat guys...
mat23452345 said:
Hello, I have the exact same issue (but using kernel "2.6.36-android+")
did you find a solution?
Click to expand...
Click to collapse
Im buiding kernel for goodix touch drivers as im currently modding a LY-F1 JB ROM which uses a focaltouch touchscreen. but a full build is not enabling the modules and gives a exec error. Maybe it has something to do with ur extra version variable. change EXTRAVERSION = to "EXTRAVERSION =+" and do a build and tell me what happens. Im out so cant really test it.
cybermate123 said:
change EXTRAVERSION = to "EXTRAVERSION =+" and do a build and tell me what happens.
Click to expand...
Click to collapse
Thanks for the reply, but that tablet has crashed and gone now. I will bear that in mind for the future...

make: arm-eabi-gcc: Command not found

android development noob here (was just a web programmer till now), way outta my league, and could use a few pointers.
i installed all the stuff i listed here: http://forum.xda-developers.com/showthread.php?t=2474543 and got the results given below.
i later installed binutils:i386, which uninstalled most of that stuff and installed a 78mb package, which i assume replaces a lot of it, but, i got the same results.
Code:
$ make ARCH=arm clean
make: arm-eabi-gcc: Command not found
clean
$
$ echo $CROSS_COMPILE
/storage/software/android/custom/sources/android-lgp769v21b/linux-x86/toolchain/arm-eabi-4.4.3/bin/arm-eabi-
$
$ ls /storage/software/android/custom/sources/android-lgp769v21b/linux-x86/toolchain/arm-eabi-4.4.3/bin/
arm-eabi-addr2line arm-eabi-cpp arm-eabi-gcov arm-eabi-nm arm-eabi-run
arm-eabi-ar arm-eabi-g++ arm-eabi-gdb arm-eabi-objcopy arm-eabi-size
arm-eabi-as arm-eabi-gcc arm-eabi-gdbtui arm-eabi-objdump arm-eabi-strings
arm-eabi-c++ arm-eabi-gcc-4.4.3 arm-eabi-gprof arm-eabi-ranlib arm-eabi-strip
arm-eabi-c++filt arm-eabi-gccbug arm-eabi-ld arm-eabi-readelf xmlwf
$
$ file /storage/software/android/custom/sources/android-lgp769v21b/linux-x86/toolchain/arm-eabi-4.4.3/bin/arm-eabi-gcc
ELF 32-bit LSB executable, Intel 80386, version 1 (SYSV), dynamically linked (uses shared libs), for GNU/Linux 2.6.8, not stripped
$
any one know why i would get this on a 64-bit machine with 32-bit dev package installed, or, how to fix it?
thanks in advance

[Q] How to compile gen10 SDE 3 years later?

Hello,
I'm currently trying to build the SDE for my Archos 101XS by following the official instructions in the README files : https://gitorious.org/archos/archos-gpl-gen9/.
When launching the compilation with "make", I get the following error:
Code:
if [ xinfo = xinfo ]; then \
makeinfo --split-size=5000000 --no-split -I . -I /home/nico/archos-gpl-gen9/buildroot/toolchain_build_arm/gcc-4.4.1/gcc/doc \
-I /home/nico/archos-gpl-gen9/buildroot/toolchain_build_arm/gcc-4.4.1/gcc/doc/include -o doc/gcc.info /home/nico/archos-gpl-gen9/buildroot/toolchain_build_arm/gcc-4.4.1/gcc/doc/gcc.texi; \
fi
/home/nico/archos-gpl-gen9/buildroot/toolchain_build_arm/gcc-4.4.1/gcc/doc/cppopts.texi:761: @itemx must follow @item
Makefile:3891: recipe for target 'doc/cpp.info' failed
make[2]: *** [doc/cpp.info] Error 1
This seems to be this GCC bug : https://gcc.gnu.org/bugzilla/show_bug.cgi?id=60961 and I didn't manage to resolve it…
I can get past this error with "make -i" and finish all steps successfully (I had to symlink linux-ics to linux at some point), but then my SDE won't boot with the initramfs and zImage files created.
If anyone has a solution, thanks in advance.

v8_mksnapshot.arm: No such file or directory?

Hi folks,
(New to the forums, tho I've been reading a bit...)
I'm trying to build the Copperhead OS version of Android (marshmallow, for a 2014 Nexus 5) and have run into an issue that I can't seem to get around. Everything seems fine until I get to this:
Code:
target Generated: libv8 <= out/host/linux-x86/bin/v8_mksnapshot.arm
/bin/bash: out/host/linux-x86/bin/v8_mksnapshot.arm: No such file or directory
make: *** [out/target/product/generic/gen/STATIC_LIBRARIES/libv8_intermediates/snapshot_arm.cc] Error 127
...which kills the build. I've been through the makefile in 'external/v8/Android.mksnapshot.mk', which seems to be controlling this part of the build, but as far as I can tell the name of the right src to compile is generated on the fly -- and I don't know enough about this to work past it in a reasonable amount of time. Any hints?
Thanks!
-j
Actually, it looks like the thing that's missing (v8_mksnapshot.arm) is what's used to compile generated source -- the compiler isn't complaining about the generated source itself:
Code:
# Generate snapshot.cc
ifeq ($(ENABLE_V8_SNAPSHOT),true)
SNAP_GEN := $(generated_sources)/snapshot_$(TARGET_ARCH).cc
MKSNAPSHOT := $(HOST_OUT_EXECUTABLES)/v8_mksnapshot.$(TARGET_ARCH)
$(SNAP_GEN): PRIVATE_CUSTOM_TOOL = $(HOST_OUT_EXECUTABLES)/v8_mksnapshot.$(TARGET_ARCH) --log-snapshot-positions --logfile $(dir [email protected])/v8-snapshot_$(TARGET_ARCH).log [email protected]
$(SNAP_GEN): $(MKSNAPSHOT)
$(transform-generated-source)
LOCAL_GENERATED_SOURCES_$(TARGET_ARCH) += $(SNAP_GEN)
...except that 'v8_mksnapshot.arm' is definitely in 'out/host/linux-x86/bin/'. When I try to run that executable:
Code:
[email protected]:/deploy/copperheados-marshmallow-release$ ./out/host/linux-x86/bin/v8_mksnapshot.arm
-bash: ./out/host/linux-x86/bin/v8_mksnapshot.arm: No such file or directory
[email protected]:/deploy/copperheados-marshmallow-release$ ls -l ./out/host/linux-x86/bin/v8_mksnapshot.arm
-rwxr-xr-x 1 admin admin 181048624 Sep 17 15:34 ./out/host/linux-x86/bin/v8_mksnapshot.arm
That usually means some library on which the executable depends is missing.

Categories

Resources