Page MenuHomePhabricator

OpenIGTlink does not build in superbuild [Ubuntu 18.04]
Closed, ResolvedPublic

Description

In Ubuntu 18.04 gcc is upgraded to v7.3
this (in combination with us using a 2014 commit of oigtl) is probably why this happens:

.../mitk-superbuild/ep/src/OpenIGTLink/Source/igtlNDArrayMessage.h: In member function ‘int igtl::Array<T>::SetValue(igtl::ArrayBase::IndexType, T)’:
.../mitk-superbuild/ep/src/OpenIGTLink/Source/igtlNDArrayMessage.h:94:62: error: ‘void*’ is not a pointer-to-object type
       * (T *) this->m_ByteArray[Get1DIndex(index) * sizeof(T)] = value;

Event Timeline

kirchnth created this task.
kislinsk renamed this task from OpenIGTlink does not build in superbuild to OpenIGTlink does not build in superbuild [Ubuntu 18.04].May 15 2018, 4:32 PM

What's the status? Is it already mergable for the alpha branch? It will be closed very soon, like possibly Wednesday. As long as it compiles it should be enough for the alpha branch. In beta phase you can still fix other things, but not upgrade any external dependencies anymore.

The OpenIGTLink UI was tested last week by Benjamin and Thomas. I don't think there were problems.

I tried to build this branch with Ubuntu 18.04 and got the following errors during superbuild (seems as the download of the new OpenIGTLibrary needs to be added to the MITK servers):

Make Error at OpenIGTLink-stamp/verify-OpenIGTLink.cmake:11 (message):
  File not found: /home/thomaskirchner/Downloads/OpenIGTLink-release-3.0.zip


CMakeFiles/OpenIGTLink.dir/build.make:89: recipe for target 'ep/src/OpenIGTLink-stamp/OpenIGTLink-download' failed
make[2]: *** [ep/src/OpenIGTLink-stamp/OpenIGTLink-download] Error 1
CMakeFiles/Makefile2:782: recipe for target 'CMakeFiles/OpenIGTLink.dir/all' failed
make[1]: *** [CMakeFiles/OpenIGTLink.dir/all] Error 2
make[1]: *** Waiting for unfinished jobs....
[ 76%] Built target MITK-Data
[ 76%] Built target CTK
[ 81%] Built target ITK
Makefile:129: recipe for target 'all' failed
make: *** [all] Error 2
franza@franz-Precision-M4800:/media/franza/DATAPART1/prg/MITK-Linux/bin$ make -j4
[ 20%] Built target DCMTK
[ 21%] Built target Eigen
[ 22%] Built target GDCM
[ 22%] Built target Poco
[ 27%] Built target HDF5
[ 32%] Built target CppUnit
[ 42%] Built target OpenCV
[ 42%] Built target ANN
[ 47%] Built target VTK
[ 53%] Built target tinyxml
[ 58%] Built target Boost
[ 63%] Built target Qwt
[ 64%] Performing download step (verify and extract) for 'OpenIGTLink'
[ 75%] Built target MITK-Data
[ 76%] Built target CTK
CMake Error at OpenIGTLink-stamp/verify-OpenIGTLink.cmake:11 (message):
  File not found: /home/thomaskirchner/Downloads/OpenIGTLink-release-3.0.zip


[ 81%] Built target ITK

Here is the missing file as downloaded from GitHub:

After adding the file to the folder /home/thomaskirchner/Downloads/ the build went on, but there still is an error when compiling the MITK OpenIGTLink classes:

In file included from /media/franza/DATAPART1/prg/MITK-Linux/src/mitk/Modules/OpenIGTLink/mitkIGTLClient.h:21:0,
                 from /media/franza/DATAPART1/prg/MITK-Linux/src/mitk/Modules/OpenIGTLink/mitkIGTLClient.cpp:17:
/media/franza/DATAPART1/prg/MITK-Linux/src/mitk/Modules/OpenIGTLink/mitkIGTLDevice.h:28:10: fatal error: igtlSocket.h: No such file or directory
 #include "igtlSocket.h"
          ^~~~~~~~~~~~~~
compilation terminated.

Okay, I add the file to the MITK server then.

Done. You should double-check the MD5 of the uploaded file.

groehl raised the priority of this task from High to Unbreak Now!.Aug 13 2018, 1:30 PM
groehl awarded a token.
groehl rescinded a token.
groehl awarded a token.

Please merge into master!

I just tried to build the current beta branch with Ubuntu 18.04 and NavigationModules configuration. I merged this branch, but the build failed. It seems OpenIGTLink was correctly downloaded by the superbuild, but later this error occurred:

/media/franza/DATAPART1/prg/MITK-Linux/src/mitk/Modules/OpenIGTLink/mitkIGTLDevice.h:28:10: fatal error: igtlSocket.h: No such file or directory
 #include "igtlSocket.h"

Did anybody else have this problems? We should really fix that issue and merge the fix to the beta branch as soon as possible.

@franza yes i had the same problem - i did not get around to have a close look at it yet :/

fyi, you can also see if everything works on the dashboard. All Ubuntu dartclients use gcc 7.3.0 and fail in "All" configuration ([All] in build name): http://cdash.mitk.org/index.php?project=MITK&display=project

is the local oigtl zipped source files in that last commit

Remember that you want to have .tar.gz instead of .zip because of the problems with CMake extracting these archives on non-NTFS file systems.

We figured out that the exported target OpenIGTLink does not have any linked libraries. Thank you @kislinsk for your help!

In the CMakeLists.txt of MITK module OpenIGTLink we added the following line to inspect the linked libraries.

get_property(test TARGET OpenIGTLink PROPERTY LINK_LIBRARIES)

It turned out that variable test is empty.

By the way: Linking works fine if OpenIGTLink is built separately and specified in CMake via EXTERNAL_OpenIGTLink_DIR. But the link libraries property is also empty in this case.

This is still an issue. It was dicussed to disable openigtlink otherwise.

If we disable openigtlink, all IGT modules/Plugins won't work. This is not an option for me. I think the main problem is to configure the build system in the right way.

Who is still working on this issue? I can offer to help …

I will have a further look into this the upcoming Community Day.

The migration of the code to OpenIGTLink v3 is done. The branch T24778-MigrationToOpenIGTLinkV3 compiles successfully on Ubuntu 18.04 now.

@franza: It would be great if you could help to verify that the application behavior is the same. We can use the checklist 'MITK to 3D Slicer through OpenIGTLink' as a start. Do you have further ideas on how to test this?

Deleted branch T24778--update-oigtl-to-current-master.

Deleted branch T24778-update-oigtl-to-v3.