delorie.com/archives/browse.cgi | search |
Date: | Wed, 25 Aug 1999 14:30:41 +0300 (IDT) |
From: | Eli Zaretskii <eliz AT is DOT elta DOT co DOT il> |
X-Sender: | eliz AT is |
To: | Anne Hawson <anne DOT hawson AT virgin DOT net> |
cc: | djgpp AT delorie DOT com |
Subject: | Re: I can't compile with the -O2 switch. |
In-Reply-To: | <7purvn$j7h$1@nclient11-gui.server.virgin.net> |
Message-ID: | <Pine.SUN.3.91.990825142920.2834e-100000@is> |
MIME-Version: | 1.0 |
Reply-To: | djgpp AT delorie DOT com |
X-Mailing-List: | djgpp AT delorie DOT com |
X-Unsubscribes-To: | listserv AT delorie DOT com |
On Tue, 24 Aug 1999, Anne Hawson wrote: > I wanted to compile C++ code into an executable with optimisations. > In this case, it is a tiny program called "keypress.cpp" > (pasted at the end of this message). > It compiles fine with - > > > gxx -o keypress.exe keypress.cpp > but complains with - > > > gxx -O2 keypress.exe keypress.cpp You need to keep the -o as well, like this: gxx -O2 -o keypress.exe keypress.cpp I believe the file README.1ST which comes with DJGPP explains how to invoke the compiler correctly.
webmaster | delorie software privacy |
Copyright © 2019 by DJ Delorie | Updated Jul 2019 |