Date: Wed, 09 Oct 2002 01:30:22 -0700 From: Peter Wemm <peter@wemm.org> To: cvs-committers@FreeBSD.org, cvs-all@FreeBSD.org Subject: Re: cvs commit: src/lib/libc/gen Makefile.inc errlst.c errno.c Message-ID: <20021009083022.A07882A88D@canning.wemm.org> In-Reply-To: <200210090804.g9984P12041412@freefall.freebsd.org>
next in thread | previous in thread | raw e-mail | index | archive | help
Peter Wemm wrote:
> peter 2002/10/09 01:04:24 PDT
>
> Modified files:
> lib/libc/gen Makefile.inc errlst.c
> Added files:
> lib/libc/gen errno.c
> Log:
> Drop almost 3k from /bin/sync by moving errno to a seperate file
> to avoid all syscalls pulling in sys_errlst[].
>
> Noted by: bde
And the following change to src/bin/sync.c gets the installed binary
from 13K down to ~2.3K (854 bytes text, 36 bytes data, 36 bytes bss on
i386, but this should world on all our platforms still). I can't
believe I did this...
Index: sync.c
===================================================================
RCS file: /home/ncvs/src/bin/sync/sync.c,v
retrieving revision 1.13
diff -u -r1.13 sync.c
--- sync.c 2002/06/30 05:15:05 1.13
+++ sync.c 2002/10/09 08:26:22
@@ -54,3 +54,15 @@
sync();
exit(0);
}
+
+void
+exit(int ret)
+{
+ _exit(ret);
+}
+
+int
+atexit(void (*func)(void))
+{
+ return (0);
+}
Cheers,
-Peter
--
Peter Wemm - peter@wemm.org; peter@FreeBSD.org; peter@yahoo-inc.com
"All of this is for nothing if we don't go to the stars" - JMS/B5
To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe cvs-all" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20021009083022.A07882A88D>
