Skip to content

Commit

Permalink
Get correct config from target imported configs
Browse files Browse the repository at this point in the history
Signed-off-by: Ivan Santiago Paunovic <ivanpauno@ekumenlabs.com>
  • Loading branch information
ivanpauno committed Jul 15, 2020
1 parent 9500695 commit d2aeb63
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -35,12 +35,12 @@ if(NOT _exported_dependencies STREQUAL "")
endif()

get_target_property(_imported_configurations ${_target} IMPORTED_CONFIGURATIONS)
if(_imported_configurations)
get_target_property(_imported_implib ${_target} IMPORTED_IMPLIB_${_imported_configurations})
if("$<CONFIG>" IN_LIST _imported_configurations)
get_target_property(_imported_implib ${_target} IMPORTED_IMPLIB_$<CONFIG>)
if(_imported_implib)
list(APPEND _libraries "${_imported_implib}")
else()
get_target_property(_imported_location ${_target} IMPORTED_LOCATION_${_imported_configurations})
get_target_property(_imported_location ${_target} IMPORTED_LOCATION_$<CONFIG>)
if(_imported_location)
list(APPEND _libraries "${_imported_location}")
endif()
Expand Down

0 comments on commit d2aeb63

Please sign in to comment.