cmake: Improve PAM_WRAPPER_LOACATION
authorAndreas Schneider <asn@samba.org>
Wed, 22 Nov 2017 14:27:44 +0000 (15:27 +0100)
committerAndreas Schneider <asn@samba.org>
Thu, 23 Nov 2017 10:50:45 +0000 (11:50 +0100)
Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
src/CMakeLists.txt

index 713625bf03ce79832cd8327c4ef7eb1fd9f5be21..76a87d679b88e589da55280a2a47f819785e5ec5 100644 (file)
@@ -74,8 +74,4 @@ if (PYTHONLIBS_FOUND)
 endif()
 
 # This needs to be at the end
-if (POLICY CMP0026)
-    cmake_policy(SET CMP0026 OLD)
-endif()
-get_target_property(PAM_WRAPPER_LOCATION pam_wrapper LOCATION)
-set(PAM_WRAPPER_LOCATION ${PAM_WRAPPER_LOCATION} PARENT_SCOPE)
+set(PAM_WRAPPER_LOCATION "${CMAKE_CURRENT_BINARY_DIR}/${CMAKE_SHARED_LIBRARY_PREFIX}pam_wrapper${CMAKE_SHARED_LIBRARY_SUFFIX}" PARENT_SCOPE)