Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[cmake] Building Protobuf v27.2 for Python fail #4302

Closed
Mizux opened this issue Jul 8, 2024 · 1 comment
Closed

[cmake] Building Protobuf v27.2 for Python fail #4302

Mizux opened this issue Jul 8, 2024 · 1 comment
Assignees
Labels
Bug Build: CMake CMake based build issue dependencies Pull requests that update a dependency file Lang: Python Python wrapper issue
Milestone

Comments

@Mizux
Copy link
Collaborator

Mizux commented Jul 8, 2024

Trace:

/home/runner/work/or-tools/or-tools/build/_deps/pybind11-src/include/pybind11/pybind11.h:145:19:   required from ‘pybind11::cpp_function::cpp_function(Func&&, const Extra& ...) [with Func = operations_research::pdlp::pybind11_init_pdlp(pybind11::module_&)::<lambda(const operations_research::MPModelProto&, bool, bool)>; Extra = {pybind11::name, pybind11::scope, pybind11::sibling, pybind11::arg, pybind11::arg, pybind11::arg_v}; <template-parameter-1-3> = void]’
/home/runner/work/or-tools/or-tools/build/_deps/pybind11-src/include/pybind11/pybind11.h:1237:22:   required from ‘pybind11::module_& pybind11::module_::def(const char*, Func&&, const Extra& ...) [with Func = operations_research::pdlp::pybind11_init_pdlp(pybind11::module_&)::<lambda(const operations_research::MPModelProto&, bool, bool)>; Extra = {pybind11::arg, pybind11::arg, pybind11::arg_v}]’
/home/runner/work/or-tools/or-tools/ortools/pdlp/python/pdlp.cc:95:8:   required from here
/home/runner/work/or-tools/or-tools/build/_deps/protobuf-src/src/google/protobuf/port.h:72:43: error: no matching function for call to ‘StrongPointer<const operations_research::MPModelProto& (* const)(), ptr>()’
   72 |   return StrongPointer<decltype(ptr), ptr>();
      |          ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~
/home/runner/work/or-tools/or-tools/build/_deps/protobuf-src/src/google/protobuf/port.h:43:36: note: candidate: ‘template<class T> void google::protobuf::internal::StrongPointer(T*)’
   43 | inline PROTOBUF_ALWAYS_INLINE void StrongPointer(T* var) {
      |                                    ^~~~~~~~~~~~~
/home/runner/work/or-tools/or-tools/build/_deps/protobuf-src/src/google/protobuf/port.h:43:36: note:   template argument deduction/substitution failed:
/home/runner/work/or-tools/or-tools/build/_deps/protobuf-src/src/google/protobuf/port.h:72:43: error: wrong number of template arguments (2, should be 1)
   72 |   return StrongPointer<decltype(ptr), ptr>();
      |          ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~
/home/runner/work/or-tools/or-tools/build/_deps/protobuf-src/src/google/protobuf/port.h:43:36: note: provided for ‘template<class T> void google::protobuf::internal::StrongPointer(T*)’
   43 | inline PROTOBUF_ALWAYS_INLINE void StrongPointer(T* var) {
      |                                    ^~~~~~~~~~~~~
/home/runner/work/or-tools/or-tools/build/_deps/protobuf-src/src/google/protobuf/port.h:54:36: note: candidate: ‘template<class T, T ptr> void google::protobuf::internal::StrongPointer()’
   54 | inline PROTOBUF_ALWAYS_INLINE void StrongPointer() {
      |                                    ^~~~~~~~~~~~~
/home/runner/work/or-tools/or-tools/build/_deps/protobuf-src/src/google/protobuf/port.h:54:36: note:   template argument deduction/substitution failed:
/home/runner/work/or-tools/or-tools/build/_deps/protobuf-src/src/google/protobuf/port.h:72:43: error: could not convert template argument ‘ptr’ from ‘const operations_research::MPModelProto& (* const)()’ to ‘const operations_research::MPModelProto& (* const)()’
   72 |   return StrongPointer<decltype(ptr), ptr>();
      |          ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~

related to:

@Mizux Mizux added Bug Lang: Python Python wrapper issue Build: CMake CMake based build issue dependencies Pull requests that update a dependency file labels Jul 8, 2024
@Mizux Mizux added this to the v10.0 milestone Jul 8, 2024
@Mizux Mizux self-assigned this Jul 8, 2024
@Mizux
Copy link
Collaborator Author

Mizux commented Jul 8, 2024

Work in Progress: testing using ubuntu-24.04 base image to have a more recent gcc (13.2.0 instead of 11.4.0)

ref: https://github.com/actions/runner-images
trace: https://github.com/google/or-tools/actions/runs/9841412658

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Build: CMake CMake based build issue dependencies Pull requests that update a dependency file Lang: Python Python wrapper issue
Projects
Archived in project
Development

No branches or pull requests

1 participant