Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
May 7, 2011, 12:06:56 AM (13 years ago)
Author:
rgrieder
Message:

MSVC specific:
Sorted out Visual Leak Detector handling (it's now treated like a real library, not as a hack).
Also, the vld.h include is gone and with it windows.h.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • code/trunk/src/CMakeLists.txt

    r8365 r8412  
    5454  ADD_COMPILER_FLAGS("-DNTDDI_VERSION=0x05010000")
    5555ENDIF(WIN32)
     56
     57# Visual Leak Dectector configuration
     58IF(MSVC AND VLD_FOUND)
     59  OPTION(VISUAL_LEAK_DETECTOR_ENABLE "Memory leak detector" OFF)
     60  IF(VISUAL_LEAK_DETECTOR_ENABLE)
     61    # Force library linking by forcing the inclusion of a symbol
     62    ADD_LINKER_FLAGS("-INCLUDE:__imp_?vld@@3VVisualLeakDetector@@A" Debug)
     63    IF(MSVC90)
     64      # VS 2008 incremental linker crashes with /INCLUDE most of the time
     65      REMOVE_LINKER_FLAGS("-INCREMENTAL:YES" Debug)
     66      ADD_LINKER_FLAGS   ("-INCREMENTAL:NO"  Debug)
     67    ENDIF()
     68  ENDIF()
     69ENDIF()
    5670
    5771######### Library Behaviour (external) ##########
     
    110124IF (DBGHELP_FOUND)
    111125  INCLUDE_DIRECTORIES(${DBGHELP_INCLUDE_DIR})
     126ENDIF()
     127
     128IF(VISUAL_LEAK_DETECTOR_ENABLE)
     129  INCLUDE_DIRECTORIES(${VLD_INCLUDE_DIR})
    112130ENDIF()
    113131
Note: See TracChangeset for help on using the changeset viewer.