This is the mail archive of the
gcc-help@gcc.gnu.org
mailing list for the GCC project.
Problems getting g++ to run
- From: "Karl Gangle" <kgangle72 at attbi dot com>
- To: <gcc-help at gcc dot gnu dot org>
- Date: Wed, 5 Mar 2003 17:04:08 -0600
- Subject: Problems getting g++ to run
Hi,
I am trying to compile a c++ program using g++ in Linux. The program is
#include <iostream>
#include <string>
int main() {
string s1( "string1" );
cout << s1 << endl;
return 1;
}
The compiler errors indicate that string, cout, endl, and s1 are not
defined. I think the problem is that the include files are not found. So,
what needs to be done for g++ to find the include file? What environment
variables along with there value need to be set?
What needs to be done to set library environment variable values?
If there are any other things that need to be done to get g++ to work please
let me know.
Thank you.
Karl Gangle