Don't try to remove from an empty list.
This commit is contained in:
parent
9ae1b1d157
commit
aeea7b6d25
@ -253,6 +253,7 @@ ENDIF()
|
|||||||
# Extract dependencies using CMake's internal ${target}_LIB_DEPENDS variable
|
# Extract dependencies using CMake's internal ${target}_LIB_DEPENDS variable
|
||||||
# returned string in ${var} is can be passed to linker's command line
|
# returned string in ${var} is can be passed to linker's command line
|
||||||
MACRO(EXTRACT_LINK_LIBRARIES target var)
|
MACRO(EXTRACT_LINK_LIBRARIES target var)
|
||||||
|
IF(${target}_LIB_DEPENDS)
|
||||||
LIST(REMOVE_ITEM ${target}_LIB_DEPENDS "")
|
LIST(REMOVE_ITEM ${target}_LIB_DEPENDS "")
|
||||||
LIST(REMOVE_DUPLICATES ${target}_LIB_DEPENDS)
|
LIST(REMOVE_DUPLICATES ${target}_LIB_DEPENDS)
|
||||||
FOREACH(lib ${${target}_LIB_DEPENDS})
|
FOREACH(lib ${${target}_LIB_DEPENDS})
|
||||||
@ -271,6 +272,7 @@ MACRO(EXTRACT_LINK_LIBRARIES target var)
|
|||||||
ENDIF()
|
ENDIF()
|
||||||
ENDIF()
|
ENDIF()
|
||||||
ENDFOREACH()
|
ENDFOREACH()
|
||||||
|
ENDIF()
|
||||||
IF(MSVC)
|
IF(MSVC)
|
||||||
STRING(REPLACE "-l" "" ${var} "${${var}}")
|
STRING(REPLACE "-l" "" ${var} "${${var}}")
|
||||||
ENDIF()
|
ENDIF()
|
||||||
|
Loading…
x
Reference in New Issue
Block a user