handle sstem (sco 3) with glob but not glob.h
authorAndrew Tridgell <tridge@samba.org>
Wed, 9 Sep 1998 06:31:13 +0000 (06:31 +0000)
committerAndrew Tridgell <tridge@samba.org>
Wed, 9 Sep 1998 06:31:13 +0000 (06:31 +0000)
configure.in
rsync.h
util.c

index 3afb857c4583939345afde4d579cf1824e9c4653..82f164e057c03cb7073d2989fa8967efea709c16 100644 (file)
@@ -16,6 +16,7 @@ AC_HEADER_SYS_WAIT
 AC_CHECK_HEADERS(sys/fcntl.h sys/select.h fcntl.h sys/time.h sys/unistd.h unistd.h utime.h grp.h)
 AC_CHECK_HEADERS(compat.h sys/param.h ctype.h sys/wait.h sys/ioctl.h)
 AC_CHECK_HEADERS(sys/filio.h string.h stdlib.h sys/socket.h sys/mode.h)
+AC_CHECK_HEADERS(glob.h)
 
 AC_CHECK_SIZEOF(int)
 AC_CHECK_SIZEOF(long)
diff --git a/rsync.h b/rsync.h
index b2945133a3a0c9e80021942c8a1479f3220bed53..ef7ea88895cb2bcdb538488428311ee87c704c3a 100644 (file)
--- a/rsync.h
+++ b/rsync.h
 #include "lib/fnmatch.h"
 #endif
 
-#ifdef HAVE_GLOB
+#ifdef HAVE_GLOB_H
 #include <glob.h>
 #endif
 
diff --git a/util.c b/util.c
index 8b36474ebd6dd895c0b6239c76b7a44ed3368ba3..6e0fbabac5ca6f03c1a01eb6c1526cc2e6e05ecf 100644 (file)
--- a/util.c
+++ b/util.c
@@ -427,7 +427,7 @@ int lock_range(int fd, int offset, int len)
 
 static void glob_expand_one(char *s, char **argv, int *argc, int maxargs)
 {
-#ifndef HAVE_GLOB
+#if !(defined(HAVE_GLOB) && defined(HAVE_GLOB_H))
        if (!*s) s = ".";
        argv[*argc] = strdup(s);
        (*argc)++;