Hi! How the best way to produce object file (somel...
# kotlin-native
r
Hi! How the best way to produce object file (somelib.o)? I trying this way:
Copy code
kotlinc -opt ./file.kt -o file -produce bitcode
llc -filetype=obj file.bc -o file.o
But it does not include standard library and result of
Copy code
cc
compilation is:
Copy code
/usr/bin/ld: file.o: relocation R_X86_64_32 against undefined symbol `ktype:kotlin.text.StringBuilder' can not be used when making a shared object; recompile with -fPIC
o
-produce static
r
not documented key, or simply fogotten? konanc -help says only:
Copy code
-produce (-p) {program|dynamic|framework|library|bitcode}
o
Just forgotten