ubports / unity-scopes-api

GNU Lesser General Public License v3.0
1 stars 1 forks source link

Switch c++11 to gnu++11 #14

Closed vanyasem closed 6 years ago

vanyasem commented 6 years ago

Unfortunately (due to lack of proper CI reeee) my previous PR #12 broke the build on bionic. I tried to guess what should be done to fix it, but CI refused to run again (unresolvable deps reee). So well there is no way to know if it works until we merge this. Sorry.

dobey commented 6 years ago

OK. I can't seem to add myself as a reviewer, but this is the wrong fix (and so likely was the previous change). The code is using c++11 (not gnu++11), so with the previous PR you've introduced a conflict where cmake tries to specify c++14 and the CXXFLAGS tries to specify 11. Instead, the correct solution here would be to remove the -std= option, and specify 11 rather than 14, as the standard to cmake; I think.

vanyasem commented 6 years ago

@dobey Nope, that didn't work

In file included from /usr/include/kj/memory.h:28,
                 from /usr/include/kj/array.h:28,
                 from /usr/include/kj/string.h:29,
                 from /usr/include/capnp/common.h:33,
                 from /usr/include/capnp/raw-schema.h:28,
                 from /usr/include/capnp/generated-header-support.h:30,
                 from /usr/include/capnp/schema.capnp.h:6,
                 from /usr/include/capnp/schema.h:32,
                 from /usr/include/capnp/dynamic.h:39,
                 from /home/vanyasem/Projects/AUR/_Unity8/_Unity8-Arch/unity-scopes-api-git/src/unity-scopes-api/include/unity/scopes/internal/zmq_middleware/ServantBase.h:21,
                 from /home/vanyasem/Projects/AUR/_Unity8/_Unity8-Arch/unity-scopes-api-git/src/unity-scopes-api/include/unity/scopes/internal/zmq_middleware/QueryCtrlI.h:23,
                 from /home/vanyasem/Projects/AUR/_Unity8/_Unity8-Arch/unity-scopes-api-git/src/unity-scopes-api/src/scopes/internal/zmq_middleware/QueryCtrlI.cpp:19:
/usr/include/kj/common.h:36:4: error: #error "This code requires C++14. Either your compiler does not support it or it is not enabled."
   #error "This code requires C++14. Either your compiler does not support it or it is not enabled."
    ^~~~~
/usr/include/kj/common.h:39:6: error: #error "Pass -std=c++14 on the compiler command line to enable C++14."
     #error "Pass -std=c++14 on the compiler command line to enable C++14."
      ^~~~~
vanyasem commented 6 years ago

The original issue got back