delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1997/01/08/02:38:34

Date: Wed, 8 Jan 1997 09:32:32 +0200 (IST)
From: Eli Zaretskii <eliz AT is DOT elta DOT co DOT il>
To: "Gautam N. Lad" <gautam AT interlog DOT com>
cc: djgpp AT delorie DOT com
Subject: Re: DJGPP compiles wrong .EXE filename
In-Reply-To: <5auogm$7hn@news.interlog.com>
Message-ID: <Pine.SUN.3.91.970108093056.28968Q-100000@is>
MIME-Version: 1.0

On 8 Jan 1997, Gautam N. Lad wrote:

> When I compile my C++ program and link it to the graphics library,
> instead of the executable file having the same name as the source
> file, it's A.EXE and so is the .OUT file (A.OUT).
> 
> The program works fine, except it keeps doing this.  I think it also
> happened when I tried to compile a single .C program.
> 
> I am compiling like this in C:
> 
> gcc prog.c

a.exe and a.out are the default output filenames in gcc.  You should tell 
gcc the name of the output you want.  To get prog.exe, say this:

	gcc -o prog.exe prog.c

- Raw text -


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