X-Git-Url: https://git.rrq.au/?a=blobdiff_plain;f=CMakeLists.txt;h=1cb4b4f7a58b89eb983462d4fad63473f28cf49e;hb=250b50f64da6281da945fde94b722e08bfa060c9;hp=9f2d870c2ebc54719578cdaf18addb5deaf36d29;hpb=21ea68ce16d0d7e0b7ea5bc0c688e3e0a2c9a357;p=rrq%2Ffuse_xattrs.git diff --git a/CMakeLists.txt b/CMakeLists.txt index 9f2d870..1cb4b4f 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -2,7 +2,7 @@ cmake_minimum_required(VERSION 2.8 FATAL_ERROR) project(fuse_xattrs C) set(FUSE_XATTRS_VERSION_MAJOR 0) -set(FUSE_XATTRS_VERSION_MINOR 2) +set(FUSE_XATTRS_VERSION_MINOR 4) set(BINARY_SIDECAR_EXT \".xattr\") @@ -34,11 +34,11 @@ endif() include (CheckCSourceCompiles) check_c_source_compiles (" #include - #include + #include int main() { return 1; } - " HAVE_ATTR_XATTR_H) -if(NOT HAVE_ATTR_XATTR_H) - message(FATAL_ERROR "attr/xattr.h not found") + " HAVE_SYS_XATTR_H) +if(NOT HAVE_SYS_XATTR_H) + message(FATAL_ERROR "sys/xattr.h not found") endif() # set required definitions @@ -46,6 +46,8 @@ add_definitions (-D_FILE_OFFSET_BITS=64) set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} "${CMAKE_SOURCE_DIR}/CMakeModules/") +set(CMAKE_C_FLAGS "-O3") + option(ENABLE_CODECOVERAGE "Enable code coverage testing support" ) if(ENABLE_CODECOVERAGE) include (CodeCoverage) @@ -66,15 +68,23 @@ set(SOURCE_FILES add_executable(fuse_xattrs ${SOURCE_FILES}) -target_link_libraries ( - fuse_xattrs - fuse -) +if(APPLE) + target_link_libraries ( + fuse_xattrs + osxfuse + ) +else() + target_link_libraries ( + fuse_xattrs + fuse + ) +endif() + install (TARGETS fuse_xattrs DESTINATION bin) install ( FILES ${CMAKE_CURRENT_BINARY_DIR}/fuse_xattrs.1 - DESTINATION man/man1 + DESTINATION share/man/man1 COMPONENT doc )