|
1234567891011121314 |
- FUNCTION(OV_DELAY_LOAD TARGET DLL)
- IF(WIN32)
- UNSET(FN_LINK_FLAGS)
- GET_TARGET_PROPERTY(FN_LINK_FLAGS ${TARGET} LINK_FLAGS)
- IF(FN_LINK_FLAGS)
- SET_TARGET_PROPERTIES(${TARGET} PROPERTIES LINK_FLAGS "${FN_LINK_FLAGS} /DELAYLOAD:${DLL}")
- ELSE(FN_LINK_FLAGS)
- SET_TARGET_PROPERTIES(${TARGET} PROPERTIES LINK_FLAGS "/DELAYLOAD:${DLL}")
- ENDIF(FN_LINK_FLAGS)
- TARGET_LINK_LIBRARIES(${TARGET} Delayimp)
- ELSE(WIN32)
- MESSAGE(WARNING "Ignored OV_DELAY_LOAD call on non WIN32 platform")
- ENDIF(WIN32)
- ENDFUNCTION(OV_DELAY_LOAD)
|