radare2/mk/android.mk

68 lines
1.3 KiB
Makefile
Raw Normal View History

# Ugly yet that's the path inside dockcross
ifeq (${PATH},"/usr/arm-linux-androideabi/bin/${ARCH}-linux-androideabi-gcc")
CC=${ARCH}-linux-androideabi-gcc
RANLIB={ARCH}-linux-androideabi-ranlib
USERCC=${ARCH}-linux-androideabi-gcc -fPIC -fPIE
else
CC=ndk-gcc -fPIC -fPIE
#RANLIB=ndk-ranlib
USERCC=ndk-gcc -fPIC -fPIE
endif
ARCH=arm
2014-11-10 18:46:19 +00:00
ifeq (${NDK_ARCH},x86)
# mips
ARCH2=i686
RANLIB=${ARCH2}-linux-android-ranlib
2016-12-10 00:39:27 +00:00
AR=${ARCH2}-linux-android-ar
CC_AR=${AR} -r ${LIBAR}
2014-11-10 18:46:19 +00:00
endif
2014-11-11 01:14:19 +00:00
2014-11-10 18:46:19 +00:00
ifeq (${NDK_ARCH},mips)
# mips
ARCH2=mipsel
2014-11-11 01:24:09 +00:00
RANLIB=${ARCH2}-linux-android-ranlib
2016-12-10 00:39:27 +00:00
AR=${ARCH2}-linux-android-ar
CC_AR=${AR} -r ${LIBAR}
2014-11-10 18:46:19 +00:00
endif
2014-11-11 00:30:54 +00:00
ifeq (${NDK_ARCH},mips64)
# mips
ARCH2=mips64el
RANLIB=${ARCH2}-linux-android-ranlib
2016-12-10 00:39:27 +00:00
AR=${ARCH2}-linux-android-ar
CC_AR=${AR} -r ${LIBAR}
2014-11-11 00:30:54 +00:00
endif
ifeq (${NDK_ARCH},arm)
2014-11-10 00:09:38 +00:00
# arm32
ARCH=arm
RANLIB=${ARCH}-linux-androideabi-ranlib
2016-12-10 00:39:27 +00:00
AR=${ARCH}-linux-androideabi-ar
CC_AR=${AR} -r ${LIBAR}
endif
2014-11-10 00:09:38 +00:00
ifeq (${NDK_ARCH},aarch64)
2014-11-10 00:09:38 +00:00
# aarch64
ARCH=aarch64
RANLIB=${ARCH}-linux-android-ranlib
2016-12-10 00:39:27 +00:00
AR=${ARCH}-linux-android-ar
CC_AR=${AR} -r ${LIBAR}
2014-11-10 00:09:38 +00:00
endif
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