diff options
author | Sage Weil <sage.weil@dreamhost.com> | 2012-04-08 20:58:59 -0700 |
---|---|---|
committer | Sage Weil <sage.weil@dreamhost.com> | 2012-04-08 20:58:59 -0700 |
commit | dd8fd1688a358758d5c9c605ddb1e87aedf2ade4 (patch) | |
tree | f72c19e23bedd46af13518669b655691694b39e1 | |
parent | 2dbdadbe48c93ba492a107947323330301b746af (diff) | |
download | ceph-dd8fd1688a358758d5c9c605ddb1e87aedf2ade4.tar.gz |
configure: HAVE_FALLOCATE -> CEPH_HAVE_FALLOCATE
/usr/include/linux/fs.h defines this on CentOS 5, even though it does not
in fact compile. This stupid workaround avoids the problem.
Reported-by: Nick Couchman <Nick.Couchman@seakr.com>
Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
-rw-r--r-- | configure.ac | 2 | ||||
-rw-r--r-- | src/os/FileStore.cc | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/configure.ac b/configure.ac index 6376c04f473..595c4fde259 100644 --- a/configure.ac +++ b/configure.ac @@ -343,7 +343,7 @@ AC_CHECK_FUNC([sync_file_range], # fallocate AC_CHECK_FUNC([fallocate], - [AC_DEFINE([HAVE_FALLOCATE], [], [fallocate(2) is supported])], + [AC_DEFINE([CEPH_HAVE_FALLOCATE], [], [fallocate(2) is supported])], []) diff --git a/src/os/FileStore.cc b/src/os/FileStore.cc index 8f1c74708b7..83832cd3dbf 100644 --- a/src/os/FileStore.cc +++ b/src/os/FileStore.cc @@ -3040,7 +3040,7 @@ int FileStore::_zero(coll_t cid, const hobject_t& oid, uint64_t offset, size_t l dout(15) << "zero " << cid << "/" << oid << " " << offset << "~" << len << dendl; int ret = 0; -#ifdef HAVE_FALLOCATE +#ifdef CEPH_HAVE_FALLOCATE # if !defined(DARWIN) && !defined(__FreeBSD__) // first try to punch a hole. int fd = lfn_open(cid, oid, O_RDONLY); |