diff options
author | Amar Tumballi <amar@gluster.com> | 2009-12-01 20:28:28 +0000 |
---|---|---|
committer | Anand V. Avati <avati@dev.gluster.com> | 2009-12-01 19:48:41 -0800 |
commit | 67d6a0a6195a72bce251891fccbd38929d5586dc (patch) | |
tree | 7ddf6cdf7803d7e1030187daac44db824bda7d42 /xlators/performance/io-cache/src | |
parent | 0c4b5814e7402658493f1e16ef7fa9a8fa8b4be5 (diff) |
fixes to compile on MacOSX (no fuse client)
These changes are required to make GlusterFS compile on MacOSX (10.5).
Currently glusterfs server component alone will work over Mac, and it has
to be built with following options to ./configure.
"bash$ ./configure --disable-fuse-client --disable-fusermount "
Signed-off-by: Amar Tumballi <amar@gluster.com>
Signed-off-by: Anand V. Avati <avati@dev.gluster.com>
BUG: 361 (GlusterFS 3.0 should work on Mac OS/X)
URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=361
Diffstat (limited to 'xlators/performance/io-cache/src')
-rw-r--r-- | xlators/performance/io-cache/src/io-cache.c | 13 | ||||
-rw-r--r-- | xlators/performance/io-cache/src/ioc-inode.c | 12 |
2 files changed, 13 insertions, 12 deletions
diff --git a/xlators/performance/io-cache/src/io-cache.c b/xlators/performance/io-cache/src/io-cache.c index 13811b628..60dda3e35 100644 --- a/xlators/performance/io-cache/src/io-cache.c +++ b/xlators/performance/io-cache/src/io-cache.c @@ -30,7 +30,7 @@ #include <assert.h> #include <sys/time.h> -extern int ioc_log2_page_size; +int ioc_log2_page_size; uint32_t ioc_get_priority (ioc_table_t *table, const char *path); @@ -38,6 +38,17 @@ ioc_get_priority (ioc_table_t *table, const char *path); uint32_t ioc_get_priority (ioc_table_t *table, const char *path); + +inline uint32_t +ioc_hashfn (void *data, int len) +{ + off_t offset; + + offset = *(off_t *) data; + + return (offset >> ioc_log2_page_size); +} + inline ioc_inode_t * ioc_inode_reupdate (ioc_inode_t *ioc_inode) { diff --git a/xlators/performance/io-cache/src/ioc-inode.c b/xlators/performance/io-cache/src/ioc-inode.c index 9ac5469f5..74c657fe7 100644 --- a/xlators/performance/io-cache/src/ioc-inode.c +++ b/xlators/performance/io-cache/src/ioc-inode.c @@ -24,17 +24,7 @@ #include "io-cache.h" -int ioc_log2_page_size; - -inline uint32_t -ioc_hashfn (void *data, int len) -{ - off_t offset; - - offset = *(off_t *) data; - - return (offset >> ioc_log2_page_size); -} +extern int ioc_log2_page_size; /* * str_to_ptr - convert a string to pointer |