Live data from Hacker News

Sta.li: Static Linux

sta.li

1–10 of 99 posts

Re: Sta.li: Static Linux

#3
"The reason why dynamic linking has been invented was not to decrease the general executable sizes or to save memory consumption, or to speed up the exec() -- but to allow changing code during runtime -- and that's the real purpose of dynamic linking, we shouldn't forget that."

Not sure about "changing code during runtime", but one of the great benefits of dynamic-link libraries are for writing plugins. And I don't think it would take much time for an app to look up its own plugin folder.

Re: Sta.li: Static Linux

#5

It's an admirable initiative, but I'm pretty sure that at this point sta.li has been in the "design phase" for years. It's vaporware. I'd love to be proven wrong, though.

© 2006-2013 for something still not released certainly isn't promising. Glancing at the git logs (http://git.suckless.org/?s=idle) there is some ongoing work, so the project isn't totally dead at least.

Re: Sta.li: Static Linux

#8
From the FAQ:

"Also a security issue with dynamically linked libraries are executables with the suid flag. A user can easily run dynamic library code using LD_PRELOAD in conjunction with some trivial program like ping. Using a static executable with the suid flag eliminates this problem completely."

Have the authors actually tried this? Using LD_PRELOAD with suid programs won't work.

Re: Sta.li: Static Linux

#9
On binary sizes:

> Linking a stripped hello world program with glibc results in 600kb. Linking it with uclibc in about 7kb.

That's nice for uclibc, but we're typically linking dynamically. The comparison should be between dynamically and statically linked binaries. A stripped and dynamically linked hello world results in a 6kb program on my machine (glibc).

There's also a lot of handwaving on memory usage in the FAQ.

Re: Sta.li: Static Linux

#10
I'm puzzled by the idea of a system being leaner/faster with n copies of a library in physical RAM rather than 1 copy mapped via VMM into whatever process wants it. IIRC this was the main point of shared libraries, not pluggability or changing code during runtime. Am I missing something?
Post reply on HN