*BSD News Article 75815


Return to BSD News archive

Path: euryale.cc.adfa.oz.au!newshost.carno.net.au!harbinger.cc.monash.edu.au!nntp.coast.net!swidir.switch.ch!01-newsfeed.univie.ac.at!Austria.EU.net!EU.net!newsfeed.internetmci.com!in2.uu.net!news.va.pubnix.com!not-for-mail
From: lidl@va.pubnix.com (Kurt J. Lidl)
Newsgroups: comp.unix.bsd.bsdi.misc
Subject: Re: large executables!
Date: 9 Aug 1996 18:40:13 -0400
Organization: UUNET Technologies -- Fairfax, Virginia, USA
Lines: 36
Message-ID: <4ugeod$91g@arrow.va.pubnix.com>
References: <4ufg5p$1k2@fnord.dfw.net>
NNTP-Posting-Host: arrow.va.pubnix.com

In article <4ufg5p$1k2@fnord.dfw.net>, Mark Blythe <blythe@dfw.dfw.net> wrote:
>I use an ISP who runs on a BSDI system.  This is my first experience
>with BSDI, although I've been a UNIX C/C++ programmer for several years.
>After programming on this BSDI system for a few months, I'm quite
>alarmed at the size of the executables I'm generating.

Are you sure you are operating the compilers properly?

lidl@arrow-59: cat > hello.c
#include <stdio.h>

main() { printf ("hello world!\n"); exit(0); }

lidl@arrow-60: shlicc hello.c
lidl@arrow-61: size a.out
text    data    bss     dec     hex
212     0       0       212     d4
lidl@arrow-62: ls -l a.out
-rwxr-xr-x  1 lidl  wheel  599 Aug  9 18:38 a.out*
lidl@arrow-63: shlicc2 hello.c
lidl@arrow-64: size a.out
text    data    bss     dec     hex
372     0       20      392     188
lidl@arrow-65: ls -l a.out
-rwxr-xr-x  1 lidl  wheel  988 Aug  9 18:39 a.out*

>Does anyone have any tips on how to generate smaller program files?
>His OS reports itself as "2.1 BSDI BSD/OS 2.1 Kernel #2" through
>uname -a.

Use shlicc or shlicc2.  It has a useful man page.

-Kurt
-- 
/* Kurt J. Lidl (lidl@va.pubnix.com) UUCP: <Earth>!uunet!lidl */
/*   Don't confuse my opinions with my employer's opinions!   */