summaryrefslogtreecommitdiffstats
path: root/Tests/RunCMake/target_link_libraries/SharedDepNotTarget.cmake
blob: bab537edbc0b9c241c4d946c5f89ad7f0dff01ba (plain)
1
2
3
4
5
6
7
8
9
10
enable_language(C)
set(CMAKE_LINK_DEPENDENT_LIBRARY_DIRS 1)
set(CMAKE_SHARED_LIBRARY_SUFFIX ".so")
add_library(imported SHARED IMPORTED)
set_target_properties(imported PROPERTIES
  IMPORTED_LOCATION "imported"
  IMPORTED_LINK_DEPENDENT_LIBRARIES "/path/to/libSharedDep.so"
  )
add_executable(empty empty.c)
target_link_libraries(empty imported)