Improve test if library is a CMake target
Newer CMake complains when you try to get the property of something
that isn't a target so use the specific if operator instead.
diff --git a/cmake/Modules/CMakeMacroLibtoolFile.cmake b/cmake/Modules/CMakeMacroLibtoolFile.cmake
index 1a3ab7c..9d04ef5 100644
--- a/cmake/Modules/CMakeMacroLibtoolFile.cmake
+++ b/cmake/Modules/CMakeMacroLibtoolFile.cmake
@@ -43,8 +43,7 @@
else()
# No shared library extension matched. Check whether target is a CMake
# target.
- get_target_property(_ltp ${library} TYPE)
- if(_ltp OR ${library} STREQUAL "general")
+ if(TARGET ${library})
# Target is a CMake target, so ignore (CMake targets are static
# libs in TigerVNC.)
elseif(${library} STREQUAL "-Wl,-Bstatic")