OpenRTM / OpenRTM-aist

OpenRTM-aist: RT-Middleware and OMG RTC implementation in C++ implemented by AIST
https://openrtm.org/
Other
19 stars 12 forks source link

Ubuntu 18.10 で master ブランチのビルドに失敗する #277

Closed tonboAkinori closed 5 years ago

tonboAkinori commented 5 years ago

Describe the bug Ubuntu 18.10 で master ブランチのビルドに失敗する

Ubuntu 18.04の g++ 7.3 ではビルド成功、18.10 の 8.2 では失敗

To Reproduce Steps to reproduce the behavior:

  1. Dockerのベースイメージを 18.10 にする

    • build/ubuntu_1604/Dockerfile を変更
  2. docker build を実施

  3. 下記エラーが出力され、ビルドに失敗する

    /root/OpenRTM-aist/src/ext/local_service/nameservice_file/FileNameservice.cpp:247:33: error: no match for 'operator!=' (operand types are 'boost::system::error_code' and 'std::nullptr_t')
           if (!result || (error != nullptr))
                           ~~~~~~^~~~~~~~~~

    Reproducibility 100 %

Expected behavior ビルドが成功すること

Screenshots or Logs

/root/OpenRTM-aist/src/ext/local_service/nameservice_file/FileNameservice.cpp: In member function 'void RTM::LocalService::FileNameservice::onUnregisterNameservice(coil::vstring&)':
/root/OpenRTM-aist/src/ext/local_service/nameservice_file/FileNameservice.cpp:247:33: error: no match for 'operator!=' (operand types are 'boost::system::error_code' and 'std::nullptr_t')
           if (!result || (error != nullptr))
                           ~~~~~~^~~~~~~~~~
In file included from /usr/include/omniORB4/CORBA.h:216,
                 from /root/OpenRTM-aist/src/lib/rtm/RTC.h:50,
                 from /root/OpenRTM-aist/src/lib/rtm/Manager.h:23,
                 from /root/OpenRTM-aist/src/ext/local_service/nameservice_file/FileNameservice.cpp:22:
/usr/include/omniORB4/fixed.h:50:16: note: candidate: 'CORBA::Boolean operator!=(const CORBA::Fixed&, const CORBA::Fixed&)'
 CORBA::Boolean operator!=(const CORBA::Fixed& a, const CORBA::Fixed& b);
                ^~~~~~~~
/usr/include/omniORB4/fixed.h:50:16: note:   no known conversion for argument 1 from 'boost::system::error_code' to 'const CORBA::Fixed&'
In file included from /usr/include/boost/filesystem/path_traits.hpp:23,
                 from /usr/include/boost/filesystem/path.hpp:25,
                 from /usr/include/boost/filesystem.hpp:16,
                 from /root/OpenRTM-aist/src/ext/local_service/nameservice_file/FileNameservice.cpp:20:
/usr/include/boost/system/error_code.hpp:599:17: note: candidate: 'bool boost::system::operator!=(const boost::system::error_code&, const boost::system::error_code&)'
     inline bool operator!=( const error_code & lhs,
                 ^~~~~~~~
/usr/include/boost/system/error_code.hpp:599:17: note:   no known conversion for argument 2 from 'std::nullptr_t' to 'const boost::system::error_code&'
/usr/include/boost/system/error_code.hpp:605:17: note: candidate: 'bool boost::system::operator!=(const boost::system::error_condition&, const boost::system::error_condition&)'
     inline bool operator!=( const error_condition & lhs,
                 ^~~~~~~~
/usr/include/boost/system/error_code.hpp:605:17: note:   no known conversion for argument 1 from 'boost::system::error_code' to 'const boost::system::error_condition&'
/usr/include/boost/system/error_code.hpp:618:17: note: candidate: 'bool boost::system::operator!=(const boost::system::error_code&, const boost::system::error_condition&)'
     inline bool operator!=( const error_code & lhs,
                 ^~~~~~~~
/usr/include/boost/system/error_code.hpp:618:17: note:   no known conversion for argument 2 from 'std::nullptr_t' to 'const boost::system::error_condition&'
/usr/include/boost/system/error_code.hpp:631:17: note: candidate: 'bool boost::system::operator!=(const boost::system::error_condition&, const boost::system::error_code&)'
     inline bool operator!=( const error_condition & lhs,
                 ^~~~~~~~
/usr/include/boost/system/error_code.hpp:631:17: note:   no known conversion for argument 1 from 'boost::system::error_code' to 'const boost::system::error_condition&'
/root/OpenRTM-aist/src/ext/local_service/nameservice_file/FileNameservice.cpp: In member function 'bool RTM::LocalService::FileNameservice::createDirectory(boost::filesystem::path&)':
/root/OpenRTM-aist/src/ext/local_service/nameservice_file/FileNameservice.cpp:276:33: error: no match for 'operator!=' (operand types are 'boost::system::error_code' and 'std::nullptr_t')
           if (!result || (error != nullptr))
                           ~~~~~~^~~~~~~~~~
In file included from /usr/include/omniORB4/CORBA.h:216,
                 from /root/OpenRTM-aist/src/lib/rtm/RTC.h:50,
                 from /root/OpenRTM-aist/src/lib/rtm/Manager.h:23,
                 from /root/OpenRTM-aist/src/ext/local_service/nameservice_file/FileNameservice.cpp:22:
/usr/include/omniORB4/fixed.h:50:16: note: candidate: 'CORBA::Boolean operator!=(const CORBA::Fixed&, const CORBA::Fixed&)'
 CORBA::Boolean operator!=(const CORBA::Fixed& a, const CORBA::Fixed& b);
                ^~~~~~~~
/usr/include/omniORB4/fixed.h:50:16: note:   no known conversion for argument 1 from 'boost::system::error_code' to 'const CORBA::Fixed&'
In file included from /usr/include/boost/filesystem/path_traits.hpp:23,
                 from /usr/include/boost/filesystem/path.hpp:25,
                 from /usr/include/boost/filesystem.hpp:16,
                 from /root/OpenRTM-aist/src/ext/local_service/nameservice_file/FileNameservice.cpp:20:
/usr/include/boost/system/error_code.hpp:599:17: note: candidate: 'bool boost::system::operator!=(const boost::system::error_code&, const boost::system::error_code&)'
     inline bool operator!=( const error_code & lhs,
                 ^~~~~~~~
/usr/include/boost/system/error_code.hpp:599:17: note:   no known conversion for argument 2 from 'std::nullptr_t' to 'const boost::system::error_code&'
/usr/include/boost/system/error_code.hpp:605:17: note: candidate: 'bool boost::system::operator!=(const boost::system::error_condition&, const boost::system::error_condition&)'
     inline bool operator!=( const error_condition & lhs,
                 ^~~~~~~~
/usr/include/boost/system/error_code.hpp:605:17: note:   no known conversion for argument 1 from 'boost::system::error_code' to 'const boost::system::error_condition&'
/usr/include/boost/system/error_code.hpp:618:17: note: candidate: 'bool boost::system::operator!=(const boost::system::error_code&, const boost::system::error_condition&)'
     inline bool operator!=( const error_code & lhs,
                 ^~~~~~~~
/usr/include/boost/system/error_code.hpp:618:17: note:   no known conversion for argument 2 from 'std::nullptr_t' to 'const boost::system::error_condition&'
/usr/include/boost/system/error_code.hpp:631:17: note: candidate: 'bool boost::system::operator!=(const boost::system::error_condition&, const boost::system::error_code&)'
     inline bool operator!=( const error_condition & lhs,
                 ^~~~~~~~
/usr/include/boost/system/error_code.hpp:631:17: note:   no known conversion for argument 1 from 'boost::system::error_code' to 'const boost::system::error_condition&'
[ 79%] Linking CXX shared library ExtendedFsmServiceProvider.so
[ 79%] Built target ExtendedFsmServiceProvider
Scanning dependencies of target LogicalTimeTriggeredEC
[ 80%] Linking CXX shared library LogicalTimeTriggeredEC.so
make[2]: *** [src/ext/local_service/nameservice_file/CMakeFiles/FileNameservice.dir/build.make:63: src/ext/local_service/nameservice_file/CMakeFiles/FileNameservice.dir/FileNameservice.cpp.o] Error 1
make[1]: *** [CMakeFiles/Makefile2:1628: src/ext/local_service/nameservice_file/CMakeFiles/FileNameservice.dir/all] Error 2
make[1]: *** Waiting for unfinished jobs....
[ 80%] Built target LogicalTimeTriggeredEC
make: *** [Makefile:130: all] Error 2
The command '/bin/sh -c cmake -DCORBA=omniORB -DCMAKE_BUILD_TYPE=Release -DSSL_ENABLE=ON -DOBSERVER_ENABLE=ON -S . -Bbuild_openrtm && cmake --build build_openrtm -- -j$(nproc)' returned a non-zero code: 2

Environment

Additional context

r-kurose commented 5 years ago

ログからは boost の仕様変更に見えますね。

r-kurose commented 5 years ago

233 で同じ部分に修正の話があるので注意。

tonboAkinori commented 5 years ago

233 で指摘されている部分が修正されれば問題なくなります。

@Nobu19800 さんの指摘にある通り error は使われていないという指摘で 指摘部分の error =! nullptr を削除すれば、ビルドが通ることは確認済みです。

tonboAkinori commented 5 years ago

476 がマージされたブランチ (4fd2a4f) で本チケットに関して確認を行い、

問題が解決されていることを確認できたためクローズする。

■ #476 がマージされる前のブランチ(08a6a98)をUbuntu18.10でビルドすると失敗することを確認

■#476 がマージされる後のブランチ(4fd2a4f)をUbuntu18.10でビルドして成功することを確認