add minimum required boost version to CMakeLists.txt
Please change the line
find_package( Boost REQUIRED system filesystem program_options )
in CMakeLists.txt
to something like
find_package( Boost 1.57.0 REQUIRED system filesystem program_options )
as this fixes a strange problem when a local boost version (BOOST_ROOT env var set) needs to take precedence over a system-installation of boost. Without this fix the wrong shared libraries are used for linking the executable(s). I can provide more details if you want.
Comments (7)
-
reporter -
Oh, sorry. This got lost...
Is 1.57 required to solve the problem? I am a bit reluctant since this is stricter than what Dolfin requires (1.47).
This seems like a workaround for another problem. Is it not possible to solve that? Does Dolfin link correctly?
-
reporter I think 1.47 should work as well. I'll investigate whether its a workaround for another problem.
-
Try to add the following to CMakeLists.txt in mshr and see if that fixes the problem:
# Check for Boost set(BOOST_ROOT $ENV{BOOST_DIR} $ENV{BOOST_HOME}) if (BOOST_ROOT) set(Boost_NO_SYSTEM_PATHS on) endif() # Prevent FindBoost.cmake from looking for system Boost{foo}.cmake files set(Boost_NO_BOOST_CMAKE true)
We will push this to mshr if this fixes the problem for you.
-
Note that this must be added before calling
find_package(Boost...
. -
reporter Sry that it took me so long to come back to this issue. I was busy with other stuff.
The proposed fix by @johannes_ring works.
-
- changed status to resolved
- Include workaround to prevent cmake from picking the wrong boost when a hint is given to find_package(Boost). Fixes issue
#27. - Make VTK an optional dependency. If MSHR_ENABLE_VTK is given it will take precedence, otherwise mshr will check if Dolfin is configured with VTK support and do the same. Fixes issue
#29
→ <<cset e651a0daeb91>>
- Log in to comment
@benjamik any updates on this issue?