melowntech / libslpk

SLPK IO C++ library.
BSD 2-Clause "Simplified" License
19 stars 6 forks source link

CMake errors building slpk2obj #2

Open barf opened 5 years ago

barf commented 5 years ago

I'm trying to build slpk2obj but struggling to get it built, I get errors relating to CMakeLists.txt

To reproduce:

$ mkdir build
$ cd build/
$ cmake ../
-- The C compiler identification is GNU 9.2.1
-- The CXX compiler identification is GNU 9.2.1
-- Check for working C compiler: /usr/bin/cc
-- Check for working C compiler: /usr/bin/cc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Detecting C compile features
-- Detecting C compile features - done
-- Check for working CXX compiler: /usr/bin/c++
-- Check for working CXX compiler: /usr/bin/c++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Detecting CXX compile features
-- Detecting CXX compile features - done
CMake Error at CMakeLists.txt:4 (define_module):
  Unknown CMake command "define_module".

Do I need to add something to, or modify my CMake system to enable this define_module command thing?

Using Ubuntu 19.10 on x86_64

vaclavblazek commented 5 years ago

This is only a library (plus few utility tools, like slpk2obj). It cannot be built on its own. It needs to be plugged-in to a full fledged project with (our) dependencies and (our) buildsystem (via git submodules). For example, you can use our vts-tools project.

To build the slpk2obj tool in the vts-tools project:

Recursive clone is important since you need to pull all the submodules. If you forget to clone it recursively, use git submodule --recursive in the project root (i.e. vts-tools).

If anything fails, install the dependency CMAKE cannot find. For buildsystem itself you need to have installed cmake and python2.

Since this is big project if needs quite a lot dependencies, you need to install:

If you want to tear down the build and start with clean slate use make purge (fancy alias to remove the build directory). If there is any compilation error on Eoan (19.10), let me know, we have not tried it yet on it.

barf commented 5 years ago

Thank you for the fast reply!

I started building VTS, only libassimp-dev needs adding to that list of dependencies I think. VTS is very impressive!!

Unfortunately I must report imgproc fails to link against the libeigen3-dev (3.3.7-1) library in Disco:

[ 26%] Building CXX object src/imgproc/CMakeFiles/imgproc.dir/contours.cpp.o
[ 27%] Building CXX object src/imgproc/CMakeFiles/imgproc.dir/png-size.cpp.o
[ 27%] Building CXX object src/imgproc/CMakeFiles/imgproc.dir/imagesize.cpp.o
[ 27%] Building CXX object src/imgproc/CMakeFiles/imgproc.dir/rastermask/cvmat.cpp.o
[ 27%] Building CXX object src/imgproc/CMakeFiles/imgproc.dir/rastermask/transform.cpp.o
[ 29%] Building CXX object src/imgproc/CMakeFiles/imgproc.dir/readimage.cpp.o
[ 29%] Building CXX object src/imgproc/CMakeFiles/imgproc.dir/uvpack.cpp.o
[ 29%] Building CXX object src/imgproc/CMakeFiles/imgproc.dir/clahe.cpp.o
[ 29%] Building CXX object src/imgproc/CMakeFiles/imgproc.dir/spectral_analysis.cpp.o
[ 30%] Building CXX object src/imgproc/CMakeFiles/imgproc.dir/scanconversion.cpp.o
[ 30%] Building CXX object src/imgproc/CMakeFiles/imgproc.dir/cvcolors.cpp.o
[ 30%] Building CXX object src/imgproc/CMakeFiles/imgproc.dir/fillrect.cpp.o
[ 30%] Building CXX object src/imgproc/CMakeFiles/imgproc.dir/scattered-interpolation.cpp.o
[ 31%] Building CXX object src/imgproc/CMakeFiles/imgproc.dir/inpaint.cpp.o
[ 31%] Building CXX object src/imgproc/CMakeFiles/imgproc.dir/png.cpp.o
[ 31%] Building CXX object src/imgproc/CMakeFiles/imgproc.dir/jpeg.cpp.o
[ 31%] Building CXX object src/imgproc/CMakeFiles/imgproc.dir/embeddedmask.cpp.o
[ 32%] Linking CXX static library ../../lib/libgeometry.a
In file included from /usr/include/eigen3/Eigen/Core:439,
                 from /usr/include/eigen3/Eigen/SparseCore:11,
                 from /usr/include/eigen3/Eigen/Sparse:26,
                 from /home/barf/melowntech/vts-tools/tools/src/imgproc/scattered-interpolation.cpp:28:
/usr/include/eigen3/Eigen/src/Core/Product.h: In instantiation of ‘Eigen::Product<Lhs, Rhs, Option>::Product(const Lhs&, const Rhs&) [with _Lhs = Eigen::Ref<const Eigen::SparseMatrix<double>, 0, Eigen::OuterStride<> >; _Rhs = Eigen::Block<Eigen::Matrix<double, -1, 1>, -1, 1, true>; int Option = 0; Eigen::Product<Lhs, Rhs, Option>::Lhs = Eigen::Ref<const Eigen::SparseMatrix<double>, 0, Eigen::OuterStride<> >; Eigen::Product<Lhs, Rhs, Option>::Rhs = Eigen::Block<Eigen::Matrix<double, -1, 1>, -1, 1, true>]’:
/usr/include/eigen3/Eigen/src/SparseCore/SparseMatrixBase.h:315:14:   required from ‘const Eigen::Product<Derived, OtherDerived> Eigen::SparseMatrixBase<Derived>::operator*(const Eigen::MatrixBase<OtherDerived>&) const [with OtherDerived = Eigen::Block<Eigen::Matrix<double, -1, 1>, -1, 1, true>; Derived = Eigen::Ref<const Eigen::SparseMatrix<double>, 0, Eigen::OuterStride<> >]’
/usr/include/eigen3/Eigen/src/IterativeLinearSolvers/BiCGSTAB.h:42:29:   required from ‘bool Eigen::internal::bicgstab(const MatrixType&, const Rhs&, Dest&, const Preconditioner&, Eigen::Index&, typename Dest::RealScalar&) [with MatrixType = Eigen::Ref<const Eigen::SparseMatrix<double>, 0, Eigen::OuterStride<> >; Rhs = Eigen::Block<const Eigen::Matrix<double, -1, 1>, -1, 1, true>; Dest = Eigen::Block<Eigen::Matrix<double, -1, 1>, -1, 1, true>; Preconditioner = Eigen::DiagonalPreconditioner<double>; Eigen::Index = long int; typename Dest::RealScalar = double]’
/usr/include/eigen3/Eigen/src/IterativeLinearSolvers/BiCGSTAB.h:203:29:   required from ‘void Eigen::BiCGSTAB<_MatrixType, _Preconditioner>::_solve_with_guess_impl(const Rhs&, Dest&) const [with Rhs = Eigen::MatrixBase<Eigen::Matrix<double, -1, 1> >; Dest = Eigen::Matrix<double, -1, 1>; _MatrixType = Eigen::SparseMatrix<double>; _Preconditioner = Eigen::DiagonalPreconditioner<double>]’
/usr/include/eigen3/Eigen/src/IterativeLinearSolvers/BiCGSTAB.h:219:5:   required from ‘void Eigen::BiCGSTAB<_MatrixType, _Preconditioner>::_solve_impl(const Eigen::MatrixBase<OtherDerived>&, Dest&) const [with Rhs = Eigen::Matrix<double, -1, 1>; Dest = Eigen::Matrix<double, -1, 1>; _MatrixType = Eigen::SparseMatrix<double>; _Preconditioner = Eigen::DiagonalPreconditioner<double>]’
/usr/include/eigen3/Eigen/src/Core/Solve.h:147:5:   required from ‘static void Eigen::internal::Assignment<DstXprType, Eigen::Solve<DecType, RhsType>, Eigen::internal::assign_op<Scalar, Scalar>, Eigen::internal::Dense2Dense>::run(DstXprType&, const SrcXprType&, const Eigen::internal::assign_op<Scalar, Scalar>&) [with DstXprType = Eigen::Matrix<double, -1, 1>; DecType = Eigen::BiCGSTAB<Eigen::SparseMatrix<double>, Eigen::DiagonalPreconditioner<double> >; RhsType = Eigen::Matrix<double, -1, 1>; Scalar = double; Eigen::internal::Assignment<DstXprType, Eigen::Solve<DecType, RhsType>, Eigen::internal::assign_op<Scalar, Scalar>, Eigen::internal::Dense2Dense>::SrcXprType = Eigen::Solve<Eigen::BiCGSTAB<Eigen::SparseMatrix<double>, Eigen::DiagonalPreconditioner<double> >, Eigen::Matrix<double, -1, 1> >]’
/usr/include/eigen3/Eigen/src/Core/AssignEvaluator.h:836:49:   required from ‘void Eigen::internal::call_assignment_no_alias(Dst&, const Src&, const Func&) [with Dst = Eigen::Matrix<double, -1, 1>; Src = Eigen::Solve<Eigen::BiCGSTAB<Eigen::SparseMatrix<double>, Eigen::DiagonalPreconditioner<double> >, Eigen::Matrix<double, -1, 1> >; Func = Eigen::internal::assign_op<double, double>]’
/usr/include/eigen3/Eigen/src/Core/PlainObjectBase.h:732:41:   required from ‘Derived& Eigen::PlainObjectBase<Derived>::_set_noalias(const Eigen::DenseBase<OtherDerived>&) [with OtherDerived = Eigen::Solve<Eigen::BiCGSTAB<Eigen::SparseMatrix<double>, Eigen::DiagonalPreconditioner<double> >, Eigen::Matrix<double, -1, 1> >; Derived = Eigen::Matrix<double, -1, 1>]’
/usr/include/eigen3/Eigen/src/Core/PlainObjectBase.h:816:7:   required from ‘void Eigen::PlainObjectBase<Derived>::_init1(const Eigen::DenseBase<ElseDerived>&) [with T = Eigen::Solve<Eigen::BiCGSTAB<Eigen::SparseMatrix<double>, Eigen::DiagonalPreconditioner<double> >, Eigen::Matrix<double, -1, 1> >; OtherDerived = Eigen::Solve<Eigen::BiCGSTAB<Eigen::SparseMatrix<double>, Eigen::DiagonalPreconditioner<double> >, Eigen::Matrix<double, -1, 1> >; Derived = Eigen::Matrix<double, -1, 1>]’
/usr/include/eigen3/Eigen/src/Core/Matrix.h:294:31:   required from ‘Eigen::Matrix<_Scalar, _Rows, _Cols, _Options, _MaxRows, _MaxCols>::Matrix(const T&) [with T = Eigen::Solve<Eigen::BiCGSTAB<Eigen::SparseMatrix<double>, Eigen::DiagonalPreconditioner<double> >, Eigen::Matrix<double, -1, 1> >; _Scalar = double; int _Rows = -1; int _Cols = 1; int _Options = 0; int _MaxRows = -1; int _MaxCols = 1]’
/home/barf/melowntech/vts-tools/tools/src/imgproc/scattered-interpolation.cpp:109:42:   required from here
/usr/include/eigen3/Eigen/src/Core/Product.h:93:86: error: implicitly-declared ‘Eigen::Block<Eigen::Matrix<double, -1, 1>, -1, 1, true>::Block(const Eigen::Block<Eigen::Matrix<double, -1, 1>, -1, 1, true>&)’ is deprecated [-Werror=deprecated-copy]
   93 |     EIGEN_DEVICE_FUNC Product(const Lhs& lhs, const Rhs& rhs) : m_lhs(lhs), m_rhs(rhs)
      |                                                                                      ^
In file included from /usr/include/eigen3/Eigen/Core:88,
                 from /usr/include/eigen3/Eigen/SparseCore:11,
                 from /usr/include/eigen3/Eigen/Sparse:26,
                 from /home/barf/melowntech/vts-tools/tools/src/imgproc/scattered-interpolation.cpp:28:
/usr/include/eigen3/Eigen/src/Core/util/Macros.h:830:52: note: because ‘Eigen::Block<Eigen::Matrix<double, -1, 1>, -1, 1, true>’ has user-provided ‘Eigen::BlockImpl<XprType, BlockRows, BlockCols, InnerPanel, Eigen::Dense>& Eigen::BlockImpl<XprType, BlockRows, BlockCols, InnerPanel, Eigen::Dense>::operator=(const Eigen::BlockImpl<XprType, BlockRows, BlockCols, InnerPanel, Eigen::Dense>&) [with XprType = Eigen::Matrix<double, -1, 1>; int BlockRows = -1; int BlockCols = 1; bool InnerPanel = true]’
  830 |     EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE Derived& operator=(const Derived& other) \
      |                                                    ^~~~~~~~
/usr/include/eigen3/Eigen/src/Core/util/Macros.h:842:53: note: in expansion of macro ‘EIGEN_INHERIT_ASSIGNMENT_EQUAL_OPERATOR’
  842 | #define EIGEN_INHERIT_ASSIGNMENT_OPERATORS(Derived) EIGEN_INHERIT_ASSIGNMENT_EQUAL_OPERATOR(Derived)
      |                                                     ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/usr/include/eigen3/Eigen/src/Core/Block.h:161:5: note: in expansion of macro ‘EIGEN_INHERIT_ASSIGNMENT_OPERATORS’
  161 |     EIGEN_INHERIT_ASSIGNMENT_OPERATORS(BlockImpl)
      |     ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from /usr/include/eigen3/Eigen/Core:461,
                 from /usr/include/eigen3/Eigen/SparseCore:11,
                 from /usr/include/eigen3/Eigen/Sparse:26,
                 from /home/barf/melowntech/vts-tools/tools/src/imgproc/scattered-interpolation.cpp:28:
/usr/include/eigen3/Eigen/src/Core/CwiseBinaryOp.h: In instantiation of ‘Eigen::CwiseBinaryOp<BinaryOp, Lhs, Rhs>::CwiseBinaryOp(const Lhs&, const Rhs&, const BinaryOp&) [with BinaryOp = Eigen::internal::scalar_difference_op<double, double>; LhsType = const Eigen::Block<const Eigen::Matrix<double, -1, 1>, -1, 1, true>; RhsType = const Eigen::Product<Eigen::Ref<const Eigen::SparseMatrix<double>, 0, Eigen::OuterStride<> >, Eigen::Block<Eigen::Matrix<double, -1, 1>, -1, 1, true>, 0>; Eigen::CwiseBinaryOp<BinaryOp, Lhs, Rhs>::Lhs = Eigen::Block<const Eigen::Matrix<double, -1, 1>, -1, 1, true>; Eigen::CwiseBinaryOp<BinaryOp, Lhs, Rhs>::Rhs = Eigen::Product<Eigen::Ref<const Eigen::SparseMatrix<double>, 0, Eigen::OuterStride<> >, Eigen::Block<Eigen::Matrix<double, -1, 1>, -1, 1, true>, 0>]’:
/usr/include/eigen3/Eigen/src/Core/../plugins/CommonCwiseBinaryOps.h:19:1:   required from ‘const Eigen::CwiseBinaryOp<Eigen::internal::scalar_difference_op<typename Eigen::internal::traits<T>::Scalar, typename Eigen::internal::traits<OtherDerived>::Scalar>, const Derived, const OtherDerived> Eigen::MatrixBase<Derived>::operator-(const Eigen::MatrixBase<OtherDerived>&) const [with OtherDerived = Eigen::Product<Eigen::Ref<const Eigen::SparseMatrix<double>, 0, Eigen::OuterStride<> >, Eigen::Block<Eigen::Matrix<double, -1, 1>, -1, 1, true>, 0>; Derived = Eigen::Block<const Eigen::Matrix<double, -1, 1>, -1, 1, true>; typename Eigen::internal::traits<OtherDerived>::Scalar = double; typename Eigen::internal::traits<T>::Scalar = double]’
/usr/include/eigen3/Eigen/src/IterativeLinearSolvers/BiCGSTAB.h:42:23:   required from ‘bool Eigen::internal::bicgstab(const MatrixType&, const Rhs&, Dest&, const Preconditioner&, Eigen::Index&, typename Dest::RealScalar&) [with MatrixType = Eigen::Ref<const Eigen::SparseMatrix<double>, 0, Eigen::OuterStride<> >; Rhs = Eigen::Block<const Eigen::Matrix<double, -1, 1>, -1, 1, true>; Dest = Eigen::Block<Eigen::Matrix<double, -1, 1>, -1, 1, true>; Preconditioner = Eigen::DiagonalPreconditioner<double>; Eigen::Index = long int; typename Dest::RealScalar = double]’
/usr/include/eigen3/Eigen/src/IterativeLinearSolvers/BiCGSTAB.h:203:29:   required from ‘void Eigen::BiCGSTAB<_MatrixType, _Preconditioner>::_solve_with_guess_impl(const Rhs&, Dest&) const [with Rhs = Eigen::MatrixBase<Eigen::Matrix<double, -1, 1> >; Dest = Eigen::Matrix<double, -1, 1>; _MatrixType = Eigen::SparseMatrix<double>; _Preconditioner = Eigen::DiagonalPreconditioner<double>]’
/usr/include/eigen3/Eigen/src/IterativeLinearSolvers/BiCGSTAB.h:219:5:   required from ‘void Eigen::BiCGSTAB<_MatrixType, _Preconditioner>::_solve_impl(const Eigen::MatrixBase<OtherDerived>&, Dest&) const [with Rhs = Eigen::Matrix<double, -1, 1>; Dest = Eigen::Matrix<double, -1, 1>; _MatrixType = Eigen::SparseMatrix<double>; _Preconditioner = Eigen::DiagonalPreconditioner<double>]’
/usr/include/eigen3/Eigen/src/Core/Solve.h:147:5:   required from ‘static void Eigen::internal::Assignment<DstXprType, Eigen::Solve<DecType, RhsType>, Eigen::internal::assign_op<Scalar, Scalar>, Eigen::internal::Dense2Dense>::run(DstXprType&, const SrcXprType&, const Eigen::internal::assign_op<Scalar, Scalar>&) [with DstXprType = Eigen::Matrix<double, -1, 1>; DecType = Eigen::BiCGSTAB<Eigen::SparseMatrix<double>, Eigen::DiagonalPreconditioner<double> >; RhsType = Eigen::Matrix<double, -1, 1>; Scalar = double; Eigen::internal::Assignment<DstXprType, Eigen::Solve<DecType, RhsType>, Eigen::internal::assign_op<Scalar, Scalar>, Eigen::internal::Dense2Dense>::SrcXprType = Eigen::Solve<Eigen::BiCGSTAB<Eigen::SparseMatrix<double>, Eigen::DiagonalPreconditioner<double> >, Eigen::Matrix<double, -1, 1> >]’
/usr/include/eigen3/Eigen/src/Core/AssignEvaluator.h:836:49:   required from ‘void Eigen::internal::call_assignment_no_alias(Dst&, const Src&, const Func&) [with Dst = Eigen::Matrix<double, -1, 1>; Src = Eigen::Solve<Eigen::BiCGSTAB<Eigen::SparseMatrix<double>, Eigen::DiagonalPreconditioner<double> >, Eigen::Matrix<double, -1, 1> >; Func = Eigen::internal::assign_op<double, double>]’
/usr/include/eigen3/Eigen/src/Core/PlainObjectBase.h:732:41:   required from ‘Derived& Eigen::PlainObjectBase<Derived>::_set_noalias(const Eigen::DenseBase<OtherDerived>&) [with OtherDerived = Eigen::Solve<Eigen::BiCGSTAB<Eigen::SparseMatrix<double>, Eigen::DiagonalPreconditioner<double> >, Eigen::Matrix<double, -1, 1> >; Derived = Eigen::Matrix<double, -1, 1>]’
/usr/include/eigen3/Eigen/src/Core/PlainObjectBase.h:816:7:   required from ‘void Eigen::PlainObjectBase<Derived>::_init1(const Eigen::DenseBase<ElseDerived>&) [with T = Eigen::Solve<Eigen::BiCGSTAB<Eigen::SparseMatrix<double>, Eigen::DiagonalPreconditioner<double> >, Eigen::Matrix<double, -1, 1> >; OtherDerived = Eigen::Solve<Eigen::BiCGSTAB<Eigen::SparseMatrix<double>, Eigen::DiagonalPreconditioner<double> >, Eigen::Matrix<double, -1, 1> >; Derived = Eigen::Matrix<double, -1, 1>]’
/usr/include/eigen3/Eigen/src/Core/Matrix.h:294:31:   required from ‘Eigen::Matrix<_Scalar, _Rows, _Cols, _Options, _MaxRows, _MaxCols>::Matrix(const T&) [with T = Eigen::Solve<Eigen::BiCGSTAB<Eigen::SparseMatrix<double>, Eigen::DiagonalPreconditioner<double> >, Eigen::Matrix<double, -1, 1> >; _Scalar = double; int _Rows = -1; int _Cols = 1; int _Options = 0; int _MaxRows = -1; int _MaxCols = 1]’
/home/barf/melowntech/vts-tools/tools/src/imgproc/scattered-interpolation.cpp:109:42:   required from here
/usr/include/eigen3/Eigen/src/Core/CwiseBinaryOp.h:105:49: error: implicitly-declared ‘Eigen::Block<const Eigen::Matrix<double, -1, 1>, -1, 1, true>::Block(const Eigen::Block<const Eigen::Matrix<double, -1, 1>, -1, 1, true>&)’ is deprecated [-Werror=deprecated-copy]
  105 |       : m_lhs(aLhs), m_rhs(aRhs), m_functor(func)
      |                                                 ^
In file included from /usr/include/eigen3/Eigen/Core:88,
                 from /usr/include/eigen3/Eigen/SparseCore:11,
                 from /usr/include/eigen3/Eigen/Sparse:26,
                 from /home/barf/melowntech/vts-tools/tools/src/imgproc/scattered-interpolation.cpp:28:
/usr/include/eigen3/Eigen/src/Core/util/Macros.h:830:52: note: because ‘Eigen::Block<const Eigen::Matrix<double, -1, 1>, -1, 1, true>’ has user-provided ‘Eigen::BlockImpl<XprType, BlockRows, BlockCols, InnerPanel, Eigen::Dense>& Eigen::BlockImpl<XprType, BlockRows, BlockCols, InnerPanel, Eigen::Dense>::operator=(const Eigen::BlockImpl<XprType, BlockRows, BlockCols, InnerPanel, Eigen::Dense>&) [with XprType = const Eigen::Matrix<double, -1, 1>; int BlockRows = -1; int BlockCols = 1; bool InnerPanel = true]’
  830 |     EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE Derived& operator=(const Derived& other) \
      |                                                    ^~~~~~~~
/usr/include/eigen3/Eigen/src/Core/util/Macros.h:842:53: note: in expansion of macro ‘EIGEN_INHERIT_ASSIGNMENT_EQUAL_OPERATOR’
  842 | #define EIGEN_INHERIT_ASSIGNMENT_OPERATORS(Derived) EIGEN_INHERIT_ASSIGNMENT_EQUAL_OPERATOR(Derived)
      |                                                     ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/usr/include/eigen3/Eigen/src/Core/Block.h:161:5: note: in expansion of macro ‘EIGEN_INHERIT_ASSIGNMENT_OPERATORS’
  161 |     EIGEN_INHERIT_ASSIGNMENT_OPERATORS(BlockImpl)
      |     ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
[ 32%] Built target geometry
In file included from /usr/include/eigen3/Eigen/Core:462,
                 from /usr/include/eigen3/Eigen/SparseCore:11,
                 from /usr/include/eigen3/Eigen/Sparse:26,
                 from /home/barf/melowntech/vts-tools/tools/src/imgproc/scattered-interpolation.cpp:28:
/usr/include/eigen3/Eigen/src/Core/CwiseUnaryOp.h: In instantiation of ‘Eigen::CwiseUnaryOp<UnaryOp, MatrixType>::CwiseUnaryOp(const XprType&, const UnaryOp&) [with UnaryOp = Eigen::internal::scalar_abs2_op<double>; XprType = const Eigen::Block<const Eigen::Matrix<double, -1, 1>, -1, 1, true>]’:
/usr/include/eigen3/Eigen/src/Core/../plugins/MatrixCwiseUnaryOps.h:45:28:   required from ‘const CwiseAbs2ReturnType Eigen::MatrixBase<Derived>::cwiseAbs2() const [with Derived = Eigen::Block<const Eigen::Matrix<double, -1, 1>, -1, 1, true>; Eigen::MatrixBase<Derived>::CwiseAbs2ReturnType = Eigen::CwiseUnaryOp<Eigen::internal::scalar_abs2_op<double>, const Eigen::Block<const Eigen::Matrix<double, -1, 1>, -1, 1, true> >; typename Eigen::internal::traits<T>::Scalar = double]’
/usr/include/eigen3/Eigen/src/Core/Dot.h:98:31:   required from ‘typename Eigen::NumTraits<typename Eigen::internal::traits<T>::Scalar>::Real Eigen::MatrixBase<Derived>::squaredNorm() const [with Derived = Eigen::Block<const Eigen::Matrix<double, -1, 1>, -1, 1, true>; typename Eigen::NumTraits<typename Eigen::internal::traits<T>::Scalar>::Real = double]’
/usr/include/eigen3/Eigen/src/IterativeLinearSolvers/BiCGSTAB.h:46:14:   required from ‘bool Eigen::internal::bicgstab(const MatrixType&, const Rhs&, Dest&, const Preconditioner&, Eigen::Index&, typename Dest::RealScalar&) [with MatrixType = Eigen::Ref<const Eigen::SparseMatrix<double>, 0, Eigen::OuterStride<> >; Rhs = Eigen::Block<const Eigen::Matrix<double, -1, 1>, -1, 1, true>; Dest = Eigen::Block<Eigen::Matrix<double, -1, 1>, -1, 1, true>; Preconditioner = Eigen::DiagonalPreconditioner<double>; Eigen::Index = long int; typename Dest::RealScalar = double]’
/usr/include/eigen3/Eigen/src/IterativeLinearSolvers/BiCGSTAB.h:203:29:   required from ‘void Eigen::BiCGSTAB<_MatrixType, _Preconditioner>::_solve_with_guess_impl(const Rhs&, Dest&) const [with Rhs = Eigen::MatrixBase<Eigen::Matrix<double, -1, 1> >; Dest = Eigen::Matrix<double, -1, 1>; _MatrixType = Eigen::SparseMatrix<double>; _Preconditioner = Eigen::DiagonalPreconditioner<double>]’
/usr/include/eigen3/Eigen/src/IterativeLinearSolvers/BiCGSTAB.h:219:5:   required from ‘void Eigen::BiCGSTAB<_MatrixType, _Preconditioner>::_solve_impl(const Eigen::MatrixBase<OtherDerived>&, Dest&) const [with Rhs = Eigen::Matrix<double, -1, 1>; Dest = Eigen::Matrix<double, -1, 1>; _MatrixType = Eigen::SparseMatrix<double>; _Preconditioner = Eigen::DiagonalPreconditioner<double>]’
/usr/include/eigen3/Eigen/src/Core/Solve.h:147:5:   required from ‘static void Eigen::internal::Assignment<DstXprType, Eigen::Solve<DecType, RhsType>, Eigen::internal::assign_op<Scalar, Scalar>, Eigen::internal::Dense2Dense>::run(DstXprType&, const SrcXprType&, const Eigen::internal::assign_op<Scalar, Scalar>&) [with DstXprType = Eigen::Matrix<double, -1, 1>; DecType = Eigen::BiCGSTAB<Eigen::SparseMatrix<double>, Eigen::DiagonalPreconditioner<double> >; RhsType = Eigen::Matrix<double, -1, 1>; Scalar = double; Eigen::internal::Assignment<DstXprType, Eigen::Solve<DecType, RhsType>, Eigen::internal::assign_op<Scalar, Scalar>, Eigen::internal::Dense2Dense>::SrcXprType = Eigen::Solve<Eigen::BiCGSTAB<Eigen::SparseMatrix<double>, Eigen::DiagonalPreconditioner<double> >, Eigen::Matrix<double, -1, 1> >]’
/usr/include/eigen3/Eigen/src/Core/AssignEvaluator.h:836:49:   required from ‘void Eigen::internal::call_assignment_no_alias(Dst&, const Src&, const Func&) [with Dst = Eigen::Matrix<double, -1, 1>; Src = Eigen::Solve<Eigen::BiCGSTAB<Eigen::SparseMatrix<double>, Eigen::DiagonalPreconditioner<double> >, Eigen::Matrix<double, -1, 1> >; Func = Eigen::internal::assign_op<double, double>]’
/usr/include/eigen3/Eigen/src/Core/PlainObjectBase.h:732:41:   required from ‘Derived& Eigen::PlainObjectBase<Derived>::_set_noalias(const Eigen::DenseBase<OtherDerived>&) [with OtherDerived = Eigen::Solve<Eigen::BiCGSTAB<Eigen::SparseMatrix<double>, Eigen::DiagonalPreconditioner<double> >, Eigen::Matrix<double, -1, 1> >; Derived = Eigen::Matrix<double, -1, 1>]’
/usr/include/eigen3/Eigen/src/Core/PlainObjectBase.h:816:7:   required from ‘void Eigen::PlainObjectBase<Derived>::_init1(const Eigen::DenseBase<ElseDerived>&) [with T = Eigen::Solve<Eigen::BiCGSTAB<Eigen::SparseMatrix<double>, Eigen::DiagonalPreconditioner<double> >, Eigen::Matrix<double, -1, 1> >; OtherDerived = Eigen::Solve<Eigen::BiCGSTAB<Eigen::SparseMatrix<double>, Eigen::DiagonalPreconditioner<double> >, Eigen::Matrix<double, -1, 1> >; Derived = Eigen::Matrix<double, -1, 1>]’
/usr/include/eigen3/Eigen/src/Core/Matrix.h:294:31:   required from ‘Eigen::Matrix<_Scalar, _Rows, _Cols, _Options, _MaxRows, _MaxCols>::Matrix(const T&) [with T = Eigen::Solve<Eigen::BiCGSTAB<Eigen::SparseMatrix<double>, Eigen::DiagonalPreconditioner<double> >, Eigen::Matrix<double, -1, 1> >; _Scalar = double; int _Rows = -1; int _Cols = 1; int _Options = 0; int _MaxRows = -1; int _MaxCols = 1]’
/home/barf/melowntech/vts-tools/tools/src/imgproc/scattered-interpolation.cpp:109:42:   required from here
/usr/include/eigen3/Eigen/src/Core/CwiseUnaryOp.h:66:35: error: implicitly-declared ‘Eigen::Block<const Eigen::Matrix<double, -1, 1>, -1, 1, true>::Block(const Eigen::Block<const Eigen::Matrix<double, -1, 1>, -1, 1, true>&)’ is deprecated [-Werror=deprecated-copy]
   66 |       : m_xpr(xpr), m_functor(func) {}
      |                                   ^
In file included from /usr/include/eigen3/Eigen/Core:88,
                 from /usr/include/eigen3/Eigen/SparseCore:11,
                 from /usr/include/eigen3/Eigen/Sparse:26,
                 from /home/barf/melowntech/vts-tools/tools/src/imgproc/scattered-interpolation.cpp:28:
/usr/include/eigen3/Eigen/src/Core/util/Macros.h:830:52: note: because ‘Eigen::Block<const Eigen::Matrix<double, -1, 1>, -1, 1, true>’ has user-provided ‘Eigen::BlockImpl<XprType, BlockRows, BlockCols, InnerPanel, Eigen::Dense>& Eigen::BlockImpl<XprType, BlockRows, BlockCols, InnerPanel, Eigen::Dense>::operator=(const Eigen::BlockImpl<XprType, BlockRows, BlockCols, InnerPanel, Eigen::Dense>&) [with XprType = const Eigen::Matrix<double, -1, 1>; int BlockRows = -1; int BlockCols = 1; bool InnerPanel = true]’
  830 |     EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE Derived& operator=(const Derived& other) \
      |                                                    ^~~~~~~~
/usr/include/eigen3/Eigen/src/Core/util/Macros.h:842:53: note: in expansion of macro ‘EIGEN_INHERIT_ASSIGNMENT_EQUAL_OPERATOR’
  842 | #define EIGEN_INHERIT_ASSIGNMENT_OPERATORS(Derived) EIGEN_INHERIT_ASSIGNMENT_EQUAL_OPERATOR(Derived)
      |                                                     ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/usr/include/eigen3/Eigen/src/Core/Block.h:161:5: note: in expansion of macro ‘EIGEN_INHERIT_ASSIGNMENT_OPERATORS’
  161 |     EIGEN_INHERIT_ASSIGNMENT_OPERATORS(BlockImpl)
      |     ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from /usr/include/eigen3/Eigen/Core:461,
                 from /usr/include/eigen3/Eigen/SparseCore:11,
                 from /usr/include/eigen3/Eigen/Sparse:26,
                 from /home/barf/melowntech/vts-tools/tools/src/imgproc/scattered-interpolation.cpp:28:
/usr/include/eigen3/Eigen/src/Core/CwiseBinaryOp.h: In instantiation of ‘Eigen::CwiseBinaryOp<BinaryOp, Lhs, Rhs>::CwiseBinaryOp(const Lhs&, const Rhs&, const BinaryOp&) [with BinaryOp = Eigen::internal::scalar_product_op<double, double>; LhsType = const Eigen::ArrayWrapper<const Eigen::Matrix<double, -1, 1> >; RhsType = const Eigen::ArrayWrapper<const Eigen::Matrix<double, -1, 1> >; Eigen::CwiseBinaryOp<BinaryOp, Lhs, Rhs>::Lhs = Eigen::ArrayWrapper<const Eigen::Matrix<double, -1, 1> >; Eigen::CwiseBinaryOp<BinaryOp, Lhs, Rhs>::Rhs = Eigen::ArrayWrapper<const Eigen::Matrix<double, -1, 1> >]’:
/usr/include/eigen3/Eigen/src/Core/../plugins/ArrayCwiseBinaryOps.h:11:10:   required from ‘const Eigen::CwiseBinaryOp<Eigen::internal::scalar_product_op<typename Eigen::internal::traits<T>::Scalar, typename Eigen::internal::traits<OtherDerived>::Scalar>, const Derived, const OtherDerived> Eigen::ArrayBase<Derived>::operator*(const Eigen::ArrayBase<OtherDerived>&) const [with OtherDerived = Eigen::ArrayWrapper<const Eigen::Matrix<double, -1, 1> >; Derived = Eigen::ArrayWrapper<const Eigen::Matrix<double, -1, 1> >; typename Eigen::internal::traits<OtherDerived>::Scalar = double; typename Eigen::internal::traits<T>::Scalar = double]’
/usr/include/eigen3/Eigen/src/IterativeLinearSolvers/BasicPreconditioners.h:91:29:   required from ‘void Eigen::DiagonalPreconditioner<_Scalar>::_solve_impl(const Rhs&, Dest&) const [with Rhs = Eigen::Matrix<double, -1, 1>; Dest = Eigen::Matrix<double, -1, 1>; _Scalar = double]’
/usr/include/eigen3/Eigen/src/Core/Solve.h:147:5:   required from ‘static void Eigen::internal::Assignment<DstXprType, Eigen::Solve<DecType, RhsType>, Eigen::internal::assign_op<Scalar, Scalar>, Eigen::internal::Dense2Dense>::run(DstXprType&, const SrcXprType&, const Eigen::internal::assign_op<Scalar, Scalar>&) [with DstXprType = Eigen::Matrix<double, -1, 1>; DecType = Eigen::DiagonalPreconditioner<double>; RhsType = Eigen::Matrix<double, -1, 1>; Scalar = double; Eigen::internal::Assignment<DstXprType, Eigen::Solve<DecType, RhsType>, Eigen::internal::assign_op<Scalar, Scalar>, Eigen::internal::Dense2Dense>::SrcXprType = Eigen::Solve<Eigen::DiagonalPreconditioner<double>, Eigen::Matrix<double, -1, 1> >]’
/usr/include/eigen3/Eigen/src/Core/AssignEvaluator.h:836:49:   required from ‘void Eigen::internal::call_assignment_no_alias(Dst&, const Src&, const Func&) [with Dst = Eigen::Matrix<double, -1, 1>; Src = Eigen::Solve<Eigen::DiagonalPreconditioner<double>, Eigen::Matrix<double, -1, 1> >; Func = Eigen::internal::assign_op<double, double>]’
/usr/include/eigen3/Eigen/src/Core/AssignEvaluator.h:804:27:   required from ‘void Eigen::internal::call_assignment(Dst&, const Src&, const Func&, typename Eigen::internal::enable_if<(! Eigen::internal::evaluator_assume_aliasing<Src>::value), void*>::type) [with Dst = Eigen::Matrix<double, -1, 1>; Src = Eigen::Solve<Eigen::DiagonalPreconditioner<double>, Eigen::Matrix<double, -1, 1> >; Func = Eigen::internal::assign_op<double, double>; typename Eigen::internal::enable_if<(! Eigen::internal::evaluator_assume_aliasing<Src>::value), void*>::type = void*]’
/usr/include/eigen3/Eigen/src/Core/AssignEvaluator.h:782:18:   [ skipping 6 instantiation contexts, use -ftemplate-backtrace-limit=0 to disable ]
/usr/include/eigen3/Eigen/src/Core/Solve.h:147:5:   required from ‘static void Eigen::internal::Assignment<DstXprType, Eigen::Solve<DecType, RhsType>, Eigen::internal::assign_op<Scalar, Scalar>, Eigen::internal::Dense2Dense>::run(DstXprType&, const SrcXprType&, const Eigen::internal::assign_op<Scalar, Scalar>&) [with DstXprType = Eigen::Matrix<double, -1, 1>; DecType = Eigen::BiCGSTAB<Eigen::SparseMatrix<double>, Eigen::DiagonalPreconditioner<double> >; RhsType = Eigen::Matrix<double, -1, 1>; Scalar = double; Eigen::internal::Assignment<DstXprType, Eigen::Solve<DecType, RhsType>, Eigen::internal::assign_op<Scalar, Scalar>, Eigen::internal::Dense2Dense>::SrcXprType = Eigen::Solve<Eigen::BiCGSTAB<Eigen::SparseMatrix<double>, Eigen::DiagonalPreconditioner<double> >, Eigen::Matrix<double, -1, 1> >]’
/usr/include/eigen3/Eigen/src/Core/AssignEvaluator.h:836:49:   required from ‘void Eigen::internal::call_assignment_no_alias(Dst&, const Src&, const Func&) [with Dst = Eigen::Matrix<double, -1, 1>; Src = Eigen::Solve<Eigen::BiCGSTAB<Eigen::SparseMatrix<double>, Eigen::DiagonalPreconditioner<double> >, Eigen::Matrix<double, -1, 1> >; Func = Eigen::internal::assign_op<double, double>]’
/usr/include/eigen3/Eigen/src/Core/PlainObjectBase.h:732:41:   required from ‘Derived& Eigen::PlainObjectBase<Derived>::_set_noalias(const Eigen::DenseBase<OtherDerived>&) [with OtherDerived = Eigen::Solve<Eigen::BiCGSTAB<Eigen::SparseMatrix<double>, Eigen::DiagonalPreconditioner<double> >, Eigen::Matrix<double, -1, 1> >; Derived = Eigen::Matrix<double, -1, 1>]’
/usr/include/eigen3/Eigen/src/Core/PlainObjectBase.h:816:7:   required from ‘void Eigen::PlainObjectBase<Derived>::_init1(const Eigen::DenseBase<ElseDerived>&) [with T = Eigen::Solve<Eigen::BiCGSTAB<Eigen::SparseMatrix<double>, Eigen::DiagonalPreconditioner<double> >, Eigen::Matrix<double, -1, 1> >; OtherDerived = Eigen::Solve<Eigen::BiCGSTAB<Eigen::SparseMatrix<double>, Eigen::DiagonalPreconditioner<double> >, Eigen::Matrix<double, -1, 1> >; Derived = Eigen::Matrix<double, -1, 1>]’
/usr/include/eigen3/Eigen/src/Core/Matrix.h:294:31:   required from ‘Eigen::Matrix<_Scalar, _Rows, _Cols, _Options, _MaxRows, _MaxCols>::Matrix(const T&) [with T = Eigen::Solve<Eigen::BiCGSTAB<Eigen::SparseMatrix<double>, Eigen::DiagonalPreconditioner<double> >, Eigen::Matrix<double, -1, 1> >; _Scalar = double; int _Rows = -1; int _Cols = 1; int _Options = 0; int _MaxRows = -1; int _MaxCols = 1]’
/home/barf/melowntech/vts-tools/tools/src/imgproc/scattered-interpolation.cpp:109:42:   required from here
/usr/include/eigen3/Eigen/src/Core/CwiseBinaryOp.h:105:49: error: implicitly-declared ‘constexpr Eigen::ArrayWrapper<const Eigen::Matrix<double, -1, 1> >::ArrayWrapper(const Eigen::ArrayWrapper<const Eigen::Matrix<double, -1, 1> >&)’ is deprecated [-Werror=deprecated-copy]
  105 |       : m_lhs(aLhs), m_rhs(aRhs), m_functor(func)
      |                                                 ^
In file included from /usr/include/eigen3/Eigen/Core:448,
                 from /usr/include/eigen3/Eigen/SparseCore:11,
                 from /usr/include/eigen3/Eigen/Sparse:26,
                 from /home/barf/melowntech/vts-tools/tools/src/imgproc/scattered-interpolation.cpp:28:
/usr/include/eigen3/Eigen/src/Core/ArrayBase.h:107:14: note: because ‘Eigen::ArrayWrapper<const Eigen::Matrix<double, -1, 1> >’ has user-provided ‘Derived& Eigen::ArrayBase<Derived>::operator=(const Eigen::ArrayBase<Derived>&) [with Derived = Eigen::ArrayWrapper<const Eigen::Matrix<double, -1, 1> >]’
  107 |     Derived& operator=(const ArrayBase& other)
      |              ^~~~~~~~
In file included from /usr/include/eigen3/Eigen/Core:461,
                 from /usr/include/eigen3/Eigen/SparseCore:11,
                 from /usr/include/eigen3/Eigen/Sparse:26,
                 from /home/barf/melowntech/vts-tools/tools/src/imgproc/scattered-interpolation.cpp:28:
/usr/include/eigen3/Eigen/src/Core/CwiseBinaryOp.h:105:49: error: implicitly-declared ‘constexpr Eigen::ArrayWrapper<const Eigen::Matrix<double, -1, 1> >::ArrayWrapper(const Eigen::ArrayWrapper<const Eigen::Matrix<double, -1, 1> >&)’ is deprecated [-Werror=deprecated-copy]
  105 |       : m_lhs(aLhs), m_rhs(aRhs), m_functor(func)
      |                                                 ^
In file included from /usr/include/eigen3/Eigen/Core:448,
                 from /usr/include/eigen3/Eigen/SparseCore:11,
                 from /usr/include/eigen3/Eigen/Sparse:26,
                 from /home/barf/melowntech/vts-tools/tools/src/imgproc/scattered-interpolation.cpp:28:
/usr/include/eigen3/Eigen/src/Core/ArrayBase.h:107:14: note: because ‘Eigen::ArrayWrapper<const Eigen::Matrix<double, -1, 1> >’ has user-provided ‘Derived& Eigen::ArrayBase<Derived>::operator=(const Eigen::ArrayBase<Derived>&) [with Derived = Eigen::ArrayWrapper<const Eigen::Matrix<double, -1, 1> >]’
  107 |     Derived& operator=(const ArrayBase& other)
      |              ^~~~~~~~
In file included from /usr/include/eigen3/Eigen/SparseCore:58,
                 from /usr/include/eigen3/Eigen/Sparse:26,
                 from /home/barf/melowntech/vts-tools/tools/src/imgproc/scattered-interpolation.cpp:28:
/usr/include/eigen3/Eigen/src/SparseCore/SparseDenseProduct.h: In instantiation of ‘static void Eigen::internal::generic_product_impl<Lhs, Rhs, Eigen::SparseShape, Eigen::DenseShape, ProductType>::scaleAndAddTo(Dest&, const Lhs&, const Rhs&, const Scalar&) [with Dest = Eigen::Matrix<double, -1, 1>; Lhs = Eigen::Ref<const Eigen::SparseMatrix<double>, 0, Eigen::OuterStride<> >; Rhs = Eigen::Block<Eigen::Matrix<double, -1, 1>, -1, 1, true>; int ProductType = 7; Eigen::internal::generic_product_impl<Lhs, Rhs, Eigen::SparseShape, Eigen::DenseShape, ProductType>::Scalar = double]’:
/usr/include/eigen3/Eigen/src/Core/ProductEvaluators.h:361:27:   required from ‘static void Eigen::internal::generic_product_impl_base<Lhs, Rhs, Derived>::scaleAndAddTo(Dst&, const Lhs&, const Rhs&, const Scalar&) [with Dst = Eigen::Matrix<double, -1, 1>; Lhs = Eigen::Ref<const Eigen::SparseMatrix<double>, 0, Eigen::OuterStride<> >; Rhs = Eigen::Block<Eigen::Matrix<double, -1, 1>, -1, 1, true>; Derived = Eigen::internal::generic_product_impl<Eigen::Ref<const Eigen::SparseMatrix<double>, 0, Eigen::OuterStride<> >, Eigen::Block<Eigen::Matrix<double, -1, 1>, -1, 1, true>, Eigen::SparseShape, Eigen::DenseShape, 7>; Eigen::internal::generic_product_impl_base<Lhs, Rhs, Derived>::Scalar = double]’
/usr/include/eigen3/Eigen/src/Core/ProductEvaluators.h:357:18:   required from ‘static void Eigen::internal::generic_product_impl_base<Lhs, Rhs, Derived>::subTo(Dst&, const Lhs&, const Rhs&) [with Dst = Eigen::Matrix<double, -1, 1>; Lhs = Eigen::Ref<const Eigen::SparseMatrix<double>, 0, Eigen::OuterStride<> >; Rhs = Eigen::Block<Eigen::Matrix<double, -1, 1>, -1, 1, true>; Derived = Eigen::internal::generic_product_impl<Eigen::Ref<const Eigen::SparseMatrix<double>, 0, Eigen::OuterStride<> >, Eigen::Block<Eigen::Matrix<double, -1, 1>, -1, 1, true>, Eigen::SparseShape, Eigen::DenseShape, 7>]’
/usr/include/eigen3/Eigen/src/Core/ProductEvaluators.h:178:42:   required from ‘static void Eigen::internal::Assignment<DstXprType, Eigen::Product<Lhs, Rhs, Options>, Eigen::internal::sub_assign_op<Scalar, Scalar>, Eigen::internal::Dense2Dense, typename Eigen::internal::enable_if<((Options == Eigen::DefaultProduct) || (Options == Eigen::AliasFreeProduct))>::type>::run(DstXprType&, const SrcXprType&, const Eigen::internal::sub_assign_op<Scalar, Scalar>&) [with DstXprType = Eigen::Matrix<double, -1, 1>; Lhs = Eigen::Ref<const Eigen::SparseMatrix<double>, 0, Eigen::OuterStride<> >; Rhs = Eigen::Block<Eigen::Matrix<double, -1, 1>, -1, 1, true>; int Options = 0; Scalar = double; Eigen::internal::Assignment<DstXprType, Eigen::Product<Lhs, Rhs, Options>, Eigen::internal::sub_assign_op<Scalar, Scalar>, Eigen::internal::Dense2Dense, typename Eigen::internal::enable_if<((Options == Eigen::DefaultProduct) || (Options == Eigen::AliasFreeProduct))>::type>::SrcXprType = Eigen::Product<Eigen::Ref<const Eigen::SparseMatrix<double>, 0, Eigen::OuterStride<> >, Eigen::Block<Eigen::Matrix<double, -1, 1>, -1, 1, true>, 0>]’
/usr/include/eigen3/Eigen/src/Core/AssignEvaluator.h:836:49:   required from ‘void Eigen::internal::call_assignment_no_alias(Dst&, const Src&, const Func&) [with Dst = Eigen::Matrix<double, -1, 1>; Src = Eigen::Product<Eigen::Ref<const Eigen::SparseMatrix<double>, 0, Eigen::OuterStride<> >, Eigen::Block<Eigen::Matrix<double, -1, 1>, -1, 1, true>, 0>; Func = Eigen::internal::sub_assign_op<double, double>]’
/usr/include/eigen3/Eigen/src/Core/ProductEvaluators.h:224:29:   required from ‘static void Eigen::internal::assignment_from_xpr_op_product<DstXprType, OtherXpr, ProductType, Func1, Func2>::run(DstXprType&, const SrcXprType&, const InitialFunc&) [with SrcXprType = Eigen::CwiseBinaryOp<Eigen::internal::scalar_difference_op<double, double>, const Eigen::Block<const Eigen::Matrix<double, -1, 1>, -1, 1, true>, const Eigen::Product<Eigen::Ref<const Eigen::SparseMatrix<double>, 0, Eigen::OuterStride<> >, Eigen::Block<Eigen::Matrix<double, -1, 1>, -1, 1, true>, 0> >; InitialFunc = Eigen::internal::assign_op<double, double>; DstXprType = Eigen::Matrix<double, -1, 1>; OtherXpr = Eigen::Block<const Eigen::Matrix<double, -1, 1>, -1, 1, true>; ProductType = Eigen::Product<Eigen::Ref<const Eigen::SparseMatrix<double>, 0, Eigen::OuterStride<> >, Eigen::Block<Eigen::Matrix<double, -1, 1>, -1, 1, true>, 0>; Func1 = Eigen::internal::assign_op<double, double>; Func2 = Eigen::internal::sub_assign_op<double, double>]’
/usr/include/eigen3/Eigen/src/Core/AssignEvaluator.h:836:49:   [ skipping 7 instantiation contexts, use -ftemplate-backtrace-limit=0 to disable ]
/usr/include/eigen3/Eigen/src/Core/Solve.h:147:5:   required from ‘static void Eigen::internal::Assignment<DstXprType, Eigen::Solve<DecType, RhsType>, Eigen::internal::assign_op<Scalar, Scalar>, Eigen::internal::Dense2Dense>::run(DstXprType&, const SrcXprType&, const Eigen::internal::assign_op<Scalar, Scalar>&) [with DstXprType = Eigen::Matrix<double, -1, 1>; DecType = Eigen::BiCGSTAB<Eigen::SparseMatrix<double>, Eigen::DiagonalPreconditioner<double> >; RhsType = Eigen::Matrix<double, -1, 1>; Scalar = double; Eigen::internal::Assignment<DstXprType, Eigen::Solve<DecType, RhsType>, Eigen::internal::assign_op<Scalar, Scalar>, Eigen::internal::Dense2Dense>::SrcXprType = Eigen::Solve<Eigen::BiCGSTAB<Eigen::SparseMatrix<double>, Eigen::DiagonalPreconditioner<double> >, Eigen::Matrix<double, -1, 1> >]’
/usr/include/eigen3/Eigen/src/Core/AssignEvaluator.h:836:49:   required from ‘void Eigen::internal::call_assignment_no_alias(Dst&, const Src&, const Func&) [with Dst = Eigen::Matrix<double, -1, 1>; Src = Eigen::Solve<Eigen::BiCGSTAB<Eigen::SparseMatrix<double>, Eigen::DiagonalPreconditioner<double> >, Eigen::Matrix<double, -1, 1> >; Func = Eigen::internal::assign_op<double, double>]’
/usr/include/eigen3/Eigen/src/Core/PlainObjectBase.h:732:41:   required from ‘Derived& Eigen::PlainObjectBase<Derived>::_set_noalias(const Eigen::DenseBase<OtherDerived>&) [with OtherDerived = Eigen::Solve<Eigen::BiCGSTAB<Eigen::SparseMatrix<double>, Eigen::DiagonalPreconditioner<double> >, Eigen::Matrix<double, -1, 1> >; Derived = Eigen::Matrix<double, -1, 1>]’
/usr/include/eigen3/Eigen/src/Core/PlainObjectBase.h:816:7:   required from ‘void Eigen::PlainObjectBase<Derived>::_init1(const Eigen::DenseBase<ElseDerived>&) [with T = Eigen::Solve<Eigen::BiCGSTAB<Eigen::SparseMatrix<double>, Eigen::DiagonalPreconditioner<double> >, Eigen::Matrix<double, -1, 1> >; OtherDerived = Eigen::Solve<Eigen::BiCGSTAB<Eigen::SparseMatrix<double>, Eigen::DiagonalPreconditioner<double> >, Eigen::Matrix<double, -1, 1> >; Derived = Eigen::Matrix<double, -1, 1>]’
/usr/include/eigen3/Eigen/src/Core/Matrix.h:294:31:   required from ‘Eigen::Matrix<_Scalar, _Rows, _Cols, _Options, _MaxRows, _MaxCols>::Matrix(const T&) [with T = Eigen::Solve<Eigen::BiCGSTAB<Eigen::SparseMatrix<double>, Eigen::DiagonalPreconditioner<double> >, Eigen::Matrix<double, -1, 1> >; _Scalar = double; int _Rows = -1; int _Cols = 1; int _Options = 0; int _MaxRows = -1; int _MaxCols = 1]’
/home/barf/melowntech/vts-tools/tools/src/imgproc/scattered-interpolation.cpp:109:42:   required from here
/usr/include/eigen3/Eigen/src/SparseCore/SparseDenseProduct.h:168:15: error: implicitly-declared ‘Eigen::Block<Eigen::Matrix<double, -1, 1>, -1, 1, true>::Block(const Eigen::Block<Eigen::Matrix<double, -1, 1>, -1, 1, true>&)’ is deprecated [-Werror=deprecated-copy]
  168 |     RhsNested rhsNested(rhs);
      |               ^~~~~~~~~
In file included from /usr/include/eigen3/Eigen/Core:88,
                 from /usr/include/eigen3/Eigen/SparseCore:11,
                 from /usr/include/eigen3/Eigen/Sparse:26,
                 from /home/barf/melowntech/vts-tools/tools/src/imgproc/scattered-interpolation.cpp:28:
/usr/include/eigen3/Eigen/src/Core/util/Macros.h:830:52: note: because ‘Eigen::Block<Eigen::Matrix<double, -1, 1>, -1, 1, true>’ has user-provided ‘Eigen::BlockImpl<XprType, BlockRows, BlockCols, InnerPanel, Eigen::Dense>& Eigen::BlockImpl<XprType, BlockRows, BlockCols, InnerPanel, Eigen::Dense>::operator=(const Eigen::BlockImpl<XprType, BlockRows, BlockCols, InnerPanel, Eigen::Dense>&) [with XprType = Eigen::Matrix<double, -1, 1>; int BlockRows = -1; int BlockCols = 1; bool InnerPanel = true]’
  830 |     EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE Derived& operator=(const Derived& other) \
      |                                                    ^~~~~~~~
/usr/include/eigen3/Eigen/src/Core/util/Macros.h:842:53: note: in expansion of macro ‘EIGEN_INHERIT_ASSIGNMENT_EQUAL_OPERATOR’
  842 | #define EIGEN_INHERIT_ASSIGNMENT_OPERATORS(Derived) EIGEN_INHERIT_ASSIGNMENT_EQUAL_OPERATOR(Derived)
      |                                                     ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/usr/include/eigen3/Eigen/src/Core/Block.h:161:5: note: in expansion of macro ‘EIGEN_INHERIT_ASSIGNMENT_OPERATORS’
  161 |     EIGEN_INHERIT_ASSIGNMENT_OPERATORS(BlockImpl)
      |     ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
cc1plus: all warnings being treated as errors
make[2]: *** [src/imgproc/CMakeFiles/imgproc.dir/build.make:297: src/imgproc/CMakeFiles/imgproc.dir/scattered-interpolation.cpp.o] Error 1
make[2]: *** Waiting for unfinished jobs....
make[1]: *** [CMakeFiles/Makefile2:488: src/imgproc/CMakeFiles/imgproc.dir/all] Error 2
make: *** [Makefile:130: all] Error 2
make: *** [Makefile:24: all] Error 2
vaclavblazek commented 5 years ago

I'll have a look, however probably not today.

BTW, 19.10 is Eoan Ermine, not Disco Dingo (which is 19.04). My bad.

barf commented 5 years ago

Thank you!

Maybe the warnings being treated as errors setting is the problem, I see an error about deprecated functions here, I will look into that.

But it's not urgent, I just wanted to try and get some I3S/SLPK data into blender for game development, the slpk2obj tool looked good for that, but now it's a big adventure into VTS :-)

barf commented 5 years ago

Removing -Werror from CMAKE_CXX_FLAGS in buildsys/cmake/buildsys.cmake resolved the problem linking to eigen3.

It was the warning about deprecated functions causing the build to fail. But then I got stuck building support.cpp in vts-libs:

[ 58%] Building CXX object src/vts-libs/CMakeFiles/vts-libs-core.dir/vts/vts.cpp.o
/home/barf/melowntech/vts-tools/tools/src/vts-libs/vts/support.cpp:37:54: error: non-local lambda expression cannot have a capture-default
   37 | const storage::SupportFile::Vars defaultSupportVars([&]()
      |                                                      ^

So I removed the & on this line and the build succeeded (with warnings) on 19.10!

Some typos prevented slpk2obj from compiling, I think I fixed those but it's 4am here in NZ and might work on a pull request tomorrow. Still unsure how to get CMake to build the slpk2obj binary, be grateful for any advice on how to setup the CMakeLists.txt to build that executable!

vaclavblazek commented 5 years ago

Great! I'll have a look on the eigen issue and fix the lambda. Use make slpk2obj to build the binary. It ends up in bin/slpk2obj (bin is a convenience symlink to build/bin). I hope our SLPK support will work for you. We have implemented only a subset suitable for our needs (textured triangle meshes).

Re game development: VTS is a complex system for 3D map streaming but if you are into game development, check out our opensource Unity 3D plugin based on a C++ VTS browser. There are two demos: a jet fighter and a car driving, all here, on github.

vaclavblazek commented 5 years ago

OK, I fixed all gcc-9-related problems and commited all in the repo. To update, use (in project root) git pull --recurse-submodules git submodule update --init --recursive

You'd maybe get modified files standing in the way, so please check them first to their original value if that happens.

barf commented 3 years ago

Hello again! Hope all is well!

I finally got around to building slpk2obj here, only had to replace CV_LOAD_IMAGE_COLOR with cv::IMREAD_COLOR in slpk2obj.cpp, but it core dumps on the SLPK archives I'm trying to use:

$ slpk2obj --input A_Kaiwharawhara.slpk --output A_Kaiwharawhara.obj --srs epsg:3857
2021-01-06 11:18:06 I4 [421747(main)]: Opening SLPK archive at "A_Kaiwharawhara.slpk". {slpk2obj.cpp:run():486}
2021-01-06 11:18:06 I4 [421747(main)]: Generating textured meshes at "A_Kaiwharawhara.obj". {slpk2obj.cpp:run():488}
terminate called after throwing an instance of 'geo::ProjectionError'
  what():  Cannot convert point [3](174.787725,-41.257063,37.340665) between coordinate systems: <>. @{csconvertor.cpp:convert():144}
Aborted (core dumped)

AFAIK the SLPK files are ok, and are just EPSG:4326, is there any other info that would help?