开发者

Digital Mars - unable to open input file 'iostream'

I'm using "Digital Mars" to compile the following program:

#include <iostream>
using namespace std;

int main() {
   cout <<"My name is 开发者_运维问答Abder-Rahman";
   return 0;
}

And, this is what I get:

C:\Users\Software Engineer\Desktop\C++\dm852c\dm\bin>dmc print1 Fatal error: unable to open input file 'iostream' --- errorlevel 1

Any ideas on that?

Thanks.


Check VernonDozier answer about this problem:

The code is fine. Your compiler installation is probably broken. You have a bad include path, permissions problems, or you have files missing.

Your compiler is probably misconfigured. I recommend you to read this post.


Modify file sc.ini in c:\dm\bin as follows then save it

[Version]
version=857

[Environment]
PATH=%PATH%;"%@P%\..\bin"
BIN="%@P%\..\bin"
INCLUDE="%@P%\..\stlport\stlport";"%@P%\..\include";"%@P%\..\mfc\include";%INCLUDE%
;INCLUDE="%@P%\..\include";"%@P%\..\mfc\include";%INCLUDE%
LIB="%@P%\..\lib";"%@P%\..\mfc\lib";%LIB%
HELP="%@P%\..\help"


I know that is is too late for an answer but in case someone (like me) likes using Digital Mars and lands here, you can use sc filename.cpp -Ic:\path\where\stlport, where the I is capital, there is no space between the -I and the path where STLport 4.5.3 was extracted.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜