← Back to team overview

hugin-devs team mailing list archive

[Bug 1165857] Re: SET(Boost_USE_STATIC_RUNTIME ON) should be set in CMakeLists.txt File

 

** Changed in: hugin
       Status: Fix Committed => Fix Released

-- 
You received this bug notification because you are a member of Hugin
Developers, which is subscribed to Hugin.
https://bugs.launchpad.net/bugs/1165857

Title:
  SET(Boost_USE_STATIC_RUNTIME ON) should be set in CMakeLists.txt File

Status in Hugin - Panorama Tools GUI:
  Fix Released

Bug description:
  At the moment the behaviour of the boost CMAKE part for hugin is in an undefined state hugin.
  As described in the comments of the FindBoost.cmake Module the Variable Boost_USE_STATIC_RUNTIME should be set to prevent this.  SET(Boost_USE_STATIC_RUNTIME OFF) and SET(Boost_USE_STATIC_RUNTIME ON) should be added to CMakeLists.txt after line 256 and 261 of rev 2577057a1bb0 (see below and attached patch).
  In my case the missing line prevented cmake to find and accept the debug versions of the boost libraries. 
  If you grant me commit right I can also commit the fix myself.
  Cheers
  Philipp

  IF(WIN32)
    IF(${HUGIN_SHARED})
      SET(Boost_USE_STATIC_LIBS OFF
      SET(Boost_USE_STATIC_RUNTIME OFF)
      # ADD_DEFINITIONS(-DBOOST_ALL_DYN_LINK)
      # ADD_DEFINITIONS(-D_DLL)
      ADD_DEFINITIONS(-DBOOST_ALL_NO_LIB)
    ELSE(${HUGIN_SHARED})
      SET(Boost_USE_STATIC_LIBS ON)
      SET(Boost_USE_STATIC_RUNTIME ON)
    ENDIF(${HUGIN_SHARED})
    # If BOOST_ROOT was defined in the environment, use it. 
    if (NOT BOOST_ROOT AND NOT $ENV{BOOST_ROOT} STREQUAL "") 
      set(BOOST_ROOT $ENV{BOOST_ROOT}) 
    else(NOT BOOST_ROOT AND NOT $ENV{BOOST_ROOT} STREQUAL "") 
      set(BOOST_ROOT ${SOURCE_BASE_DIR}/boost${Boost_root_suffix}) 
     endif(NOT BOOST_ROOT AND NOT $ENV{BOOST_ROOT} STREQUAL "") 
  ENDIF(WIN32)

To manage notifications about this bug go to:
https://bugs.launchpad.net/hugin/+bug/1165857/+subscriptions


References