delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1997/06/19/19:30:21

Date: Fri, 20 Jun 1997 11:32:09 -0700
From: Bill Currie <billc AT blackmagic DOT tait DOT co DOT nz>
Subject: Re: really simple compiler question, please help :)
To: gbaer AT tribune DOT com
Cc: djgpp AT delorie DOT com
Reply-to: billc AT blackmagic DOT tait DOT co DOT nz
Message-id: <33AACCA9.174B@blackmagic.tait.co.nz>
Organization: Tait Electronics NZ
MIME-version: 1.0
References: <33A95FD6 DOT 7E5A AT tribune DOT com>

Gerritt Baer wrote:
> I get a 187k executable even when using the -O option.  am I using the
> wrong thing to compile with?  I do a
> 
> gxx -O -o blah.exe blah.cpp

Put a `-s' on the command line. A lot of the 187k is symbols (will still
be ~100k due to libiostream.a).

> 
> gcc doesnt work at all, it cant find the iostream.h library for some
> reason, is it supposed to work?  If you could reply via email it would
> help me out a bunch, I usually cant find my origianal thread on usenet.
> Thanks a bunch.

gcc DOES work, you just have to include a `-liostream' (or '-liostr' if
under w59 with lfn) at the end of the command line. gxx does this for
you.

Just because you include a header file does NOT mean the libaray will be
linked in (works for the standard C headers because libc is always
linked in for you).

Bill
-- 
Leave others their otherness.

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019