NetBSD build fixes
Signed-off-by: Emmanuel Dreyfus <manu@netbsd.org> Change-Id: I8f9aabeadd2f842521a82e59594115bd80155d68 BUG: 2923 Signed-off-by: Emmanuel Dreyfus <manu@netbsd.org> Reviewed-on: http://review.gluster.com/3053 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Anand Avati <avati@redhat.com>
This commit is contained in:
parent
92baa61bfe
commit
7313b22f10
@ -1460,11 +1460,13 @@ cli_get_detail_status (dict_t *dict, int i, cli_volume_status_t *status)
|
|||||||
if (!status->total)
|
if (!status->total)
|
||||||
goto out;
|
goto out;
|
||||||
|
|
||||||
|
#ifdef GF_LINUX_HOST_OS
|
||||||
memset (key, 0, sizeof (key));
|
memset (key, 0, sizeof (key));
|
||||||
snprintf (key, sizeof (key), "brick%d.device", i);
|
snprintf (key, sizeof (key), "brick%d.device", i);
|
||||||
ret = dict_get_str (dict, key, &(status->device));
|
ret = dict_get_str (dict, key, &(status->device));
|
||||||
if (ret)
|
if (ret)
|
||||||
status->device = NULL;
|
status->device = NULL;
|
||||||
|
#endif
|
||||||
|
|
||||||
memset (key, 0, sizeof (key));
|
memset (key, 0, sizeof (key));
|
||||||
snprintf (key, sizeof (key), "brick%d.block_size", i);
|
snprintf (key, sizeof (key), "brick%d.block_size", i);
|
||||||
|
10
configure.ac
10
configure.ac
@ -394,6 +394,11 @@ dnl Linux, Solaris, Cygwin
|
|||||||
AC_CHECK_MEMBERS([struct stat.st_atim.tv_nsec])
|
AC_CHECK_MEMBERS([struct stat.st_atim.tv_nsec])
|
||||||
dnl FreeBSD, NetBSD
|
dnl FreeBSD, NetBSD
|
||||||
AC_CHECK_MEMBERS([struct stat.st_atimespec.tv_nsec])
|
AC_CHECK_MEMBERS([struct stat.st_atimespec.tv_nsec])
|
||||||
|
case $host_os in
|
||||||
|
*netbsd*)
|
||||||
|
CFLAGS=-D_INCOMPLETE_XOPEN_C063
|
||||||
|
;;
|
||||||
|
esac
|
||||||
AC_CHECK_FUNC([linkat], [have_linkat=yes])
|
AC_CHECK_FUNC([linkat], [have_linkat=yes])
|
||||||
if test "x${have_linkat}" = "xyes"; then
|
if test "x${have_linkat}" = "xyes"; then
|
||||||
AC_DEFINE(HAVE_LINKAT, 1, [define if found linkat])
|
AC_DEFINE(HAVE_LINKAT, 1, [define if found linkat])
|
||||||
@ -474,8 +479,9 @@ case $host_os in
|
|||||||
if test "x$ac_cv_header_execinfo_h" = "xyes"; then
|
if test "x$ac_cv_header_execinfo_h" = "xyes"; then
|
||||||
GF_GLUSTERFS_LDFLAGS="-lexecinfo"
|
GF_GLUSTERFS_LDFLAGS="-lexecinfo"
|
||||||
fi
|
fi
|
||||||
GF_FUSE_LDADD="-liconv -lperfuse"
|
GF_FUSE_LDADD="-lperfuse"
|
||||||
BUILD_FUSE_CLIENT=no
|
BUILD_FUSE_CLIENT=yes
|
||||||
|
LEXLIB=""
|
||||||
;;
|
;;
|
||||||
*bsd*)
|
*bsd*)
|
||||||
GF_HOST_OS="GF_BSD_HOST_OS"
|
GF_HOST_OS="GF_BSD_HOST_OS"
|
||||||
|
@ -30,6 +30,7 @@
|
|||||||
#include <fcntl.h>
|
#include <fcntl.h>
|
||||||
#include <dirent.h>
|
#include <dirent.h>
|
||||||
#include <assert.h>
|
#include <assert.h>
|
||||||
|
#include <signal.h>
|
||||||
#include <sys/wait.h>
|
#include <sys/wait.h>
|
||||||
#include <sys/resource.h>
|
#include <sys/resource.h>
|
||||||
|
|
||||||
|
@ -56,6 +56,7 @@ enum gf_dump_procnum {
|
|||||||
#define xdr_u_quad_t xdr_u_int64_t
|
#define xdr_u_quad_t xdr_u_int64_t
|
||||||
#define xdr_quad_t xdr_int64_t
|
#define xdr_quad_t xdr_int64_t
|
||||||
#define xdr_uint32_t xdr_u_int32_t
|
#define xdr_uint32_t xdr_u_int32_t
|
||||||
|
#define xdr_uint64_t xdr_u_int64_t
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
@ -19,6 +19,7 @@
|
|||||||
|
|
||||||
#include "xdr-nfs3.h"
|
#include "xdr-nfs3.h"
|
||||||
#include "mem-pool.h"
|
#include "mem-pool.h"
|
||||||
|
#include "xdr-common.h"
|
||||||
|
|
||||||
#if GF_DARWIN_HOST_OS
|
#if GF_DARWIN_HOST_OS
|
||||||
#define xdr_u_quad_t xdr_u_int64_t
|
#define xdr_u_quad_t xdr_u_int64_t
|
||||||
|
@ -24,6 +24,9 @@
|
|||||||
#include <sys/sysctl.h>
|
#include <sys/sysctl.h>
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#ifndef GF_REQUEST_MAXGROUPS
|
||||||
|
#define GF_REQUEST_MAXGROUPS 16
|
||||||
|
#endif /* GF_REQUEST_MAXGROUPS */
|
||||||
|
|
||||||
static void
|
static void
|
||||||
fuse_resolve_wipe (fuse_resolve_t *resolve)
|
fuse_resolve_wipe (fuse_resolve_t *resolve)
|
||||||
|
@ -85,7 +85,7 @@ start_glusterfs ()
|
|||||||
--volfile-server-transport=$transport");
|
--volfile-server-transport=$transport");
|
||||||
else
|
else
|
||||||
cmd_line=$(echo "$cmd_line \
|
cmd_line=$(echo "$cmd_line \
|
||||||
--volfile-server=$server_ip \
|
--volfile-server=$server_ip");
|
||||||
fi
|
fi
|
||||||
else
|
else
|
||||||
cmd_line=$(echo "$cmd_line --volfile=$volfile_loc");
|
cmd_line=$(echo "$cmd_line --volfile=$volfile_loc");
|
||||||
@ -173,6 +173,7 @@ main ()
|
|||||||
|
|
||||||
[ -r "$volfile_loc" ] || {
|
[ -r "$volfile_loc" ] || {
|
||||||
server_ip=$(echo "$volfile_loc" | sed -n 's/\([a-zA-Z0-9:.\-]*\):.*/\1/p');
|
server_ip=$(echo "$volfile_loc" | sed -n 's/\([a-zA-Z0-9:.\-]*\):.*/\1/p');
|
||||||
|
volume_id=$(echo "$volfile_loc" | sed -n 's/[a-zA-Z0-9:.\-]*:\(.*\)/\1/p');
|
||||||
volfile_loc="";
|
volfile_loc="";
|
||||||
}
|
}
|
||||||
# following line is product of love towards sed
|
# following line is product of love towards sed
|
||||||
|
@ -27,7 +27,9 @@
|
|||||||
#include <sys/stat.h>
|
#include <sys/stat.h>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
#include <libgen.h>
|
#include <libgen.h>
|
||||||
|
#ifdef GF_LINUX_HOST_OS
|
||||||
#include <alloca.h>
|
#include <alloca.h>
|
||||||
|
#endif
|
||||||
|
|
||||||
#include "posix-handle.h"
|
#include "posix-handle.h"
|
||||||
#include "posix.h"
|
#include "posix.h"
|
||||||
|
Loading…
Reference in New Issue
Block a user