tutorials:cb1:installation:instruction_to_build_openbox_android_4.0.4_tb-box_system_for_cubieboard

This is an old revision of the document!


Instruction To Build Openbox Android 4.0.4 Tv-box System For Cubieboard

About this Article

Abstract

Openbox is based on ics-4.0.4, and with XBMC integrated. And the source code is maintained using git/repo tools. If you want to build android for cubieboard, you at least need to know how to use git and android repo tools(just some basic commands will be okay). Also the recommended building environment is ubuntu 12.04(x86_64). You can reference to Setting up a Linux build environment

Getting Source Code

2 ways to get the source code

From Github

$curl https://raw.github.com/cubieboard/git-repo/stable/repo > ~/bin/repo
$chmod +x ~/bin/repo
$mkdir openbox && cd openbox
$repo init --no-repo-verify -u git://github.com/cubieboard/manifests -b cb -m openbox.xml  
$repo sync

All-In-One Tarball

mkdir -p ~/android/build/Cubieboard
cd ~/android/build/Cubieboard/
wget http://dl.cubieboard.org/software/a10-cubieboard/android/cubieboard_opentv.tar.gz

Now we will check that cubieboard_opentv.tar.gz match what used by that document:

md5sum cubieboard_opentv.tar.gz 
$ -> d36631c98f30ebc0f43eeafeba8201ec  cubieboard_opentv.tar.gz
tar -zxf cubieboard_opentv.tar.gz
cd cubieboard-tv-sdk/

A this point is necessary to fix a but in cubieboard_opentv script and precisely to following file:

nano frameworks/base/media/libstagefright/Android.mk

search LOCAL_STATIC_LIBRARIES and add to list: libstagefright_rtsp \ so you get:

LOCAL_STATIC_LIBRARIES := \
libstagefright_color_conversion \
libstagefright_aacenc \
libstagefright_amrnbenc \
libstagefright_amrwbenc \
libstagefright_avcenc \
libstagefright_m4vh263enc \
libstagefright_matroska \
libstagefright_timedtext \
libvpx \
libstagefright_mpeg2ts \
libstagefright_id3 \
libFLAC \
libstagefright_rtsp \
     ...

Building

$source build/envsetup.sh
$lunch 4 (note: select cubieboard option)
$make -j4
$tools/pack-cm.sh (note: this will generate the final image suitable for livesuit tool)

Install LiveSuit on Linux (64bit)

sudo apt-get install dkms
git clone https://github.com/matson-hall/allwinner-pack-tools.git -b cubieboard
unzip allwinner-pack-tools/tools/Livesuit-linux.zip
chmod +x LiveSuit_For_Linux64/LiveSuit.run
./LiveSuit_For_Linux64/LiveSuit.run #livesuit will be installed to ~/Bin

Flash nand flash on your board

sudo ~/Bin/LiveSuit/LiveSuit.sh #run livesuit
  1. Livesuit GUI will start
  2. Choose the image we built just now (sun4i_linux_cubieboard.img)
  3. Disconnect all power to board, connect USB cable to board side, but not computer, then hold down "usb boot" button on your board, and plug in USB to computer – a new device should be detected. If using a virtual machine you may need to modify your .vmx file to include the "skip reset usb-quirk" option. Instead of this method, you can follow the instructions to get into FEL mode.
  4. It should ask to format the partition first, say yes.
  5. You should see the progress bar increasing.
  6. flashing should complete in about 3-4 minutes

See Also

tutorials/cb1/installation/instruction_to_build_openbox_android_4.0.4_tb-box_system_for_cubieboard.1382717314.txt.gz · Last modified: 2013/12/23 14:50 (external edit)