forked from ColinIanKing/stress-ng
-
Notifications
You must be signed in to change notification settings - Fork 0
/
README.Android
41 lines (28 loc) · 1.04 KB
/
README.Android
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
= Android porting notes =
How to setup a Ubuntu 12.04 machine to cross compile for different architectures.
== Setup ==
Install tools:
sudo apt-get install kernel-package build-essential git gcc-arm-linux-gnueabi gcc-arm-linux-gnueabihf gcc-4.6-multilib-arm-linux-gnueabihf gcc-4.6-multilib-arm-linux-gnueabi
== Environment ==
Ubuntu has a command called ''dpkg-architecture'' which setups up most of the cross compile environment.
64-bit x86:
export $(dpkg-architecture -aamd64)
32-bit x86:
export $(dpkg-architecture -ai386)
armhf (RaspberryPi/uPC):
export $(dpkg-architecture -aarmhf)
export CROSS_COMPILE=arm-linux-gnueabihf-
export CCPREFIX=${CROSS_COMPILE}
armel:
export $(dpkg-architecture -aarmel)
export CROSS_COMPILE=arm-linux-gnueabi-
export CCPREFIX=${CROSS_COMPILE}
Shared Variables:
export CONCURRENCY_LEVEL=`grep -c '^processor' /proc/cpuinfo`
export ROOT_CMD=fakeroot
== Build ==
#Make
export CC=${CROSS_COMPILE}
STATIC=1 make ARCH=arm
M.Srikanth Kumar, Jul 14, 2015
Colin Ian King, Dec 6, 2016 (updated, static linking)