Changeset 141 in pacpusframework for branches/2.0-beta1/cmake/PacpusDependencies.cmake


Ignore:
Timestamp:
Jul 30, 2013, 5:48:06 PM (11 years ago)
Author:
Marek Kurdej
Message:

Major update: using Boost.Log if PACPUS_USE_LOG is true.
Added: overloaded operator<< for QString (explicit instantiation).

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/2.0-beta1/cmake/PacpusDependencies.cmake

    r130 r141  
    9191# Do not use compiled modules, include-only headers.
    9292# ========================================
    93 #find_package(Boost 1.49.0 REQUIRED)
    94 #list(APPEND PACPUS_DEPENDENCIES_INC ${Boost_INCLUDE_DIRS})
    95 
    96 # ========================================
    97 # log4cxx
    98 # ========================================
    9993if(PACPUS_USE_LOG)
    100     if(WIN32 AND MSVC AND IS_BUILDING_PACPUS)
    101         set(LOG4CXX_ROOT ${PACPUS_3RD_PARTY_DIR}/apache-log4cxx)
    102     endif()
    103 
    104     find_package(log4cxx REQUIRED)
    105 
    10694    list(APPEND PACPUS_DEFINITIONS " -DPACPUS_USE_LOG ")
    107     list(APPEND PACPUS_DEPENDENCIES_INC ${LOG4CXX_INCLUDE_DIRS})
    108     list(APPEND PACPUS_DEPENDENCIES_LIB ${LOG4CXX_LIBRARIES})
    109 
    110     # If needed, install the dll of log4cxx
    111     if(WIN32 AND MSVC AND IS_BUILDING_PACPUS)
    112         pacpus_get_msvc(MSVC_VERSION)
    113         pacpus_purge_backslash(LOG4CXX_ROOT)
    114 
    115         install(
    116             FILES
    117                 ${LOG4CXX_ROOT}/bin/${MSVC_VERSION}/log4cxx.dll
    118                 ${LOG4CXX_ROOT}/bin/${MSVC_VERSION}/log4cxx_d.dll
    119             DESTINATION
    120                 ${PACPUS_INSTALL_DIR}/bin
    121         )
    122     endif()
     95    list(APPEND PACPUS_DEFINITIONS " -DBOOST_ALL_DYN_LINK ")
     96   
     97    find_package(Boost 1.54.0 REQUIRED
     98        COMPONENTS
     99            log
     100    )
     101    include_directories(${Boost_INCLUDE_DIRS})
     102    link_directories(${Boost_LIBRARY_DIRS})
     103   
     104    list(APPEND PACPUS_DEPENDENCIES_INC ${Boost_INCLUDE_DIRS})
     105    list(APPEND PACPUS_DEPENDENCIES_LIB ${Boost_LIBRARIES})
    123106endif()
    124107
Note: See TracChangeset for help on using the changeset viewer.