PRB: Cannot Open Compiler Intermediate File
Article ID: 114334
Article Last Modified on 12/2/2003
APPLIES TO
- Microsoft Visual C++ 1.0 Professional Edition
- Microsoft Visual C++ 1.5 Professional Edition
- Microsoft Visual C++ 1.51
- Microsoft Visual C++ 1.52 Professional Edition
- Microsoft Visual C++ 1.0 Professional Edition
- Microsoft Visual C++ 2.0 Professional Edition
- Microsoft Visual C++ 2.1
- Microsoft Visual C++ 2.2
- Microsoft Visual C++ 4.0 Standard Edition
- Microsoft Visual C++ 4.1 Subscription
- Microsoft Visual C++ 4.2 Professional Edition
- Microsoft Visual C++ 5.0 Standard Edition
- Microsoft Visual C++ 6.0 Service Pack 5
This article was previously published under Q114334
SYMPTOMS
The following error occurs when compiling a file with the Visual C++
compiler:
fatal error C1083: Cannot open compiler intermediate file:
'<tmp directory>;\<tmpfile>': Invalid argument
fatal error C1083: Cannot open compiler intermediate file:
'<tmp directory>;\<tmpfile>': No such file or
directory
CAUSE
The error is caused by a semicolon at the end of the TMP environment
variable. For example:
TMP=C:\TMP;
RESOLUTION
The correct way to set up the TMP environment variable from the
command line is as follows:
C:\>SET TMP=C:\TMP
MORE INFORMATION
It is important that the environment string does not end with a
semicolon (;) because the compiler appends the intermediate filename
to the TMP path. By removing the semicolon from the path, the
compiler can create the file correctly.
In addition, the TMP variable should be a fully qualified path and
not a relative path. For example C:TMP may cause the compiler to
issue similar errors, but C:\TMP will always work correctly. The TMP
environment variable should also be set to a drive that has sufficient
space for the compiler's temporary files.
Keywords: kbprb kbcompiler KB114334