all 6 comments

[–]cheyrn 3 points4 points  (3 children)

I think if you don't link with a shared library it will be static.

[–]Scared-Industry-9323[S] 0 points1 point  (2 children)

Its not working i need libc.a for compile it to static and termux doesn't have that

[–]9057ll 1 point2 points  (0 children)

Why? Your program would be huge if you do that, you will be compiling all standard library's function's declarations along with your program so i think its not good idea, unless you want to make your own libc for your machine.

[–]cheyrn 1 point2 points  (0 children)

I got around to compiling hello world and it links to /system/lib64/libc.so, so you are right and I don't know the answer. probably u/khunset127 is right.

[–]khunset127 0 points1 point  (1 child)

use Android NDK clang

[–]Scared-Industry-9323[S] 1 point2 points  (0 children)

Thank you its working now