Skip to content

Commit

Permalink
cmake: use file(WRITE) instead of file(TOUCH)
Browse files Browse the repository at this point in the history
Older CMake doesn't support file(TOUCH) yet, so we use file(WRITE)
instead.
  • Loading branch information
arogge committed Aug 20, 2020
1 parent 297c8e7 commit 53ae584
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion cmake/BareosCheckAcl.cmake
Expand Up @@ -22,7 +22,7 @@ find_program(GETFACL_PROG getfacl)

set(SETFACL_WORKS NO)
if(SETFACL_PROG AND GETFACL_PROG)
file(TOUCH "${CMAKE_CURRENT_BINARY_DIR}/acl-test-file.txt")
file(WRITE "${CMAKE_CURRENT_BINARY_DIR}/acl-test-file.txt" "Just a testfile")
exec_program(${SETFACL_PROG}
${CMAKE_CURRENT_BINARY_DIR}
ARGS "-m user:0:rw- acl-test-file.txt"
Expand Down
2 changes: 1 addition & 1 deletion cmake/BareosCheckXattr.cmake
Expand Up @@ -22,7 +22,7 @@ find_program(GETFATTR_PROG getfattr)

set(SETFATTR_WORKS NO)
if(SETFATTR_PROG AND GETFATTR_PROG)
file(TOUCH "${CMAKE_CURRENT_BINARY_DIR}/xattr-test-file.txt")
file(WRITE "${CMAKE_CURRENT_BINARY_DIR}/xattr-test-file.txt" "Just a testfile")
exec_program(${SETFATTR_PROG}
${CMAKE_CURRENT_BINARY_DIR}
ARGS "--name=user.cmake-check --value=xattr-value xattr-test-file.txt"
Expand Down

0 comments on commit 53ae584

Please sign in to comment.