Hi Michel,

we have dedicated CMake code to add the Boost libraries required by SOFA, when 
you switch it on. Atomic and date_time are no hard SOFA dependencies, though. 
Maybe there is a SOFA plugin you have in mind, that is not built by the MITK 
superbuild, that requires Atomic or date_time? Anyways, glad you made it. :-)

There is one thing you may stumble across when making the first steps with MITK 
Simulation: Many of the well-known SOFA example scenes like liver.scn will 
produce errors when loading them with MITK, because they have "magic paths" to 
external files in them, which are supposed to get resolved by a SOFA class 
looking in various fixed known SOFA paths. This is a bit ugly and obviously 
won't work with an external program using SOFA like MITK. In these cases you 
have to specify the full or relative paths in the scene files and it will work 
like a charm again.

We also implemented SOFA components to easily work with MITK data manager 
objects (MITK <-> SOFA bridge), so you can simulate directly on MITK surfaces 
for example. Also the opposite direction is featured (but a bit hidden): You 
can right-click on Visual nodes in the SOFA tree view (simulation plugin), and 
click on "Render to surface". Instead of rendering with OpenGL, this visual is 
then stuffed into an MITK surface (basically wraps a VTK poly data) in the data 
manager, and then rendered by the usual MITK rendering pipeline. Great for 
inter-op and saving simulation results together with the MITK scene.

Best,
Stefan


From: Audette, Michel A. [mailto:maude...@odu.edu]
Sent: Donnerstag, 27. Oktober 2016 15:44
To: Kislinskiy, Stefan; Sascha Zelzer; mitk-users@lists.sourceforge.net
Subject: Re: [mitk-users] Superbuild on Windows MSVC 2012 leads to incomplete 
building of Boost libraries


Dear Stefan and Sascha, and fellow MITK enthusiasts,



I managed after all to compile cleanly on Windows with MSVC 2013, however I 
also specified to use the Boost libraries system;thread;chrono;date_time;atomic 
. I found with my previous builds (based on 2012) that in the regular 
configuration, Boost failed to produce date_time and atomic, and the build 
would complain about these missing libraries.  Lo and behold I noticed on CMake 
that you had only set  system;thread;chrono; by default, which is exactly what 
the build spit out. I don't know if date_time and atomic are requirements of 
SOFA versus the usual build, but all five should be specified in 
MITK_Use_Boost_LIBRARIES .  I could probably go back to 2012 with the full 
Boost instruction and try again, but at this point, why mess with it?



I will doubtless have questions for you on the use of SOFA objects imbedded in 
the code.



Thanks for your support.



Michel


Michel Audette, Ph.D.
Assistant Professor,
Department of Modeling, Simulation and Visualization Engineering,
Old Dominion University,
Norfolk, VA.

________________________________
From: Kislinskiy, Stefan 
<s.kislins...@dkfz-heidelberg.de<mailto:s.kislins...@dkfz-heidelberg.de>>
Sent: Wednesday, October 26, 2016 8:07:44 AM
To: Audette, Michel A.; Sascha Zelzer; 
mitk-users@lists.sourceforge.net<mailto:mitk-users@lists.sourceforge.net>
Subject: RE: [mitk-users] Superbuild on Windows MSVC 2012 leads to incomplete 
building of Boost libraries

Hi Michel,

There's a CMake warning when the path chosen for the build is too long. We also 
mention it quite explicitly in some tutorials like [1], but you're totally 
right, we need to place a hint more prominently in our documentation. BTW, it's 
a Windows-related problem, so you don't have that limitations on Linux and OS X.

However, everything works perfectly for me on Windows 8.1 with MSVC 2013 Update 
5. Here is what I did:

I cloned MITK 2015.05.2:

D:\>git clone --branch v2015.05.2 
https://phabricator.mitk.org/diffusion/MITK/mitk.git 
MITK-2015.05.2<https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fphabricator.mitk.org%2Fdiffusion%2FMITK%2Fmitk.git%2520MITK-2015.05.2&data=01%7C01%7Cmaudette%40odu.edu%7Cceab87aa57434c4f3ee608d3fd98bfde%7C48bf86e811a24b8a8cb368d8be2227f3%7C0&sdata=xPuCmOPIYlKy1ZWSl6JB87M9y9LLNjlpLtRWKQDooqU%3D&reserved=0>

I opened CMake 3.6.2 GUI, set the build directory to 
D:\MITK-2015.05.2-superbuild and set the following variables:

I added the variable CMAKE_PREFIX_PATH and set it to my Qt installation 
"C:\Qt\5.4\msvc2013_64_opengl", enabled MITK_USE_SOFA, clicked on "Configure" 
and then added "date_time" as well as "atomic" to MITK_USE_Boost_LIBRARIES, so 
it reads "system;thread;chrono;date_time;atomic". To speed things up I also 
switched off "MITK_BUILD_TESTING". I configured/generated the superbuild 
solution again.

I then opened the generated MITK-superbuild solution and built "MITK-Configure" 
in Release configuration.

Both date_time and atomic were built and installed properly besides the other 
Boost libraries.

After it was done, I opened CMake again and set the build directory to 
D:\MITK-2015.05.2\MITK-build this time to configure the MITK build itself:

I switched on MITK_BUILD_org.mitk.gui.qt.simulation and configured/generated.

Finally I opened the generated MITK.sln via the according batch file 
"D:\MITK-2015.05.2\MITK-build\StartVS_release.bat", built MitkWorkbench in 
release mode and successfully started the application afterwards (remember to 
set MitkWorkbench as startup project in MSVC).

Hope that helps.
Stefan

[1] 
http://mitk.org/wiki/Developer_Tutorial_(Microsoft_Windows)<https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fmitk.org%2Fwiki%2FDeveloper_Tutorial_(Microsoft_Windows)&data=01%7C01%7Cmaudette%40odu.edu%7Cceab87aa57434c4f3ee608d3fd98bfde%7C48bf86e811a24b8a8cb368d8be2227f3%7C0&sdata=h8Ze%2Fq8Oj%2FaNKet7OuC%2FDdL8vUu3wQUCSQGs9%2BMovHs%3D&reserved=0>


From: Audette, Michel A. [mailto:maude...@odu.edu]
Sent: Dienstag, 25. Oktober 2016 22:33
To: Kislinskiy, Stefan; Sascha Zelzer; 
mitk-users@lists.sourceforge.net<mailto:mitk-users@lists.sourceforge.net>
Subject: Re: [mitk-users] Superbuild on Windows MSVC 2012 leads to incomplete 
building of Boost libraries


Still seeing an incomplete build of the internal Boost with MSVC 2012.


17>    Boost version: 1.56.0
17>
17>    Boost include path: C:/MITK/MITK15052MSVC2012/ep/include/boost-1_56
17>
17>    Could not find the following Boost libraries:
17>
17>            boost_date_time
17>            boost_atomic
17>
17>    Some (but not all) of the required Boost libraries were found.  You may
17>    need to install these additional Boost libraries.  Alternatively, set
17>    BOOST_LIBRARYDIR to the directory containing Boost libraries or 
BOOST_ROOT
17>    to the location of Boost.
17>  Call Stack (most recent call first):
17>    cmake/externals.cmake:84 (find_package)
17>    CMakeLists.txt:46 (include)
17>


There must be something wrong in the internal Boost setup in MITK. It does not 
make sense that the build process would successfully produce boost_thread, 
boost_chrono and boost_system, while failing to produce boost_data_time and 
boost_atomic. That does not jibe at all.



Anyhow, I will retry with both an external Boost with MSVC 2012 as well as with 
MSVC 2013, once I get it installed.



Warm wishes,



Michel






Michel Audette, Ph.D.
Assistant Professor,
Department of Modeling, Simulation and Visualization Engineering,
Old Dominion University,
Norfolk, VA.

________________________________
From: Audette, Michel A.
Sent: Tuesday, October 25, 2016 3:48:54 PM
To: Kislinskiy, Stefan; Sascha Zelzer; 
mitk-users@lists.sourceforge.net<mailto:mitk-users@lists.sourceforge.net>
Subject: Re: [mitk-users] Superbuild on Windows MSVC 2012 leads to incomplete 
building of Boost libraries


Hi again,



please disregard the previous message. I had intended to set the external Boost 
path and ended up setting the GLUT path by mistake.



I am trying again with a fresh build. I have found that the superbuild fails 
due to ITK if the ITK path is longer than 50 characters, so I am trying once 
more with a shorter total pathname. I don't know if it says that on your 
website, but you should state that somewhere. Still building right now; will 
follow up shortly.



Cheers,



Michel


Michel Audette, Ph.D.
Assistant Professor,
Department of Modeling, Simulation and Visualization Engineering,
Old Dominion University,
Norfolk, VA.

________________________________
From: Audette, Michel A.
Sent: Tuesday, October 25, 2016 2:18:50 PM
To: Kislinskiy, Stefan; Sascha Zelzer; 
mitk-users@lists.sourceforge.net<mailto:mitk-users@lists.sourceforge.net>
Subject: Re: [mitk-users] Superbuild on Windows MSVC 2012 leads to incomplete 
building of Boost libraries


Hi Stefan and Sascha,



I neglected to follow up on this due to MICCAI and some proposals that were 
outgoing these past few weeks.



I'm back at it. I am using MSVE 2012, and somehow it complained about Boost, 
but that went away when I gave it an external Boost. The build is still 
complaining about something:

Could NOT find GLUT (missing: GLUT_glut_LIBRARY GLUT_INCLUDE_DIR).



Is this due to the build process? Can I find a workaround with an external 
FreeGlut?



Cheers,



Michel
Michel Audette, Ph.D.
Assistant Professor,
Department of Modeling, Simulation and Visualization Engineering,
Old Dominion University,
Norfolk, VA.

________________________________
From: Audette, Michel A. <maude...@odu.edu<mailto:maude...@odu.edu>>
Sent: Monday, October 3, 2016 9:34:24 AM
To: Kislinskiy, Stefan; Sascha Zelzer; 
mitk-users@lists.sourceforge.net<mailto:mitk-users@lists.sourceforge.net>
Subject: Re: [mitk-users] Superbuild on Windows MSVC 2012 leads to incomplete 
building of Boost libraries


Hi Stefan,



thanks for your kind reply and support. I will give it a try with MITK 
2015.05.2 and report back.



Cheers,



Michel


Michel Audette, Ph.D.
Assistant Professor,
Department of Modeling, Simulation and Visualization Engineering,
Old Dominion University,
Norfolk, VA.

________________________________
From: Kislinskiy, Stefan 
<s.kislins...@dkfz-heidelberg.de<mailto:s.kislins...@dkfz-heidelberg.de>>
Sent: Saturday, October 1, 2016 4:14:24 AM
To: Audette, Michel A.; Sascha Zelzer; 
mitk-users@lists.sourceforge.net<mailto:mitk-users@lists.sourceforge.net>
Subject: AW: [mitk-users] Superbuild on Windows MSVC 2012 leads to incomplete 
building of Boost libraries

Hi Michel,


MITK and SOFA have some common third-party dependencies. We try to build these 
only once and use them in both MITK and SOFA, but that doesn't work for all 
libraries. In case of Eigen, our version of SOFA (which is from the beginning 
of 2015 btw), uses its own, already packaged, header-only Eigen. So if I 
remember correctly, it isn't a trivial task to inject your own Eigen to SOFA 
through the MITK-superbuild. However, building SOFA with MITK is supposed to be 
as easy as any other feature of MITK, which is why it should work out of the 
box by simply switching on MITK_USE_SOFA. This is tested by our dart clients 
and works for Windows (MSVC), Linux, and OS X. As Sascha said, switching on 
MITK_USE_SOFA will automatically switch on common dependencies like the 
necessary Boost libraries. Hence, for the beginning, I highly recommend not to 
put extra work in fiddling around with external toolkits. In fact, the only 
manual steps necessary should be to set the right Qt path if it wasn't detected 
automatically, switch on MITK_USE_SOFA, run the superbuild, and after it's 
finished, go one level down to the actual MITK build and switch on the 
org.mitk.gui.qt.simulation plugin in CMake.


Please note, that MITK 2016.03 doesn't support MSVC 2012 anymore, so you should 
use MITK 2015.05.2 instead, if you don't do so already.


Regarding the CMake output: If you're using CMake GUI, just copy the error 
message from its output window. If you use command line CMake, you can either 
copy the error from the terminal or in general just look for the files 
CMakeOutput.log  and CMakeError.log in the build directory.


I'm happy to help you with MITK+SOFA. Please don't hesitate to ask.


Best,
Stefan

________________________________
Von: Audette, Michel A. <maude...@odu.edu<mailto:maude...@odu.edu>>
Gesendet: Freitag, 30. September 2016 22:15
An: Sascha Zelzer; 
mitk-users@lists.sourceforge.net<mailto:mitk-users@lists.sourceforge.net>
Betreff: Re: [mitk-users] Superbuild on Windows MSVC 2012 leads to incomplete 
building of Boost libraries


Hi Sascha,


for the time being, I am trying to get around that by using a prebuilt Boost 
externally, where it was building properly only 3 of the Boost libraries 
(thread, system, forget the third), however I'm still up against a problem 
compiling Eigen. I've seen that before trying to compile Sofa standalone on 
Windows. I will try with separate Eigen build as well and report back.


For my future use, when you say CMake output, where do I look for this file? Is 
it a log file of some kind?


Best wishes,


Michel


Michel Audette, Ph.D.
Assistant Professor,
Department of Modeling, Simulation and Visualization Engineering,
Old Dominion University,
Norfolk, VA.

________________________________
From: Sascha Zelzer <sascha.zel...@gmail.com<mailto:sascha.zel...@gmail.com>>
Sent: Friday, September 30, 2016 4:00:35 PM
To: Audette, Michel A.; 
mitk-users@lists.sourceforge.net<mailto:mitk-users@lists.sourceforge.net>
Subject: Re: [mitk-users] Superbuild on Windows MSVC 2012 leads to incomplete 
building of Boost libraries


Hi,


normally, the MITK superbuild sets the required boost libraries depending on 
the MITK_USE_* CMake variables being set to ON. E.g. if MITK_USE_SOFA is on, it 
adds the system, thread and chrono library. If you send us the full cmake 
output, it is easier to tell what is going on and which dependency requires 
data_time and atomic.


However, you can manually append required libraries in the 
MITK_USE_Boos_LIBRARIES cmake variable (e.g. using the CMake GUI). It would 
look like "date_time;atomic", but I am wondering why this is needed at all.


Cheers,

Sascha

On 09/30/2016 05:25 PM, Audette, Michel A. wrote:

Hello,


I would like to build MITK with SOFA, using MS Visual Studio 2012 (with service 
packs) and the superbuild does not seem to produce all of the needed Boost 
libraries.


The build process complains of the following:


19>    Unable to find the requested Boost libraries.
19>
19>    Boost version: 1.59.0
19>
19>    Boost include path: 
C:/MITK/MITK16.3.0-buildMSVS2012/ep/include/boost-1_59
19>
19>    Could not find the following Boost libraries:
19>
19>            boost_date_time
19>            boost_atomic

Is there an easy fix?


Best wishes,


Michel Audette, Ph.D.
Assistant Professor,
Department of Modeling, Simulation and Visualization Engineering,
Old Dominion University,
Norfolk, VA.




------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, SlashDot.org! 
https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fsdm.link%2Fslashdot&data=01%7C01%7Cmaudette%40odu.edu%7C356a40a078934b1543fa08d3e9d2fc92%7C48bf86e811a24b8a8cb368d8be2227f3%7C0&sdata=ylP%2FYLT7vULc8NTCtCF3J%2BAOePKAyID8XqeCzD%2F5Srk%3D&reserved=0<https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fsdm.link%2Fslashdot&data=01%7C01%7Cmaudette%40odu.edu%7Cae0d2d5222b447b6581c08d3e96c72f1%7C48bf86e811a24b8a8cb368d8be2227f3%7C0&sdata=gJHXITch8GRjmaa4PyzLBR4kV9rIN6s7CFID5P6BFcs%3D&reserved=0<https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fsdm.link%2Fslashdot&data=01%7C01%7Cmaudette%40odu.edu%7C356a40a078934b1543fa08d3e9d2fc92%7C48bf86e811a24b8a8cb368d8be2227f3%7C0&sdata=ylP%2FYLT7vULc8NTCtCF3J%2BAOePKAyID8XqeCzD%2F5Srk%3D&reserved=0%3chttps://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fsdm.link%2Fslashdot&data=01%7C01%7Cmaudette%40odu.edu%7Cae0d2d5222b447b6581c08d3e96c72f1%7C48bf86e811a24b8a8cb368d8be2227f3%7C0&sdata=gJHXITch8GRjmaa4PyzLBR4kV9rIN6s7CFID5P6BFcs%3D&reserved=0>>



_______________________________________________
mitk-users mailing list
mitk-users@lists.sourceforge.net<mailto:mitk-users@lists.sourceforge.net<mailto:mitk-users@lists.sourceforge.net%3cmailto:mitk-users@lists.sourceforge.net>>
https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Flists.sourceforge.net%2Flists%2Flistinfo%2Fmitk-users&data=01%7C01%7Cmaudette%40odu.edu%7C356a40a078934b1543fa08d3e9d2fc92%7C48bf86e811a24b8a8cb368d8be2227f3%7C0&sdata=iLRWIY3vGCUIXEK%2B%2BE%2BJi6WNi5PmrwzBTXWkd%2BcZx6s%3D&reserved=0<https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Flists.sourceforge.net%2Flists%2Flistinfo%2Fmitk-users&data=01%7C01%7Cmaudette%40odu.edu%7Cae0d2d5222b447b6581c08d3e96c72f1%7C48bf86e811a24b8a8cb368d8be2227f3%7C0&sdata=5GMDBFDHANhilKuDcL92Xqtuv0ecspnUAmG2HlDLCVI%3D&reserved=0<https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Flists.sourceforge.net%2Flists%2Flistinfo%2Fmitk-users&data=01%7C01%7Cmaudette%40odu.edu%7C356a40a078934b1543fa08d3e9d2fc92%7C48bf86e811a24b8a8cb368d8be2227f3%7C0&sdata=iLRWIY3vGCUIXEK%2B%2BE%2BJi6WNi5PmrwzBTXWkd%2BcZx6s%3D&reserved=0%3chttps://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Flists.sourceforge.net%2Flists%2Flistinfo%2Fmitk-users&data=01%7C01%7Cmaudette%40odu.edu%7Cae0d2d5222b447b6581c08d3e96c72f1%7C48bf86e811a24b8a8cb368d8be2227f3%7C0&sdata=5GMDBFDHANhilKuDcL92Xqtuv0ecspnUAmG2HlDLCVI%3D&reserved=0>>
------------------------------------------------------------------------------
The Command Line: Reinvented for Modern Developers
Did the resurgence of CLI tooling catch you by surprise?
Reconnect with the command line and become more productive. 
Learn the new .NET and ASP.NET CLI. Get your free copy!
http://sdm.link/telerik
_______________________________________________
mitk-users mailing list
mitk-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mitk-users

Reply via email to