Intel® C++ Compiler
Community support and assistance for creating C++ code that runs on platforms based on Intel® processors.

stdc++ does not work with iclc on Ubuntu Linux 13

Juan_Jose_Garcia_Rip
610 Views

I know that 13.10 is not actually supported, but the machine I work with was upgraded and there is no going back :-/  So I am trying to work with Intel Composer C++ 2013 XE Update 1 which was already installed there, and the compiler is not able to build anything that uses the C++ interface to the C library, such as #include <ctime> or #include <cstdlib> It always finishes up with

/usr/include/c++/4.8/cstdlib(41): catastrophic error: cannot open source file "bits/c++config.h"  #include <bits/c++config.h>

The missing file is located here

/usr/include/x86_64-linux-gnu/c++/4.7/bits/c++config.h
/usr/include/x86_64-linux-gnu/c++/4.8/bits/c++config.h

and indeed these paths are outside what iclc searches for

.
 /opt/intel/composer_xe_2013.3.163/mkl/include
 /opt/intel/composer_xe_2013.3.163/mkl/include
 /opt/intel/composer_xe_2013.3.163/mkl/include
 /opt/intel/composer_xe_2013.3.163/tbb/include
 /opt/intel/composer_xe_2013.3.163/mkl/include
 /opt/intel/composer_xe_2013.3.163/compiler/include/intel64
 /opt/intel/composer_xe_2013.3.163/compiler/include
 /usr/include/c++/4.8
 /usr/include/c++/4.8/x86_64-linux-gnu
 /usr/include/c++/4.8/backward
 /usr/local/include
 /usr/lib/gcc/x86_64-linux-gnu/4.8/include
 /usr/lib/gcc/x86_64-linux-gnu/4.8/include-fixed
 /usr/include
 /usr/include/x86_64-linux-gnu

I know that you are going to tell me that I should add the path to the build options, but this is a hack that was not needed prior to this upgrade, so I am looking for a more consistent fix that does not break with every minor change to the libraries.

Juanjo

 

0 Kudos
4 Replies
Juan_Jose_Garcia_Rip
610 Views

Just for completeness and because it might not be clear in the previous message, the code builds fine with Ubuntu 12.04. It is just that icpc cannot find the headers in Ubuntu 13.10

0 Kudos
Juan_Jose_Garcia_Rip
610 Views

A horrible hack just for the record

sudo ln -s /usr/include/x86_64-linux-gnu/c++/4.8 /usr/include/c++/4.8/x86_64-linux-gnu

0 Kudos
TimP
Honored Contributor III
610 Views

Juan Jose Garcia Ripoll wrote:

sudo ln -s /usr/include/x86_64-linux-gnu/c++/4.8 /usr/include/c++/4.8/x86_64-linux-gnu

IMO it's reasonable to expect icpc to use the same headers used by the g++ present on PATH (which g++).  I can't see from your posts whether this is the case.  I don't know why icpc would be using the symlink you propose here if it were not proposed by g++.

As you are using a newer Ubuntu than those identified as "supported," if Ubuntu has made some inscrutable change, it's not reasonable to expect icpc to deal with it.  If you want the Intel compiler team to investigate, you could submit a reproducer on your premier.intel.com account.

0 Kudos
Melanie_B_Intel
Employee
610 Views

This looks like the same issue as reported here, http://software.intel.com/en-us/forums/topic/489013

0 Kudos
Reply