[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH][RFC] New 'true' program

From: Alfred M. Szmidt
Subject: Re: [PATCH][RFC] New 'true' program
Date: Sat, 20 Nov 2004 20:02:34 +0100

   The current true program is an amazing-bloated thing.

As you have seem from the small dicussion, that even your 3.2k is
"bloated".  Point is that 13k is nothing, now if you really need to
save 13k on a system then you should first of all not use the GNU C
library; and secondly, compile everything with -Os.  And if that still
isn't enough, write tight assembler code, with a custom ELF header,
etc.  There are many things one can do to write utterly small

The GNU system and variants are meant for general purpose machines, on
which 13kb doesn't matter; even if it was 1Mb, it wouldn't really

The user comes first on these systems, so for example, users want to
be able to type "true --help" or "true --version" to get information
about true, this makes the binary bigger sine it has to do argument
handling.  Then users want to have those messages in their own
language, so you gotta support that, which adds a bunch of extra calls
to gettext() and friends.  And so on...  When they day ends, you will
have something that users will find useful, and nice, but something
some pedants might find a bit "big and bloated". :-)

   The regular executable is 6.7K, and the stripped version is 3.2K.

You could have saved another couple bytes by using return instead of


reply via email to

[Prev in Thread] Current Thread [Next in Thread]