xen-devel.lists.xenproject.org archive mirror
 help / color / mirror / Atom feed
From: Ian Campbell <ian.campbell@citrix.com>
To: anshul makkar <anshulmakkar@gmail.com>
Cc: Dario Faggioli <dario.faggioli@citrix.com>,
	xen-devel@lists.xen.org, s.kalaga@samsung.com
Subject: Re: Running android on Dom U. on ARM Cubieboard2.
Date: Wed, 20 Aug 2014 18:26:00 +0100	[thread overview]
Message-ID: <1408555560.16955.11.camel@hastur.hellion.org.uk> (raw)
In-Reply-To: <CACZDEvFXNCmhTvVpYQdLiiHfwBU2FBae6sxAP5RdFchCSCUgQw@mail.gmail.com>

On Wed, 2014-08-20 at 17:00 +0200, anshul makkar wrote:

Please can you not top post, it makes threads rather hard to follow.

[...]
> > But if Dom0 has to be Android, the toolstack needs to be built
> > for/within Android's userspace, which I don't think is something that
> > has been done before.
> >
> > Actually, this is something I always wanted to try, but never got the
> > time to do so. Ian seems (from this message [1]) to at least have
> > glanced at it also, but probably nothing more than that (Ian?).

I poked at it a bit, but ultimately building C code as part of AOSP
(e.g.to build the Xen tools and their deps) seems to be a massive pain
in the ars^wneck. You effectively need a complete parallel Android.mk
build system.

I messed around for a bit getting libfdt and yajl to build in that
context based on some github repos I found, but that was all, I never
managed to figure out how to even start building something more complex
like the Xen tools without rewriting the build system (there was some
other roadblock tool, but I can't remember what it was)

FWIW my "Android.txt" from my scratch dir is below, no warranty etc. I
expect it is mostly useless as a starting point.

Obviously I'd love it if someone else could figure this stuff out ;-)

Ian.
----

http://gerdmestdagh.wordpress.com/2010/12/30/android-native-library-howto/
https://thenewcircle.com/s/post/1044/remixing_android

http://stackoverflow.com/questions/5856383/how-do-i-compile-simple-native-code-using-android-mk
---------------------------------------------------------------------
AOSP
---------------------------------------------------------------------
https://source.android.com/

curl http://commondatastorage.googleapis.com/git-repo-downloads/repo > bin/repo
export PATH=$(pwd)/bin:$PATH
mkdir working
cd working
repo init -u https://android.googlesource.com/platform/manifest
repo sync

export USE_CCACHE=1
export EXPERIMENTAL_USE_JAVA7=y
export PS1="[aosp] $PS1"

lunch aosp_arm-eng
nice make -j4 EXPERIMENTAL_USE_JAVA7=y

NEW LIBRARIES:
libfdt
------
git clone git://git.kernel.org/pub/scm/utils/dtc/dtc.git external/dtc
https://github.com/sonyxperiadev/mkqcdtbootimg/blob/master/libfdt/Android.mk

Android.mk is included automatically by the build system.
LOCAL_PATH:= $(call my-dir)

include $(CLEAR_VARS)
LOCAL_SRC_FILES := \
	libfdt/fdt.c \
	libfdt/fdt_ro.c \
	libfdt/fdt_wip.c \
	libfdt/fdt_sw.c \
	libfdt/fdt_rw.c \
	libfdt/fdt_strerror.c \
	libfdt/fdt_empty_tree.c
LOCAL_C_INCLUDES := $(LOCAL_PATH)/libfdt
LOCAL_COPY_HEADERS := libfdt/fdt.h libfdt/libfdt.h libfdt/libfdt_env.h
LOCAL_MODULE := libfdt

include $(BUILD_SHARED_LIBRARY)

List libfdt in build/target/product/runtime_common.mk

libyajl
-------
http://lloyd.github.io/yajl/
https://github.com/stubma/WiEngine/blob/master/jni/yajl/Android.mk

git clone git://github.com/lloyd/yajl external/yajl

---------------------------------------------------------------------
NDK
---------------------------------------------------------------------
https://developer.android.com/tools/sdk/ndk/index.html

wget http://dl.google.com/android/ndk/android-ndk-r9d-linux-x86_64.tar.bz2
tar xaf android-ndk-r9d-linux-x86_64.tar.bz2 

  reply	other threads:[~2014-08-20 17:26 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-08-18 10:54 Running android on Dom U. on ARM Cubieboard2 anshul makkar
2014-08-20  8:52 ` anshul makkar
2014-08-20 14:16   ` Dario Faggioli
2014-08-20 15:00     ` anshul makkar
2014-08-20 17:26       ` Ian Campbell [this message]
2014-08-21 17:19         ` Dario Faggioli

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1408555560.16955.11.camel@hastur.hellion.org.uk \
    --to=ian.campbell@citrix.com \
    --cc=anshulmakkar@gmail.com \
    --cc=dario.faggioli@citrix.com \
    --cc=s.kalaga@samsung.com \
    --cc=xen-devel@lists.xen.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).