/usr/share/kde4/apps/cmake/modules/UnixAuth.cmake is in kde-workspace-dev 4:4.8.4-6.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 | macro_optional_find_package(PAM)
include(CheckFunctionExists)
include(CheckLibraryExists)
include(CheckIncludeFiles)
set(UNIXAUTH_LIBRARIES)
set(UNIXAUTH_INCLUDE_DIRS)
set(SHADOW_LIBRARIES)
check_function_exists(getspnam found_getspnam)
if (found_getspnam)
set(HAVE_GETSPNAM 1)
else (found_getspnam)
macro_push_required_vars()
set(CMAKE_REQUIRED_LIBRARIES -lshadow)
check_function_exists(getspnam found_getspnam_shadow)
if (found_getspnam_shadow)
set(HAVE_GETSPNAM 1)
set(SHADOW_LIBRARIES shadow)
check_function_exists(pw_encrypt HAVE_PW_ENCRYPT) # ancient Linux shadow
else (found_getspnam_shadow)
set(CMAKE_REQUIRED_LIBRARIES -lgen) # UnixWare
check_function_exists(getspnam found_getspnam_gen)
if (found_getspnam_gen)
set(HAVE_GETSPNAM 1)
set(SHADOW_LIBRARIES gen)
endif (found_getspnam_gen)
endif (found_getspnam_shadow)
macro_pop_required_vars()
endif (found_getspnam)
set(CRYPT_LIBRARIES)
check_library_exists(crypt crypt "" HAVE_CRYPT)
if (HAVE_CRYPT)
set(CRYPT_LIBRARIES crypt)
check_include_files(crypt.h HAVE_CRYPT_H)
endif (HAVE_CRYPT)
if (PAM_FOUND)
set(HAVE_PAM 1)
set(UNIXAUTH_LIBRARIES ${PAM_LIBRARIES})
set(UNIXAUTH_INCLUDE_DIRS ${PAM_INCLUDE_DIR})
else (PAM_FOUND)
if (HAVE_GETSPNAM)
set(UNIXAUTH_LIBRARIES ${SHADOW_LIBRARIES})
endif (HAVE_GETSPNAM)
if (NOT HAVE_PW_ENCRYPT)
set(UNIXAUTH_LIBRARIES ${UNIXAUTH_LIBRARIES} ${CRYPT_LIBRARIES})
endif (NOT HAVE_PW_ENCRYPT)
endif (PAM_FOUND)
|