JetBrains / kotlin-native

Kotlin/Native infrastructure
Apache License 2.0
7.02k stars 566 forks source link

kotlin Cannot run mips/mipsel in LEDE #1217

Closed cooboyno111 closed 6 years ago

cooboyno111 commented 6 years ago

ldd ./program.kexe /lib/ld.so.1 (0x77180000) linux-vdso.so.1 (0x771b1000) libdl.so.2 => not found libm.so.6 => not found libpthread.so.0 => not found libgcc_s.so.1 => not found libc.so.6 => not found

root@LEDE:/tmp# ./program.kexe ./program.kexe: error while loading shared libraries: libdl.so.2: cannot open shared object file: No such file or directory

I configure Lede's running environment for glibc instead of musl. The same compilation condition can be run on armv7。

Compile instruction 1 kotlinc ht.kt -target linux_mipsel32 -opt HC5661/lede/glibc/environment 2 kotlinc ht.kt -target linux_mips32 -opt 3 kotlinc ht.kt -target raspberrypi //can run on netgear R7800/lede/glibc/environment kotlin native 0.4/0.5

olonho commented 6 years ago

We are considering possibility of option to produce statically linked executable, but currently you likely need to provide mentioned libraries for Kotlin/Native compiled programs to run.