Hello All,
I tried to the following and got nowhere.
1- Opened Project Builder and selected a new project
2- selected the "C++ Tool" for the project type
3- I got a project with "main.cpp" file
4- This file contained the following code:
---
#include <iostream>
int main (int argc, const char * argv[]) {
// insert code here...
std::cout << "Hello, World!\n";
return 0;
}
---
5- I select Build from the Build Menu and get the following error
---
main.cpp:1: iostream: No such file or directory
main.cpp: In function `int main(int, const char **)':
main.cpp:5: `::cout' undeclared (first use here)
---
6- I checked under the "External Frameworks and Libraries" and "libstdc++.a" is checked.
Why am I getting this error? This file is generated by ProjectBuilder itself without me adding anything to it.
Thank you.
I tried to the following and got nowhere.
1- Opened Project Builder and selected a new project
2- selected the "C++ Tool" for the project type
3- I got a project with "main.cpp" file
4- This file contained the following code:
---
#include <iostream>
int main (int argc, const char * argv[]) {
// insert code here...
std::cout << "Hello, World!\n";
return 0;
}
---
5- I select Build from the Build Menu and get the following error
---
main.cpp:1: iostream: No such file or directory
main.cpp: In function `int main(int, const char **)':
main.cpp:5: `::cout' undeclared (first use here)
---
6- I checked under the "External Frameworks and Libraries" and "libstdc++.a" is checked.
Why am I getting this error? This file is generated by ProjectBuilder itself without me adding anything to it.
Thank you.