How can I cross compile for android using ndk?
xeome opened this issue · comments
I'm not familiar with the configure script this project is using, how do I cross compile for android(arm) using ndk?
I want to statically compile my project which uses libxdp and run on AOSP.
All the build variables set in the configure script are overridable from
the command line. See the list in check_toolchain():
: ${PKG_CONFIG:=pkg-config}
: ${CC=gcc}
: ${LD=ld}
: ${OBJCOPY=objcopy}
: ${CLANG=clang}
: ${LLC=llc}
: ${M4=m4}
: ${EMACS=emacs}
: ${BPFTOOL=bpftool}
: ${READELF=readelf}
: ${ARCH_INCLUDES=}
: ${ARCH_NAME=}
They can be set in the environment when running configure, like:
CC=/my/cross/compiler/cc ./configure
No idea if anything else is needed for cross-compiling...