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

can not build cmake-3.14.5 with Intel compiler 19.0.4

Hanousek__Petr
Beginner
1,005 Views
I am trying to use the last version of Intel compiler to build the last version of cmake on Debian9. Getting stuck on this:

export CC=icc 
export CFLAGS="-fPIC -msse4.1 -axAVX,CORE-AVX2" 
export CXX=icpc 
export CXXFLAGS="-fPIC -msse4.1 -axAVX,CORE-AVX2" 
./configure --verbose 
make

[ 68%] Building CXX object Source/CMakeFiles/CMakeLib.dir/cmQtAutoGeneratorMocUic.cxx.o
cd /scratch/cmake-3.14.5/Source && /software/intel-parallel-studio/cluster.2019.4/intel-19.0.4/compilers_and_libraries_2019.4.243/linux/bin/intel64/icpc  -DCMAKE_BUILD_WITH_CMAKE -DCURL_STATICLIB -DLIBARCHIVE_STATIC -I/scratch/cmake-3.14.5/Utilities -I/scratch/cmake-3.14.5/Source -I/scratch/cmake-3.14.5/Source/LexerParser -I/scratch/cmake-3.14.5/Utilities/cmcompress -I/scratch/cmake-3.14.5/Source/CTest -I/scratch/cmake-3.14.5/Source/CPack  -fPIC -msse4.1 -axAVX,CORE-AVX2   -std=gnu++17 -o CMakeFiles/CMakeLib.dir/cmQtAutoGeneratorMocUic.cxx.o -c /scratch/cmake-3.14.5/Source/cmQtAutoGeneratorMocUic.cxx

/scratch/cmake-3.14.5/Source/cmOrderDirectories.cxx(430): remark #15009: _ZN18cmOrderDirectories13FindConflictsEv has been targeted for automatic cpu dispatch

/usr/include/c++/6.3.0/bits/stl_algo.h(1839): remark #15009: ZSt16__insertion_sortIN9__gnu_cxx17__normal_iteratorIPSt4pairIiiESt6vectorIS3_SaIS3_EEEENS0_5__ops15_Iter_less_iterEEvT_SB_T0 has been targeted for automatic cpu dispatch

/usr/include/c++/6.3.0/bits/stl_algobase.h(750): remark #15009: ZSt10__fill_n_aIPcmiEN9__gnu_cxx11__enable_ifIXsr3std11__is_scalarIT1_EE7__valueET_E6__typeES4_T0_RKS3 has been targeted for automatic cpu dispatch

/usr/include/c++/6.3.0/type_traits(2505): error: class "std::__result_of_impl<false, false, std::_Mem_fn<void (cmQtAutoGeneratorMocUic::WorkerT::*)()>, cmQtAutoGeneratorMocUic::WorkerT *>" has no member class "type"

When I remove the -std=gnu++17 directive the compilation goes without error. Is this the bug of the compiler or the code?

Thank you, Petr

0 Kudos
2 Replies
Viet_H_Intel
Moderator
1,005 Views

Neither one. C++17 doesn't allow class w/o member class "type"

0 Kudos
Hanousek__Petr
Beginner
1,005 Views

Thank you Viet,

so it looks like a configuration problem to avoid compiling this file with gnu++17 directive. However I tried to build it once again on system with newer gcc and it passed ok. Why Icc depends on gcc in some way as is mentioned in the error log?

0 Kudos
Reply