heremaps / tin-terrain

A command-line tool for converting heightmaps in GeoTIFF format into tiled optimized meshes.
MIT License
586 stars 127 forks source link

Error while building and installing #77

Closed Girishchandra-Yendargaye closed 2 years ago

Girishchandra-Yendargaye commented 4 years ago

error: parameter declared ‘auto’ std::for_each(begin, end, [this](const auto& v) { add(v); }); error: ‘v’ was not declared in this scope std::for_each(begin, end, [this](const auto& v) { add(v); }); error: ‘make_unique’ is not a member of ‘std’ TileMaker() : m_mesh(std::make_unique()) {} error: expected primary-expression before ‘>’ token TileMaker() : m_mesh(std::make_unique()) {} error: expected primary-expression before ‘)’ token TileMaker() : m_mesh(std::make_unique()) {}

kiner-shah commented 3 years ago

for_each was introduced in C++ 17 as per this link. And make_unique in C++ 14 as per this link. Where exactly are you getting this error?

crohr88 commented 2 years ago

I had something similar while compiling. I was inadvertently using an old compiler (4.8.5) for both boost and tin-terrain. Everything behaved correctly under GCC 8.3.0.

Girishchandra-Yendargaye commented 2 years ago

error: parameter declared ‘auto’ std::for_each(begin, end, [this](const auto& v) { add(v); }); error: ‘v’ was not declared in this scope std::for_each(begin, end, [this](const auto& v) { add(v); }); error: ‘make_unique’ is not a member of ‘std’ TileMaker() : m_mesh(std::make_unique()) {} error: expected primary-expression before ‘>’ token TileMaker() : m_mesh(std::make_unique()) {} error: expected primary-expression before ‘)’ token TileMaker() : m_mesh(std::make_unique()) {}

Yes after changing compiler it worked.