coin-or / Clp

COIN-OR Linear Programming Solver
Other
396 stars 82 forks source link

Error when try to build from source using bazel BUILD #131

Closed flipony closed 4 years ago

flipony commented 4 years ago

when I tried to write a bazel BUILD rule using 1.17.5 release source file, got the following error:

external/clp/Clp/src/AbcSimplex.hpp:1422:22: error: field has incomplete type 'AbcSimplexProgress'
  AbcSimplexProgress abcProgress_;
                     ^
external/clp/Clp/src/AbcSimplex.hpp:31:7: note: forward declaration of 'AbcSimplexProgress'
class AbcSimplexProgress;
svigerske commented 4 years ago

Does it work if you add an include of CbcSolve.hpp to AbcSimplex.hpp?

svigerske commented 4 years ago

AbcSimplex.hpp seems to ClpSolve.hpp, which defines class AbcSimplexProgress, if CLP_HAS_ABC is defined and not zero. The latter should be the case for builds where Aboca has been enabled.