Hmm, I'm not sure, all I can say is the cross compiler cannot find the sysroot
This the exact command line I did and it success
\nimcache>arm-linux-androideabi-gcc -I d:/installer/nim/lib hello_android.c
stdlib_system.c -o hello
--sysroot=e:/installer/android/ndk/platforms/android-19/arch-arm
Before I did failed like what you had but because I wrote the sysroot wrong,
before I wrote it `--sysroot=e:/installer/ndk/platforms/android-19/arch-arm` ,
but after recompiled with correct path, it compiled successfully.
My Nim version is still 0.17.2, 64 bit (haven't had a chance to try 0.18.0)
My arm-linux-androideabi-gcc version and its path dependency
arm-linux-androideabi-gcc -v
Using built-in specs.
COLLECT_GCC=arm-linux-androideabi-gcc
COLLECT_LTO_WRAPPER=e:/installer/android/ndk/toolchains/arm-linux-androideabi-4.9/prebuilt/windows-x86_64/bin/../libexec/gcc/arm-linux-androideabi/4.9.x/lto-wrapper.exe
Target: arm-linux-androideabi
Configured with:
/usr/local/google/buildbot/src/android/gcc/toolchain/build/../gcc/gcc-4.9/configure
--prefix=/tmp/54f254f8bb7b48dd787052921220a87d --target=arm-linux-androideabi
--host=x86_64-pc-mingw32msvc --build=x86_64-linux-gnu --with-gnu-as
--with-gnu-ld --enable-languages=c,c++
--with-gmp=/buildbot/tmp/build/toolchain/temp-install
--with-mpfr=/buildbot/tmp/build/toolchain/temp-install
--with-mpc=/buildbot/tmp/build/toolchain/temp-install
--with-cloog=/buildbot/tmp/build/toolchain/temp-install
--with-isl=/buildbot/tmp/build/toolchain/temp-install
--with-ppl=/buildbot/tmp/build/toolchain/temp-install
--disable-ppl-version-check --disable-cloog-version-check
--disable-isl-version-check --enable-cloog-backend=isl
--with-host-libstdcxx='-static-libgcc -static-libstdc++ -lstdc++ -lm -static'
--disable-libssp --enable-threads --disable-nls --disable-libmudflap
--disable-libgomp --disable-libstdc__-v3 --disable-sjlj-exceptions
--disable-shared --disable-tls --disable-libitm --with-float=soft
--with-fpu=vfp --with-arch=armv5te --enable-target-optspace
--enable-bionic-libs --enable-libatomic-ifuncs=no --enable-initfini-array
--disable-nls --prefix=/tmp/54f254f8bb7b48dd787052921220a87d
--with-sysroot=/tmp/54f254f8bb7b48dd787052921220a87d/sysroot
--with-binutils-version=2.25 --with-mpfr-version=3.1.1 --with-mpc-version=1.0.1
--with-gmp-version=5.0.5 --with-gcc-version=4.9 --with-gdb-version=none
--with-gxx-include-dir=/tmp/54f254f8bb7b48dd787052921220a87d/include/c++/4.9.x
--with-bugurl=http://source.android.com/source/report-bugs.html
--enable-languages=c,c++ --disable-bootstrap --enable-plugins --enable-libgomp
--enable-gnu-indirect-function --disable-libsanitizer --enable-gold
--enable-eh-frame-hdr-for-static --enable-graphite=yes
--with-isl-version=0.11.1 --with-cloog-version=0.18.0 --with-arch=armv5te
--program-transform-name='s&^&arm-linux-androideabi-&' --enable-gold=default
Thread model: posix
gcc version 4.9.x 20150123 (prerelease) (GCC)
My system is Windows 10 64 bit