3 ms·
Could someone explain why touch program is 47 Kbytes size? Just checked my Ubuntu machine to confirm this.
by hippich 15y ago
Could someone explain why touch program is 47 Kbytes size? Just checked my Ubuntu machine to confirm this.
- mkopinsky 15y agoProbably because it's statically linked with some standard libraries. If you write a hello world app in C++ and compile/link with all the defaults, you'll see similar results.
- deleted 15y ago[deleted]
- beza1e1 15y agoIt is not. It even dynamically links to libpthread ...
- tedunangst 15y agoYou should use OpenBSD, then it's only 10k. As for why, objdump -s gives some hints. Lots of the file is really just zeros (you can see this with hexdump too), and the various sections of the file are padded for alignment.
- pdw 15y agoI think you can blame the GNU `--date` option. It supports many, many possible input formats (http://www.gnu.org/s/coreutils/manual/html_node/Date-input-formats.html http://www.gnu.org/s/coreutils/manual/html_node/Date-input-f...) and the implementation has to be quite complex.