Why icpc need the library file crtxi.o

Why icpc need the library file crtxi.o

I've installed Intel C++ Compiler 11.1 on Gentoo Linux, icc works well. But when a package use icpc to compile a test program, it failed.

The test program is very simple, code is:

       /* confdefs.h.  */
#define PACKAGE_NAME ""
#define PACKAGE_TARNAME ""
#define PACKAGE_VERSION ""
#define PACKAGE_STRING ""
#define PACKAGE_BUGREPORT ""
/* end confdefs.h.  */


int main() {
  return 0;
}

Compile with command:icpc -o conftest -O2 -xSSE4.2 -ip -gcc -Wl,-O1 conftest.cpp >&5

icpc give 2 warning and one error:
icpc: warning #10001: could not find directory in which the set of libstdc++ include files resides
icpc: warning #10047: reverting to Intel libraries and includes
ld: //opt/intel/Compiler/11.1/046/lib/ia32/crtxi.o: No such file: No such file or directory

I've install libstdc++ 3.3, and the file libstdc++.so.5 in directory /usr/lib/; I couldn't find the crtxi.o in the icc installation directory.

5 posts / 0 new
Last post
For more complete information about compiler optimizations, see our Optimization Notice.

I can compile and run on Ubuntu 8.x and RHLES 5.xwithout any issue. It could be that the compiler is not installed properly.

Could you compile a "hello world" program?

Om

Quoting - Om Sachan (Intel)

Could you compile a "hello world" program?

Under both g++ and icpc? I suppose icpc may be depending on g++ to show where libstdc++ is installed. Do you set the environment variables in the supported way, using the iccvars script, or do you skip some of that?

Quoting - tim18
Under both g++ and icpc? I suppose icpc may be depending on g++ to show where libstdc++ is installed. Do you set the environment variables in the supported way, using the iccvars script, or do you skip some of that?

I call the shell file with ia32 parameter in my profile. Since icc works well, I don't think that's the point.

And yesterday I reinstall a "clean" Gentoo and icc, but still the same error.

I test a very simple program, named it as empty.cpp with this code

int main() {
    return 0;
}

Complied without any flags using "icpc empty.cpp" or "icc empty.cpp", I got the same error. But if I rename it to "empty.c", compile is ok.

I wonder 2 things:

1.Where the icc find the "libstdc++ include files"?

2.Why it request the file crtxi.o? I googled, it seems it's a library file in Intel Fortran Compiler or old version icc, but not in my install directory.

Login to leave a comment.