Open dcam0050 opened 5 years ago
me too!!!when i compile android on macbook pro, report error:
# github.com/ZoneTong/yunxingningmeng
/usr/local/go/pkg/tool/linux_amd64/link: running arm-linux-androideabi-gcc failed: exit status 1
/usr/arm-linux-androideabi-4.9/bin/../sysroot/usr/lib/crtbegin_dynamic.o:crtbrand.c:function _start: error: undefined reference to 'main'
collect2: error: ld returned 1 exit status
2019/11/16 23:13:00 Failed to cross compile package: exit status 2.
make: *** [so] Error 1
Sorry to bring that up, but any ideas on how to fix it or why this did it happen?
I've been trying to compile a simple c-shared library for android but cannot seem to get it to work.
This is the code I'm trying to compile:
This is the command I'm running:
xgo --targets=android/arm --buildmode=c-shared -out android_test ./test
To which I get the following:
Any idea as to what is wrong? And thank you for a great tool!