<commit_before>message(STATUS "Setup Boost ...")

set(proj BOOST)

set(DEFAULT_USE_SYSTEM_BOOST  ON)

option(USE_SYSTEM_BOOST "  Use a system build of Boost." ${DEFAULT_USE_SYSTEM_BOOST})
mark_as_advanced(USE_SYSTEM_BOOST)

if(USE_SYSTEM_BOOST)
  message(STATUS "  Using Boost system version")
else()
  
  set(BOOST_SB_BUILD_DIR ${CMAKE_BINARY_DIR}/${proj}/build)
  set(BOOST_SB_SRC ${CMAKE_BINARY_DIR}/${proj}/src/${proj})
  
  if(UNIX)
    ExternalProject_Add(${proj}
        PREFIX ${proj}
        URL "http://sourceforge.net/projects/boost/files/boost/1.57.0/boost_1_57_0.tar.gz/download"
        URL_MD5 25f9a8ac28beeb5ab84aa98510305299
        BINARY_DIR ${BOOST_SB_BUILD_DIR}
        INSTALL_DIR ${CMAKE_INSTALL_PREFIX}
        CMAKE_CACHE_ARGS
        -DCMAKE_INSTALL_PREFIX:STRING=${CMAKE_INSTALL_PREFIX}
        -DCMAKE_BUILD_TYPE:STRING=Release
        -DBUILD_SHARED_LIBS:BOOL=ON
        PATCH_COMMAND ${CMAKE_COMMAND} -E copy 
        ${CMAKE_SOURCE_DIR}/patches/${proj}/CMakeLists.txt 
        ${BOOST_SB_SRC}
    )
    
    message(STATUS "  Using Boost SuperBuild version")
    
  else(MSVC)
    #TODO: find hash for archives properly
    set(BOOST_HEADERS_URL_HASH 1605dc6085cb2dc778ef5ab6c0e59083)
    set(BOOST_GRAPH_URL_HASH c246516ca84a3c79ae8a0b22fceb0344)
    set(BOOST_REGEX_URL_HASH a3bfc2dc9a3ebe3c050518ecb29d6f8b)
    set(BOOST_UTF_URL_HASH 75971963a74c76d32e01974a8e48be11)
    <commit_msg>ENH: decrease boost version to 1.54 to avoid incompat with qt<commit_after>message(STATUS "Setup Boost ...")

set(proj BOOST)

set(DEFAULT_USE_SYSTEM_BOOST  ON)

option(USE_SYSTEM_BOOST "  Use a system build of Boost." ${DEFAULT_USE_SYSTEM_BOOST})
mark_as_advanced(USE_SYSTEM_BOOST)

if(USE_SYSTEM_BOOST)
  message(STATUS "  Using Boost system version")
else()
  
  set(BOOST_SB_BUILD_DIR ${CMAKE_BINARY_DIR}/${proj}/build)
  set(BOOST_SB_SRC ${CMAKE_BINARY_DIR}/${proj}/src/${proj})
  
  if(UNIX)
    ExternalProject_Add(${proj}
        PREFIX ${proj}
        URL "http://sourceforge.net/projects/boost/files/boost/1.54.0/boost_1_54_0.tar.gz/download"
        URL_MD5 efbfbff5a85a9330951f243d0a46e4b9
        BINARY_DIR ${BOOST_SB_BUILD_DIR}
        INSTALL_DIR ${CMAKE_INSTALL_PREFIX}
        CMAKE_CACHE_ARGS
        -DCMAKE_INSTALL_PREFIX:STRING=${CMAKE_INSTALL_PREFIX}
        -DCMAKE_BUILD_TYPE:STRING=Release
        -DBUILD_SHARED_LIBS:BOOL=ON
        PATCH_COMMAND ${CMAKE_COMMAND} -E copy 
        ${CMAKE_SOURCE_DIR}/patches/${proj}/CMakeLists.txt 
        ${BOOST_SB_SRC}
    )
    
    message(STATUS "  Using Boost SuperBuild version")
    
  else(MSVC)
    #TODO: find hash for archives properly
    set(BOOST_HEADERS_URL_HASH 1605dc6085cb2dc778ef5ab6c0e59083)
    set(BOOST_GRAPH_URL_HASH c246516ca84a3c79ae8a0b22fceb0344)
    set(BOOST_REGEX_URL_HASH a3bfc2dc9a3ebe3c050518ecb29d6f8b)
    set(BOOST_UTF_URL_HASH 75971963a74c76d32e01974a8e48be11)
    
{'fraction_non_alphanumeric': 0.09355509355509356, 'fraction_numerical': 0.07449757449757449, 'mean_word_length': 4.173835125448028, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 2, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1521311', 'n_tokens_mistral': 1311, 'n_tokens_neox': 1120, 'n_words': 148}