This repo contains an old (version 3.1.0, the latest version is 7.1.2) vendored copy of fmt. While the header should not create any conflict, as they are installed in mp/format.h instead of fmt/format.h, the symbols of the embedded fmt library are not put in a different namespace, so they could create conflicts when the ampl-mp library is used in the same process that also links with the latest fmt library.
Possible strategies to deal with this are:
Migrate ampl-mp to use the latest (external) fmt library via find_package(fmt CONFIG REQUIRED) : I quickly tried, but it seems not to be trivial due to the extensive use of fmt::CStringRef symbol that are not present anymore in fmt 7
Enclose all the fmt symbols inside a different C++ namespace, ensuring that the vendored fmt library of ampl-mp can be used with no problems and without creating problems to other users of fmt library.
Note that both of this options would break the ABI of the library.
This repo contains an old (version 3.1.0, the latest version is 7.1.2) vendored copy of fmt. While the header should not create any conflict, as they are installed in
mp/format.h
instead offmt/format.h
, the symbols of the embedded fmt library are not put in a different namespace, so they could create conflicts when the ampl-mp library is used in the same process that also links with the latest fmt library.Possible strategies to deal with this are:
find_package(fmt CONFIG REQUIRED)
: I quickly tried, but it seems not to be trivial due to the extensive use offmt::CStringRef
symbol that are not present anymore in fmt 7Note that both of this options would break the ABI of the library.