delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1997/01/21/06:32:48

Date: Tue, 21 Jan 1997 13:16:22 +0200 (IST)
From: Eli Zaretskii <eliz AT is DOT elta DOT co DOT il>
To: Brian Zaugg <zauggb AT cs DOT byu DOT edu>
cc: djgpp AT delorie DOT com
Subject: Re: Need help making standalone with PMODE/DJ--"Program too large to fit in memory"
In-Reply-To: <32E29199.368D@cs.byu.edu>
Message-ID: <Pine.SUN.3.91.970121130840.27230B-100000@is>
MIME-Version: 1.0

On Sun, 19 Jan 1997, Brian Zaugg wrote:

> Then, following the instructions in the PMODE docs,:
> >copy /B pmodstub.exe + who who.exe
> overwrite who.exe?y
> 1 file copied 
> 
> This creates a new executable (who.exe, size 78,205).  Why is the new
> executable the same size as the COFF image?  Didn't I just add a stub or
> something?

Most probably, pmodstub.exe isn't in the directory where you type the
above command.  That's the dumb DOS COPY command you are using, remember? 
It doesn't know how to look for the files you need, it needs you to tell
you where to find pmodstub.  So you should say something like this: 

	copy /b c:\djgpp\bin\pmodstub.exe + who who.exe

(assuming you put pmodstub.exe into c:\djgpp\bin).  Make sure that COPY 
prints the names of *both* pmodstub.exe and who when it copies, because 
if it doesn't find one of the files, it just copies the rest without
any error messages.

> Anyway, then I rename the cwsdpmi files that allowed me to run gcc so
> that they won't be in the way, and run my program:
> >who
> Program too big to fit in memory.

That's because you just effectively copied who into who.exe.  Since who is
raw COFF image, DOS doesn't know how to run it, so it tries to interpret
its beginning as a COM program (because it doesn't have the MZ signature),
with obvious results. 

- Raw text -


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