View previous topic :: View next topic |
Author |
Message |
arctica
Joined: 10 Sep 2006 Posts: 146 Location: United Kingdom
|
Posted: Sat Feb 01, 2025 10:33 am Post subject: C++ query |
|
|
Hello
I primarily code in Fortran, but just out of interest I wanted to try the C++ compiler (SCC) via command line and Plato, but cannot get it to work using the easy code below:
Code: | // Your First C++ Program
#include <iostream>
int main() {
std::cout << "Hello World!";
return 0;
}
|
It returns a compile error:
Code: | Compiling and linking file hw1.cpp using SCC.
C:\TEMP\HW1.CPP(3) : fatal 4 - Include file iostream cannot be opened
*** Compilation failed
Compilation or linking failed. |
The include files sit under FTN95 and Fortran has no issues looking for MOD files there
....Silverfrost\FTN95\include
I am sure it is something simple! A basic query I know.
SCC version 4.61, Plato 6.01
Thanks
Lester |
|
Back to top |
|
 |
PaulLaidler Site Admin
Joined: 21 Feb 2005 Posts: 8184 Location: Salford, UK
|
Posted: Sat Feb 01, 2025 10:59 am Post subject: |
|
|
Some changes are required for Win32 whilst iostream is not currently supported for x64.
Code: | #include <iostream.h>
int main() {
cout << "Hello World!";
return 0;
} |
|
|
Back to top |
|
 |
arctica
Joined: 10 Sep 2006 Posts: 146 Location: United Kingdom
|
Posted: Sat Feb 01, 2025 12:55 pm Post subject: |
|
|
Thanks for the information Paul, got things working. |
|
Back to top |
|
 |
|