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

Version 9.8 fails to build with abseil-20230125.3: error: no matching function for call to 'StrCat' #4070

Closed
yurivict opened this issue Jan 31, 2024 · 2 comments
Assignees
Labels
Milestone

Comments

@yurivict
Copy link

What version of OR-Tools and what language are you using?
Version: 9.8
Language: n/a

Which solver are you using (e.g. CP-SAT, Routing Solver, GLOP, BOP, Gurobi)
n/a

What operating system (Linux, Windows, ...) and version?
FreeBSD 14.0

What did you do?
regular build

What did you expect to see
n/a

What did you see instead?

/usr/ports/math/or-tools/work/or-tools-9.8/ortools/sat/cuts.cc:70:24: error: no matching function for call to 'StrCat'
  std::string result = absl::StrCat("CutData rhs=", rhs, "\n");
                       ^~~~~~~~~~~~
/usr/local/include/absl/strings/str_cat.h:388:34: note: candidate function not viable: no known conversion from 'const absl::int128' to 'const AlphaNum' for 2nd argument
ABSL_MUST_USE_RESULT std::string StrCat(const AlphaNum& a, const AlphaNum& b,
                                 ^
/usr/local/include/absl/strings/str_cat.h:387:34: note: candidate function not viable: requires 2 arguments, but 3 were provided
ABSL_MUST_USE_RESULT std::string StrCat(const AlphaNum& a, const AlphaNum& b);
                                 ^
/usr/local/include/absl/strings/str_cat.h:390:34: note: candidate function not viable: requires 4 arguments, but 3 were provided
ABSL_MUST_USE_RESULT std::string StrCat(const AlphaNum& a, const AlphaNum& b,
                                 ^
/usr/local/include/absl/strings/str_cat.h:383:41: note: candidate function not viable: requires single argument 'a', but 3 arguments were provided
ABSL_MUST_USE_RESULT inline std::string StrCat(const AlphaNum& a) {
                                        ^
/usr/local/include/absl/strings/str_cat.h:381:41: note: candidate function not viable: requires 0 arguments, but 3 were provided
ABSL_MUST_USE_RESULT inline std::string StrCat() { return std::string(); }
                                        ^
/usr/local/include/absl/strings/str_cat.h:395:41: note: candidate function template not viable: requires at least 5 arguments, but 3 were provided
ABSL_MUST_USE_RESULT inline std::string StrCat( 
                                        ^
/usr/local/include/absl/strings/str_cat.h:400:8: error: no viable conversion from 'const absl::int128' to 'const AlphaNum'
       static_cast<const AlphaNum&>(args).Piece()...});
       ^                            ~~~~
/usr/ports/math/or-tools/work/or-tools-9.8/ortools/sat/cuts.cc:1997:16: note: in instantiation of function template specialization 'absl::StrCat<absl::int128, char[8], int, char[6], int, char[6], int>' requested here      
  return absl::StrCat("#in:", in_flow.size(), " #out:", out_flow.size(),
               ^
/usr/local/include/absl/strings/str_cat.h:255:3: note: candidate constructor not viable: no known conversion from 'const absl::int128' to 'int' for 1st argument
  AlphaNum(int x)  // NOLINT(runtime/explicit)
  ^
/usr/local/include/absl/strings/str_cat.h:259:3: note: candidate constructor not viable: no known conversion from 'const absl::int128' to 'unsigned int' for 1st argument
  AlphaNum(unsigned int x)  // NOLINT(runtime/explicit) 
  ^
/usr/local/include/absl/strings/str_cat.h:263:3: note: candidate constructor not viable: no known conversion from 'const absl::int128' to 'long' for 1st argument
  AlphaNum(long x)  // NOLINT(*)
  ^
/usr/local/include/absl/strings/str_cat.h:267:3: note: candidate constructor not viable: no known conversion from 'const absl::int128' to 'unsigned long' for 1st argument
  AlphaNum(unsigned long x)  // NOLINT(*)
  ^
/usr/local/include/absl/strings/str_cat.h:271:3: note: candidate constructor not viable: no known conversion from 'const absl::int128' to 'long long' for 1st argument
  AlphaNum(long long x)  // NOLINT(*)
  ^
/usr/local/include/absl/strings/str_cat.h:275:3: note: candidate constructor not viable: no known conversion from 'const absl::int128' to 'unsigned long long' for 1st argument
  AlphaNum(unsigned long long x)  // NOLINT(*)
  ^
/usr/local/include/absl/strings/str_cat.h:280:3: note: candidate constructor not viable: no known conversion from 'const absl::int128' to 'float' for 1st argument
  AlphaNum(float f)  // NOLINT(runtime/explicit)

Make sure you include information that can help us debug (full error message, model Proto).

Anything else we should know about your project / environment

@lperron
Copy link
Collaborator

lperron commented Jan 31, 2024

old version of abseil.
Printing of int128 was added in the summer 2023 release I believe.

@lperron lperron closed this as completed Jan 31, 2024
@Mizux Mizux added this to the v9.9 milestone Jan 31, 2024
@Mizux Mizux added Bug OS: FreeBSD FreeBSD OS labels Jan 31, 2024
@Mizux
Copy link
Collaborator

Mizux commented Jan 31, 2024

Confirmed v9.8 has be built against abseil-cpp 20230802.1

GIT_REPOSITORY "https://github.com/abseil/abseil-cpp.git"
GIT_TAG "20230802.1"

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants