From 000075c0719883663f3250cbd74685847ace7ae4 Mon Sep 17 00:00:00 2001 From: Alex Kent Hajnal Date: Wed, 15 May 2024 18:43:42 -0400 Subject: Code clean-up, proper CMake integration Signed-off-by: Alex Kent Hajnal --- CMakeLists.txt | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) (limited to 'CMakeLists.txt') diff --git a/CMakeLists.txt b/CMakeLists.txt index 84158ef6d..3618f20b7 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -284,13 +284,17 @@ if( NOT HAVE_SYS_UCRED_H ) endif( ) endif( ) check_include_file( "sys/xattr.h" HAVE_SYS_XATTR_H ) + check_include_file( "attr/libattr.h" HAVE_ATTR_LIBATTR_H) if ( HAVE_ATTR_LIBATTR_H ) - check_library_exists( attr attr_copy_file "" HAVE_ATTR__ATTR_COPY_FILE ) -endif( ) -if( HAVE_ATTR__ATTR_COPY_FILE ) - set( DO_USER_XATTR_COPYING "1" ) + message( STATUS "Have attr/libattr.h" ) + check_library_exists( attr attr_copy_file "" HAVE_ATTR__ATTR_COPY_FILE ) + if( HAVE_ATTR__ATTR_COPY_FILE ) + message( STATUS "Have attr_copy_file in libattr" ) + set( USER_XATTR_LIBRARIES attr ) + set( DO_USER_XATTR_COPYING 1 ) message( STATUS "User extended attribute copy support enabled" ) + endif( ) endif( ) check_include_file( "termios.h" HAVE_TERMIOS_H ) -- cgit v1.2.1