Skip to content

Fails to build with gcc 14 #310

@musicinmybrain

Description

@musicinmybrain

Trying to rebuild linbox 1.7.0 with GCC 14.0.1 in Fedora Rawhide, I encounter the following errors:

In file included from ../../linbox/matrix/sparse-matrix.h:76:
../../linbox/matrix/sparsematrix/sparse-ell-matrix.h: In member function 'LinBox::SparseMatrix<_Field, LinBox::SparseM
atrixFormat::ELL>::_IndexedIterator<index_iterator, element_iterator, Field>& LinBox::SparseMatrix<_Field, LinBox::Spa
rseMatrixFormat::ELL>::_IndexedIterator<index_iterator, element_iterator, Field>::operator=(const LinBox::SparseMatrix
<_Field, LinBox::SparseMatrixFormat::ELL>::_IndexedIterator<index_iterator, element_iterator, Field>&)':
../../linbox/matrix/sparsematrix/sparse-ell-matrix.h:1216:44: error: assignment of read-only location '((LinBox::Spars
eMatrix<_Field, LinBox::SparseMatrixFormat::ELL>::_IndexedIterator<index_iterator, element_iterator, Field>*)this)->Li
nBox::SparseMatrix<_Field, LinBox::SparseMatrixFormat::ELL>::_IndexedIterator<index_iterator, element_iterator, Field>
::_ld'
 1216 |                                 _ld        = iter._ld ;
      |                                 ~~~~~~~~~~~^~~~~~~~~~
In file included from ../../linbox/matrix/sparse-matrix.h:77:
../../linbox/matrix/sparsematrix/sparse-ellr-matrix.h: In member function 'LinBox::SparseMatrix<_Field, LinBox::Sparse
MatrixFormat::ELL_R>::_Iterator<element_iterator, Field>& LinBox::SparseMatrix<_Field, LinBox::Spmake[4]: Leaving dire
ctory '/builddir/build/BUILD/linbox-1.7.0/linbox/algorithms'
arseMatrixFormat::ELL_R>::_Iterator<element_iterator, Field>::operator=(const LinBox::SparseMatrix<_Field, LinBox::Spa
rseMatrixFormat::ELL_R>::_Iterator<element_iterator, Field>&)':
../../linbox/matrix/sparsematrix/sparse-ellr-matrix.h:1108:47: error: no match for 'operator=' (operand types are 'con
st std::vector<long unsigned int>' and 'const std::vector<long unsigned int>')
 1108 |                                 _rowid = iter._rowid;
      |                                               ^~~~~~

More context is available in the downstream bug. I haven’t tried to investigate this more closely yet.

(I used the workaround in linbox-team/givaro#226 (comment) to build givaro with GCC 14.)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions