From fa1b5d86bf5ba20047774014b422e7c30ee13a9c Mon Sep 17 00:00:00 2001 From: Julian Andres Klode Date: Tue, 9 Aug 2016 17:39:25 +0200 Subject: [PATCH] Add statvfs.h.in to CMake directory Gbp-Dch: ignore --- CMake/statvfs.h.in | 13 +++++++++++++ CMakeLists.txt | 2 +- 2 files changed, 14 insertions(+), 1 deletion(-) create mode 100644 CMake/statvfs.h.in diff --git a/CMake/statvfs.h.in b/CMake/statvfs.h.in new file mode 100644 index 000000000..d0ec238ad --- /dev/null +++ b/CMake/statvfs.h.in @@ -0,0 +1,13 @@ +/* Compatibility for systems with out Single Unix Spec statvfs */ +#include + +#ifdef HAVE_VFS_H +#include +#endif + +#ifdef HAVE_MOUNT_H +#include +#include +#endif + +#define statvfs statfs diff --git a/CMakeLists.txt b/CMakeLists.txt index 1f9ca02b8..80b9c380c 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -92,7 +92,7 @@ if (NOT HAVE_STATVFS) if (NOT HAVE_VFS_H AND NOT HAVE_MOUNT_H) message(FATAL_ERROR "Can find neither statvfs() nor statfs()") endif() - configure_file(buildlib/statvfs.h.in ${PROJECT_BINARY_DIR}/include/statvfs.h @ONLY) + configure_file(CMake/statvfs.h.in ${PROJECT_BINARY_DIR}/include/statvfs.h @ONLY) endif() CHECK_STRUCT_HAS_MEMBER("struct statfs" f_type sys/vfs.h HAVE_STRUCT_STATFS_F_TYPE) -- 2.45.2