summaryrefslogtreecommitdiffstats
path: root/CMakeLists.txt
diff options
context:
space:
mode:
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r--CMakeLists.txt21
1 files changed, 20 insertions, 1 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 80d66bc28..c8047f82f 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -599,7 +599,26 @@ endif( HAVE_LIBMAGIC )
if( WITH_UTEMPTER )
check_include_file( utempter.h HAVE_UTEMPTER_H )
check_library_exists( utempter addToUtmp "" HAVE_ADDTOUTEMP )
- if( HAVE_UTEMPTER_H AND HAVE_ADDTOUTEMP )
+ if( NOT DEFINED UTEMPTER_HELPER )
+ message( STATUS "Looking for utempter helper" )
+ find_program( UTEMPTER_HELPER utempter
+ PATHS
+ /usr/lib/${CMAKE_LIBRARY_ARCHITECTURE}/utempter
+ /usr/lib/utempter
+ /usr/libexec/utempter
+ /usr/libexec
+ /usr/local/lib/${CMAKE_LIBRARY_ARCHITECTURE}/utempter
+ /usr/local/lib/utempter
+ /usr/local/libexec/utempter
+ /usr/local/libexec
+ )
+ if( UTEMPTER_HELPER )
+ message( STATUS "Looking for utempter helper - found" )
+ else( )
+ message( STATUS "Looking for utempter helper - not found" )
+ endif( )
+ endif( )
+ if( HAVE_UTEMPTER_H AND HAVE_ADDTOUTEMP AND UTEMPTER_HELPER )
set( HAVE_UTEMPTER 1 )
set( UTEMPTER_LIBRARY utempter )
else( )