tbeu / matio

MATLAB MAT File I/O Library
https://matio.sourceforge.io
BSD 2-Clause "Simplified" License
330 stars 97 forks source link

issues with hdf5 1.10.5 #112

Closed massich closed 5 years ago

massich commented 5 years ago

In openmeeg in macosx in Travis-CI we are use libmatio from brew and stoped working after https://github.com/Homebrew/homebrew-core/commit/b3eb55b6c5bc1aae035be9867208320fa35c9fe3 was merged. The combination is matio-1.5.12 and hdf5-1.10.5.

Can anyone replicate that matio test suit breaks when using hdf5-1.10.5 ?

here is my trace:

(lldb) bt
* thread #1, queue = 'com.apple.main-thread', stop reason = signal SIGABRT
  * frame #0: 0x00007fff5bfbe23e libsystem_kernel.dylib`__pthread_kill + 10
    frame #1: 0x00007fff5c074c1c libsystem_pthread.dylib`pthread_kill + 285
    frame #2: 0x00007fff5bf271c9 libsystem_c.dylib`abort + 127
    frame #3: 0x0000000100159d98 libhdf5.103.dylib`H5check_version + 588
    frame #4: 0x00000001004899f6 libmatio.4.dylib`Mat_Create73 + 86
    frame #5: 0x000000010010eaba libOpenMEEGMaths.1.dylib`OpenMEEG::maths::MatlabIO::write(this=0x0000000100128c58, os=0x00007ffeefbff1f0, linop=0x00007ffeefbff688) const at MatlabIO.H:218:30
    frame #6: 0x0000000100105760 libOpenMEEGMaths.1.dylib`OpenMEEG::maths::operator<<(OpenMEEG::maths::MathsIO&, OpenMEEG::LinOp const&)(mio=0x00007ffeefbff4a8, linop=0x00007ffeefbff688) at MathsIO.C:89:26
    frame #7: 0x00000001000f1718 libOpenMEEGMaths.1.dylib`OpenMEEG::Vector::save(this=0x00007ffeefbff688, filename="tmp_matrix.mat") const at vector.cpp:165:70
    frame #8: 0x0000000100003591 OpenMEEGMathsTest-vector`main at vector.cpp:69:7
    frame #9: 0x00007fff5be7eed9 libdyld.dylib`start + 1
    frame #10: 0x00007fff5be7eed9 libdyld.dylib`start + 1
(lldb) frame select 5
frame #5: 0x000000010010eaba libOpenMEEGMaths.1.dylib`OpenMEEG::maths::MatlabIO::write(this=0x0000000100128c58, os=0x00007ffeefbff1f0, linop=0x00007ffeefbff688) const at MatlabIO.H:218:30
   215                      os.close();
   216                      std::remove(name().c_str());
   217                  }
-> 218                  mat_t* mat = Mat_CreateVer(name().c_str(),NULL,MAT_FT_MAT73);
   219                  if (!mat)
   220                      throw BadFileOpening(name(),maths::BadFileOpening::WRITE);
   221
(lldb) l
   222                  if (linop.dimension()==1)
   223                      write<Vector>(mat,linop);
   224                  else {
   225                      switch (linop.storageType()) {
   226                          case LinOp::SPARSE:
   227                              write_sparse(mat,linop);
   228                              break;
(lldb)

I would also propose to have some repos with the CI running system recipies: brew, conda, whatever people use. This would allow for early detection of problems.

@tbeu could this be related to fixes in 1.5.13? if so updating brew receipies should fix the problem.

tbeu commented 5 years ago

Seems like a configuration issue, since H5check_version fails. Probably the hdf5 headers that were used when building libmatio do not match the version of the hdf5 libraries.

massich commented 5 years ago

yes that's exactly it. I thought it was in our end, but not. However, having a CI running all these things would allow us to report issues faster. This was broken in Oct 2018. It cannot be that we realize about those things 6 month afterwards.