On 10/08/2018 01:52 PM, enh wrote:
> On Sun, Oct 7, 2018 at 6:13 PM Rob Landley <r...@landley.net> wrote:
>>
>> I downloaded the release 18 NDK and installed it:
>>
>>   sudo build/tools/make_standalone_toolchain.py --arch x86_64 --api 28 \
>>     --install-dir /opt/android/x86_64
>>
>> Then in order to build:
>>
>>   export CROSS_COMPILE=/opt/android/x86_64/bin/llvm- LDFLAGS=--static
>>   make distclean
>>   make defconfig
>>   make
>>
>> I need to:
>>
>>   A) add the llvm-cc symlink to clang.
> 
> note that toybox is our example of a non-configure project on
> https://developer.android.com/ndk/guides/standalone_toolchain#building_open_source_projects_using_standalone_toolchains

I saw that, but toybox is designed to build the same way the kernel does, I.E.
one CROSS_COMPILE=prefix- rather than specifying each individual tool.

And it works now with the NDK if you add that symlink. :)

>>   B) disable the android logger because liblog.so doesn't have a
>>      corresponding liblog.a.
> 
> yeah, all the "NDK" libraries are stub .so-only (even the .so files
> just have symbols for build-time linking, no code).

I added another portability.h stanza and I _think_ that covers everything except
the llvm-cc symlink. It still errors about strip not understanding -o but
automatically falls back to copying the unstripped version to the output, and is
thus at least testable.

(And hey, my netbook dying means the machine I'm running it on now has the
x86-64 instruction that was missing in the startup code, so I don't need to run
it under qemu-x86_64 anymore. :)

Rob
_______________________________________________
Toybox mailing list
Toybox@lists.landley.net
http://lists.landley.net/listinfo.cgi/toybox-landley.net

Reply via email to