forked from radareorg/radare2
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathandroid.mk
60 lines (53 loc) · 1.02 KB
/
android.mk
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
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
# Ugly yet that's the path inside dockcross
ifeq (${PATH},"/usr/arm-linux-androideabi/bin/${ARCH}-linux-androideabi-gcc")
CC=${ARCH}-linux-androideabi-gcc
USERCC=${ARCH}-linux-androideabi-gcc -fPIC -fPIE
else
CC=ndk-gcc -fPIC -fPIE
USERCC=ndk-gcc -fPIC -fPIE
endif
ARCH=arm
ifeq (${NDK_ARCH},x86)
# mips
ARCH2=i686
CROSS=${ARCH2}-linux-android-
endif
ifeq (${NDK_ARCH},mips)
# mips
ARCH2=mipsel
CROSS=${ARCH2}-linux-android-
endif
ifeq (${NDK_ARCH},mips64)
# mips
ARCH2=mips64el
CROSS=${ARCH2}-linux-android-
endif
ifeq (${NDK_ARCH},arm)
# arm32
ARCH=arm
CROSS=${ARCH}-linux-androideabi-
endif
ifeq (${NDK_ARCH},aarch64)
# aarch64
ARCH=aarch64
CROSS=${ARCH}-linux-android-
endif
RANLIB=${CROSS}ranlib
AR=${CROSS}ar
CC_AR=${AR} -r ${LIBAR}
PARTIALLD=${CROSS}ld -r --whole-archive
ONELIB=0
OSTYPE=android
LINK=
#CC_AR=ndk-ar -r ${LIBAR}
PICFLAGS=-fPIC -fpic
CFLAGS+=${PICFLAGS}
CC_LIB=${CC} -shared -o
CFLAGS_INCLUDE=-I
LDFLAGS_LINK=-l
LDFLAGS_LINKPATH=-L
CFLAGS_OPT0=-O0
CFLAGS_OPT1=-O1
CFLAGS_OPT2=-O2
CFLAGS_OPT3=-O3
CFLAGS_DEBUG=-g