weixin_39941792 2020-11-29 11:16
浏览 0

Fix build for moab 4.9.2 on gcc8

Our code currently relies on an older version of Moab which has errors that cause it to fail compilation on GCC 8. This patches MOAB to allow it to compile.


5 errors found in build log:
     609      CXX      mbpart.o
     610      CXX      quality.o
     611      CXX      umr.o
     612      CXX      merge.o
     613      CXX      parread.o
     614    mbpart.cpp: In function 'int main(int, char**)':
  >> 615    mbpart.cpp:494:19: error: no match for 'operator<'} and 'std::ostri
            ngstream' {aka 'std::__cxx11::basic_ostringstream<char>'})
     616             std::cerr << tmp_output_file << " : failed to write file."
             << std::endl;
     617             ~~~~~~~~~~^~~~~~~~~~~~~~~~~~
     618    mbpart.cpp:494:19: note: candidate: 'operator<
     619    mbpart.cpp:494:19: note:   no known conversion for argument 2 from
            'std::ostringstream' {aka 'std::__cxx11::basic_ostringstream<char>'
            } to 'int'
     620    In file included from /software/user_tools/centos-7.2.1511/cades-ns
            ed-spack/opt/spack/linux-centos7-x86_64/gcc-4.8.5/gcc-8.2.0-uc6sbum
            ioobdbkw4rwfyn2givi4nyvwq/include/c++/8.2.0/iterator:64,
     621                     from /software/user_tools/centos-7.2.1511/cades-ns
            ed-spack/var/spack/stage/moab-4.9.2-77uuzmj4ofb7z7vz6m25sftyks7p5do
            7/spack-src/src/moab/Range.hpp:167,

     ...

     886    /software/user_tools/centos-7.2.1511/cades-nsed-spack/opt/spack/lin
            ux-centos7-x86_64/gcc-4.8.5/gcc-8.2.0-uc6sbumioobdbkw4rwfyn2givi4ny
            vwq/include/c++/8.2.0/ostream:682:5: note: candidate: 'template<cla ss _ostream class _tp> typename std::enable_if<:__and_ not_> >, std::__is_convertible_to_basi
            c_ostream<_ostream>, std::__is_insertable<typename std::__is_conver tible_to_basic_ostream>::__ostream_type, const _Tp&, void> >::v
            alue, typename std::__is_convertible_to_basic_ostream<_tp>::__ostre
            am_type>::type std::operator< typename std::enable_if<:__and_> >, std::__is_convertible_to_basic_os
            tream<_ostream>, std::__is_insertable<typename std::__is_convertibl e_to_basic_ostream>::__ostream_type, const _Tp&, void> >::value
            , typename std::__is_convertible_to_basic_ostream<_tp>::__ostream_t
            ype>::type std::operator<&; _Tp = std::__cxx11::basic_ostringstream
            <char>]':
     891    mbpart.cpp:494:22:   required from here
  >> 892    /software/user_tools/centos-7.2.1511/cades-nsed-spack/opt/spack/lin
            ux-centos7-x86_64/gcc-4.8.5/gcc-8.2.0-uc6sbumioobdbkw4rwfyn2givi4ny
            vwq/include/c++/8.2.0/ostream:682:5: error: no type named 'type' in
             'struct std::enable_if<false std::basic_ostream>&>'
     893      CXXLD    mbdepth
     894      CXXLD    hexmodops
  >> 895    make[2]: *** [mbpart.o] Error 1
     896    make[2]: *** Waiting for unfinished jobs....
     897    make[2]: Leaving directory `/localscratch/tmp/s3j-spack/spack-stage
            /spack-stage-NT13kT/spack-src/tools'
  >> 898    make[1]: *** [all-recursive] Error 1
     899    make[1]: Leaving directory `/localscratch/tmp/s3j-spack/spack-stage
            /spack-stage-NT13kT/spack-src/tools'
  >> 900    make: *** [all-recursive] Error 1
</false></char></_tp></typename></_ostream></:__and_></_tp></typename></_ostream></:__and_></cla></char></char>

该提问来源于开源项目:spack/spack

  • 写回答

5条回答 默认 最新

  • weixin_39941792 2020-11-29 11:16
    关注

    Thanks! I think the test failure is a fluke; I've restarted that single test.

    评论

报告相同问题?