ceph.in: handle DYLD_LIBRARY_PATH on OS X

On OS X, the environment variable to override
to .libs is DYLD_LIBRARY_PATH instead of
LD_LIBRARY_PATH.

Signed-off-by: John Spray <john.spray@redhat.com>
common/Thread: add missing #include for pid_t

On linux this worked by side effect from
pthread.h, but POSIX header for pid_t is
sys/types.h -- this is needed on OS X.

Signed-off-by: John Spray <john.spray@redhat.com>
os/FileStore: move ZFS_SUPER_MAGIC in linux ifdef

The __SWORD_TYPE for this line is linux-specific.

Signed-off-by: John Spray <john.spray@redhat.com>
client: handle missing O_RSYNC constant

Although this is part of POSIX, it's missing on
OS X.  #define it to zero in this case so that checks
for the flag will always be false.

Signed-off-by: John Spray <john.spray@redhat.com>
common: move #include syscall into ifndef DARWIN

Signed-off-by: John Spray <john.spray@redhat.com>
os/FileStore: put SUPER usage in ifdef __linux__

This is an update to take account of 9312c5e wherein
the FS_* enum was replaced by direct use of SUPER_MAGIC
macros.

Signed-off-by: John Spray <john.spray@redhat.com>
mds: avoid comparing MutationRef with 0

LLVM on OS X considers this == operator with an int
ambiguous: compare with an explicit MutationRef()
instead.

Signed-off-by: John Spray <john.spray@redhat.com>
Merge pull request #2042 from ceph/wip-port-fixes

Portability updates

Reviewed-by: Sage Weil <sage@redhat.com>