2015-11-15 14:41 GMT+01:00 Jochen Topf <joc...@remote.org>: > Hi! > > Today taginfo has switched from using the old Osmium library to the new > Libosmium (https://github.com/osmcode/libosmium). This doesn't change any > functionality, but should make the generation of the statistics a bit > faster > and brings the code into the 21st century which will make changes easier > in the future. >
Compiling the tagstats binaries results in an "ambiguous overload for ‘operator<’ " error. Do you have an idea what is wrong? This is the output: ~/src/taginfo/tagstats$ make g++ -O3 -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -std=c++11 -I../../libosmium/include -Wall -Wextra -pedantic -Wredundant-decls -Wdisabled-optimization -Wctor-dtor-privacy -Wnon-virtual-dtor -Woverloaded-virtual -Wsign-promo -Wold-style-cast -DTAGSTATS_GEODISTRIBUTION_INT=uint16_t -DTAGSTATS_GEODISTRIBUTION_FOR_WAYS=SparseMemArray -DTAGSTATS_GEODISTRIBUTION_INCLUDE="<osmium/index/map/sparse_mem_array.hpp>" -o tagstats tagstats.cpp -pthread -lexpat -lbz2 -lz -lsqlite3 -lgd -lz -lm In file included from tagstats.cpp:47:0: tagstats_handler.hpp: In member function ‘void TagStatsHandler::collect_tag_stats(const osmium::OSMObject&)’: tagstats_handler.hpp:421:29: error: ambiguous overload for ‘operator<’ (operand types are ‘time_t {aka long int}’ and ‘osmium::Timestamp’) if (m_max_timestamp < object.timestamp()) { ^ tagstats_handler.hpp:421:29: note: candidates are: tagstats_handler.hpp:421:29: note: operator<(time_t {aka long int}, int) <built-in> tagstats_handler.hpp:421:29: note: operator<(time_t {aka long int}, unsigned int) <built-in> tagstats_handler.hpp:421:29: note: operator<(time_t {aka long int}, long unsigned int) <built-in> tagstats_handler.hpp:421:29: note: operator<(time_t {aka long int}, time_t {aka long int}) <built-in> In file included from ../../libosmium/include/osmium/osm/object.hpp:49:0, from ../../libosmium/include/osmium/osm/node.hpp:39, from ../../libosmium/include/osmium/osm.hpp:36, from ../../libosmium/include/osmium/builder/osm_object_builder.hpp:45, from ../../libosmium/include/osmium/io/detail/pbf_decoder.hpp:49, from ../../libosmium/include/osmium/io/detail/pbf_input_format.hpp:51, from ../../libosmium/include/osmium/io/pbf_input.hpp:46, from ../../libosmium/include/osmium/io/any_input.hpp:48, from tagstats.cpp:24: ../../libosmium/include/osmium/osm/timestamp.hpp:239:17: note: bool osmium::operator<(const osmium::Timestamp&, const osmium::Timestamp&) inline bool operator<(const Timestamp& lhs, const Timestamp& rhs) noexcept { ^ In file included from tagstats.cpp:47:0: tagstats_handler.hpp:422:29: warning: ‘constexpr osmium::Timestamp::operator time_t() const’ is deprecated (declared at ../../libosmium/include/osmium/osm/timestamp.hpp:165) [-Wdeprecated-declarations] m_max_timestamp = object.timestamp(); ^ make: *** [tagstats] Error 1 Cheers, Martin
_______________________________________________ Taginfo-dev mailing list Taginfo-dev@openstreetmap.org https://lists.openstreetmap.org/listinfo/taginfo-dev