linbox-team / linbox

LinBox - C++ library for exact, high-performance linear algebra
https://linbox-team.github.io/linbox
GNU Lesser General Public License v2.1
83 stars 28 forks source link

The master branch of linbox does not compile any more #223

Closed ZHG2017 closed 5 years ago

ZHG2017 commented 5 years ago

Having updated givaro, fflasffpack and linbox each for their master branch, make install does not work any more meanwhile givaro and fflasffpack could be compiled correctly with no error. And please find the error message for compiling linbox as follows:

In file included from ../../linbox/solutions/methods.h:25:0,
                 from ../../linbox/algorithms/rational-solver.h:41,
                 from ../../linbox/algorithms/diophantine-solver.h:29,
                 from diophantine-solver.C:26:
../../linbox/field/field-traits.h:88:12: error: redefinition of ‘struct LinBox::ClassifyRing<Givaro::ZRing<Givaro::Integer> >’
     struct ClassifyRing<Givaro::IntegerDom> {
            ^
../../linbox/field/field-traits.h:84:12: error: previous definition of ‘struct LinBox::ClassifyRing<Givaro::ZRing<Givaro::Integer> >’
     struct ClassifyRing<Givaro::ZRing<Givaro::Integer>> {
            ^
In file included from ../../linbox/matrix/densematrix/blas-matrix.h:43:0,
                 from ../../linbox/matrix/dense-matrix.h:79,
                 from ../../linbox/solutions/methods.h:26,
                 from ../../linbox/algorithms/rational-solver.h:41,
                 from ../../linbox/algorithms/diophantine-solver.h:29,
                 from diophantine-solver.C:26:
../../linbox/field/hom.h:274:28: error: ‘Element’ in ‘LinBox::Hom<Givaro::QField<Givaro::Rational>, _Target>::Source {aka class Givaro::QField<Givaro::Rational>}’ does not name a type
   typedef typename Source::Element SrcElt;
                            ^
../../linbox/field/hom.h:305:10: error: field ‘_source’ has incomplete type ‘LinBox::Hom<Givaro::QField<Givaro::Rational>, _Target>::Source {aka Givaro::QField<Givaro::Rational>}’
   Source _source;
          ^
In file included from ../../linbox/field/field-traits.h:28:0,
                 from ../../linbox/solutions/methods.h:25,
                 from ../../linbox/algorithms/rational-solver.h:41,
                 from ../../linbox/algorithms/diophantine-solver.h:29,
                 from diophantine-solver.C:26:
/home/zhg/soft/builds/include/givaro/givrational.h:49:11: note: declaration of ‘LinBox::Hom<Givaro::QField<Givaro::Rational>, _Target>::Source {aka class Givaro::QField<Givaro::Rational>}’
     class QField;
ZHG2017 commented 5 years ago

Sorry, I did not paste all the message here are the next part of the error message:

In file included from ../../linbox/matrix/densematrix/blas-matrix.h:43:0,
                 from ../../linbox/matrix/dense-matrix.h:79,
                 from ../../linbox/solutions/methods.h:26,
                 from ../../linbox/algorithms/rational-solver.h:41,
                 from ../../linbox/algorithms/diophantine-solver.h:29,
                 from diophantine-solver.C:26:
../../linbox/field/hom.h: In member function ‘LinBox::Hom<Givaro::QField<Givaro::Rational>, _Target>::Elt& LinBox::Hom<Givaro::QField<Givaro::Rational>, _Target>::image(LinBox::Hom<Givaro::QField<Givaro::Rational>, _Target>::Elt&, const SrcElt&)’:
../../linbox/field/hom.h:281:24: error: request for member ‘deno’ in ‘s’, which is of non-class type ‘const SrcElt {aka const int}’
    if (_source.isOne(s.deno())) {
                        ^
../../linbox/field/hom.h:282:29: error: request for member ‘nume’ in ‘s’, which is of non-class type ‘const SrcElt {aka const int}’
     return _target.init(t,s.nume());
                             ^
../../linbox/field/hom.h:284:29: error: request for member ‘nume’ in ‘s’, which is of non-class type ‘const SrcElt {aka const int}’
    else if (_source.isOne(s.nume())) {
                             ^
../../linbox/field/hom.h:285:22: error: request for member ‘deno’ in ‘s’, which is of non-class type ‘const SrcElt {aka const int}’
     _target.init(t,s.deno());
                      ^
../../linbox/field/hom.h:289:27: error: request for member ‘deno’ in ‘s’, which is of non-class type ‘const SrcElt {aka const int}’
     _target. init (tmp, s.deno());
                           ^
../../linbox/field/hom.h:290:25: error: request for member ‘nume’ in ‘s’, which is of non-class type ‘const SrcElt {aka const int}’
     _target. init (t, s.nume());
                         ^
../../linbox/field/hom.h: In member function ‘LinBox::Hom<Givaro::QField<Givaro::Rational>, _Target>::SrcElt& LinBox::Hom<Givaro::QField<Givaro::Rational>, _Target>::preimage(LinBox::Hom<Givaro::QField<Givaro::Rational>, _Target>::SrcElt&, const Elt&)’:
../../linbox/field/hom.h:296:24: error: request for member ‘nume’ in ‘s’, which is of non-class type ‘LinBox::Hom<Givaro::QField<Givaro::Rational>, _Target>::SrcElt {aka int}’
    _target. convert (s.nume(), t);
                        ^
../../linbox/field/hom.h:297:24: error: request for member ‘nume’ in ‘s’, which is of non-class type ‘LinBox::Hom<Givaro::QField<Givaro::Rational>, _Target>::SrcElt {aka int}’
    _source. init (s, s.nume());
                        ^
../../linbox/field/hom.h: At global scope:
../../linbox/field/hom.h:315:19: error: ‘Element’ in ‘LinBox::Hom<Givaro::QField<Givaro::Rational>, Givaro::QField<Givaro::Rational> >::Domain {aka class Givaro::QField<Givaro::Rational>}’ does not name a type
   typedef Domain::Element Elt;
                   ^
../../linbox/field/hom.h:318:3: error: ‘Elt’ does not name a type
   Elt& image(Elt& t, const Elt& s) const { return t=s; }
   ^
../../linbox/field/hom.h:320:3: error: ‘Elt’ does not name a type
   Elt& preimage(Elt& s, const Elt& t) const { return s=t; }
   ^
In file included from ../../linbox/algorithms/rational-reconstruction.h:40:0,
                 from ../../linbox/algorithms/./dixon-solver/./dixon-solver-dense.inl:28,
                 from ../../linbox/algorithms/./dixon-solver/dixon-solver-dense.h:363,
                 from ../../linbox/algorithms/rational-solver.h:583,
                 from ../../linbox/algorithms/diophantine-solver.h:29,
                 from diophantine-solver.C:26:
../../linbox/algorithms/rational-reconstruction-base.h: In member function ‘bool LinBox::RReconstructionBase<Givaro::ZRing<Givaro::Integer> >::reconstructRational(LinBox::RReconstructionBase<Givaro::ZRing<Givaro::Integer> >::Element&, LinBox::RReconstructionBase<Givaro::ZRing<Givaro::Integer> >::Element&, const Element&, const Element&)’:
../../linbox/algorithms/rational-reconstruction-base.h:337:20: error: ‘LinBox::RReconstructionBase<Givaro::ZRing<Givaro::Integer> >::Ring {aka class Givaro::ZRing<Givaro::Integer>}’ has no member named ‘reconstructRational’
    return _intRing.reconstructRational(a,b,x,m,a_bound,a_bound);
                    ^
../../linbox/algorithms/rational-reconstruction-base.h: In member function ‘bool LinBox::RReconstructionBase<Givaro::ZRing<Givaro::Integer> >::reconstructRational(LinBox::RReconstructionBase<Givaro::ZRing<Givaro::Integer> >::Element&, LinBox::RReconstructionBase<Givaro::ZRing<Givaro::Integer> >::Element&, const Element&, const Element&, const Element&)’:
../../linbox/algorithms/rational-reconstruction-base.h:342:13: error: ‘LinBox::RReconstructionBase<Givaro::ZRing<Givaro::Integer> >::Ring {aka class Givaro::ZRing<Givaro::Integer>}’ has no member named ‘reconstructRational’
    _intRing.reconstructRational(a,b,x,m,a_bound);
Breush commented 5 years ago

Should be fixed by #221. This is due to Givaro's ZRing update being merged, but the update not done in LinBox.

ZHG2017 commented 5 years ago

I have just got all master branches updated but the linbox still does not compile properly

Breush commented 5 years ago

@ZHG2017 Yeah, go on the zring-refactor branch in LinBox.

ZHG2017 commented 5 years ago

Affirmative... ... The zring-refactor branch compiles correctly.

Breush commented 5 years ago

@ZHG2017 I merged it on master then, should be ok from now on.

ZHG2017 commented 5 years ago

Even with the most recent version from the master branch, I still cannot pass all make check and I got some error message as follows: test-det.C:459:47: required from here ../linbox/algorithms/cra-distributed.h:200:17: error: request for member ‘begin’ in ‘r’, which is of non-class type ‘double’ _pCommunicator->recv(r.begin(), r.end(), _pCommunicator->status().MPI_SOURCE, 0); ^ ../linbox/algorithms/cra-distributed.h:200:17: error: request for member ‘end’ in ‘r’, which is of non-class type ‘double’ ../linbox/algorithms/cra-distributed.h: In instantiation of ‘void LinBox::ChineseRemainderDistributed::worker_process_task(Function&, Vect&) [with Vect = double; Function = LinBox::IntegerModularDet<LinBox::SparseMatrix<Givaro::ZRing

, LinBox::Method::Elimination>; CRABase = LinBox::CRABuilderEarlySingle<Givaro::ModularBalanced >]’: ../linbox/algorithms/cra-distributed.h:132:36: required from ‘void LinBox::ChineseRemainderDistributed::para_compute(Any&, Function&, PrimeIterator&) [with Any = Givaro::Integer; Function = LinBox::IntegerModularDet<LinBox::SparseMatrix<Givaro::ZRing , LinBox::Method::Elimination>; PrimeIterator = LinBox::PrimeIterator; CRABase = LinBox::CRABuilderEarlySingle<Givaro::ModularBalanced >]’ ../linbox/algorithms/cra-distributed.h:113:25: required from ‘Any& LinBox::ChineseRemainderDistributed::operator()(Any&, Function&, PrimeIterator&) [with Any = Givaro::Integer; Function = LinBox::IntegerModularDet<LinBox::SparseMatrix<Givaro::ZRing , LinBox::Method::Elimination>; PrimeIterator = LinBox::PrimeIterator; CRABase = LinBox::CRABuilderEarlySingle<Givaro::ModularBalanced >]’ ../linbox/solutions/det.h:581:6: required from ‘typename Blackbox::Field::Element& LinBox::cra_det(typename Blackbox::Field::Element&, const Blackbox&, const LinBox::RingCategories::IntegerTag&, const MyMethod&, LinBox::Communicator*) [with Blackbox = LinBox::SparseMatrix<Givaro::ZRing >; MyMethod = LinBox::Method::Elimination; typename Blackbox::Field::Element = Givaro::Integer]’ ../linbox/solutions/det.h:620:26: required from ‘typename Blackbox::Field::Element& LinBox::det(typename Blackbox::Field::Element&, const Blackbox&, const LinBox::RingCategories::IntegerTag&, const MyMethod&) [with Blackbox = LinBox::SparseMatrix<Givaro::ZRing >; MyMethod = LinBox::Method::Elimination; typename Blackbox::Field::Element = Givaro::Integer]’ ../linbox/solutions/det.h:107:13: required from ‘typename Blackbox::Field::Element& LinBox::det(typename Blackbox::Field::Element&, const Blackbox&, const MyMethod&) [with Blackbox = LinBox::SparseMatrix<Givaro::ZRing >; MyMethod = LinBox::Method::Elimination; typename Blackbox::Field::Element = Givaro::Integer]’

On Tue, Jul 9, 2019 at 9:46 AM A. Breust notifications@github.com wrote:

Closed #223 https://github.com/linbox-team/linbox/issues/223.

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/linbox-team/linbox/issues/223?email_source=notifications&email_token=AHOVIDRWAMDQEEJGNBMYHT3P6Q63TA5CNFSM4H7COBD2YY3PNVWWK3TUL52HS4DFWZEXG43VMVCXMZLOORHG65DJMZUWGYLUNFXW5KTDN5WW2ZLOORPWSZGOSMQR3NQ#event-2468421046, or mute the thread https://github.com/notifications/unsubscribe-auth/AHOVIDTMFGWHSL2V276QFCTP6Q63TANCNFSM4H7COBDQ .

ZHG2017 commented 5 years ago

And new make check error appears .. ...

test-regression.C:438:16: required from here ../linbox/algorithms/cra-builder-full-multip.h:128:26: error: request for member ‘size’ in ‘e’, which is of non-class type ‘const double’ if (e.size() > dimension) { ^ ../linbox/algorithms/cra-builder-full-multip.h:129:28: error: request for member ‘size’ in ‘e’, which is of non-class type ‘const double’ dimension = e.size(); ^ ../linbox/algorithms/cra-builder-full-multip.h:136:26: error: request for member ‘begin’ in ‘e’, which is of non-class type ‘const double’ progress_iter(D, e.begin(), e.size()); ^ ../linbox/algorithms/cra-builder-full-multip.h:136:26: error: request for member ‘size’ in ‘e’, which is of non-class type ‘const double’