www.delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1996/02/08/20:42:10

Date: Thu, 8 Feb 1996 19:41:10 CST (-0600)
To: djgpp AT delorie DOT com
From: Mail Delivery Subsystem <MAILER-DAEMON AT email4 DOT starnetinc DOT com> (by way of cameronbuschardt <c027319 AT mailc DOT starnetinc DOT com>)
Subject: Returned mail: Host unknown (Name server: djgpp.com: host not
found)

   At 06:36 PM 2/7/96 -0500, you wrote:
   >   Date: Wed, 7 Feb 1996 16:20:14 CST (-0600)
   >   From: cameronbuschardt <c027319 AT email4 DOT starnetinc DOT com>
   >
   >   At 02:49 PM 2/7/96 -0500, you wrote:
   >   Thanx.. and one more question how come :
   >   ..
   >   long variable[1000000];
   >
   >   main()
   >   {
   >   ...
   >   }
   >   creates a 4mb exe!? is there a way to avoid this?
   >   and how come
   >   ..
   >   main()
   >   {
   >   long variable [1000000];
   >   }
   >
   >   Gives me a runtime error? is it a bug?
   >
<STUFF REMOVED>
>
>   My command line was "GCC file.cc libgpp.a" and a couple of other libs..
>   And I am using v2 official release...
>
>AHA!  If you name a library like that (rather than in a '-l' option) the entire
>library gets included in the executable!  There is where your 1MB .exe comes
>from!  With the '-l' option the linker searches the library for required
>symbols only yielding a MUCH smaller .exe.  Also unlike commercial DOS
>compilers, GCC follows the UNIX standard and if no '-o' option is present
>produces an executable called "a.out".
>
>Try:
>
>gcc -o file file.cc -lgpp
>
>-- 
>Art S. Kagel, kagel AT quasar DOT bloomberg DOT com
>
>A proverb is no proverb to you 'till life has illustrated it.  -- John Keats
>
I think I just found one minster of a bug...
try:
main.cc
#include <iostream.h>

int largvar[1000000]
main()
{
return 0;
}

then compile via: GCC -o main.cc -lgpp: it deletes main.cc!!????
then try gcc main.cc with any params and it make a 2-4mb exe!!!

This bug only appears on IBMs (and it is on the latest release.


- Raw text -


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