Whamcloud - gitweb
Clean up the header file #include's for lib/blkid/getsize.c
authorTheodore Ts'o <tytso@mit.edu>
Fri, 17 Sep 2004 23:07:03 +0000 (19:07 -0400)
committerTheodore Ts'o <tytso@mit.edu>
Fri, 17 Sep 2004 23:07:03 +0000 (19:07 -0400)
and lib/ext2fs/getsize.c

In lib/blkid/getsize.c, include <sys/disk.h> if present since
this is where the DIOCGMEDIASIZE ioctl is defined on FreeBSD.
(Addresses Debian Bug #264630)

ChangeLog
configure
configure.in
lib/blkid/ChangeLog
lib/blkid/getsize.c
lib/ext2fs/ChangeLog
lib/ext2fs/getsize.c

index 2518da4..76c5b69 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2004-09-17  Theodore Ts'o  <tytso@mit.edu>
+
+       * config.guess, config.sub: Update to newer version from the FSF
+               (2004-06-11)
+
+       * configure.in, configure: Add test for the sys/queue.h header file.
+
 2004-05-04  Theodore Ts'o  <tytso@mit.edu>
 
        * e2fsprogs.spec.in: Fix up e2fsprogs.spec file so it should work
index 30ae696..f386232 100644 (file)
--- a/configure
+++ b/configure
@@ -5272,7 +5272,7 @@ test -n "$BUILD_CC" && break
 done
 
 fi
-for ac_hdr in stdlib.h unistd.h stdarg.h stdint.h errno.h malloc.h mntent.h paths.h dirent.h getopt.h setjmp.h signal.h termios.h linux/fd.h linux/major.h sys/disk.h sys/disklabel.h sys/ioctl.h sys/mkdev.h sys/mount.h sys/sockio.h sys/socket.h sys/sysmacros.h sys/time.h sys/stat.h sys/types.h sys/wait.h sys/resource.h net/if.h net/if_dl.h netinet/in.h
+for ac_hdr in stdlib.h unistd.h stdarg.h stdint.h errno.h malloc.h mntent.h paths.h dirent.h getopt.h setjmp.h signal.h termios.h linux/fd.h linux/major.h sys/disk.h sys/disklabel.h sys/ioctl.h sys/mkdev.h sys/mount.h sys/queue.h sys/sockio.h sys/socket.h sys/sysmacros.h sys/time.h sys/stat.h sys/types.h sys/wait.h sys/resource.h net/if.h net/if_dl.h netinet/in.h
 do
 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
index 5d2f220..79a39f4 100644 (file)
@@ -586,7 +586,7 @@ if test $cross_compiling = no; then
 else
   AC_CHECK_PROGS(BUILD_CC, gcc cc)
 fi
-AC_CHECK_HEADERS(stdlib.h unistd.h stdarg.h stdint.h errno.h malloc.h mntent.h paths.h dirent.h getopt.h setjmp.h signal.h termios.h linux/fd.h linux/major.h sys/disk.h sys/disklabel.h sys/ioctl.h sys/mkdev.h sys/mount.h sys/sockio.h sys/socket.h sys/sysmacros.h sys/time.h sys/stat.h sys/types.h sys/wait.h sys/resource.h net/if.h net/if_dl.h netinet/in.h)
+AC_CHECK_HEADERS(stdlib.h unistd.h stdarg.h stdint.h errno.h malloc.h mntent.h paths.h dirent.h getopt.h setjmp.h signal.h termios.h linux/fd.h linux/major.h sys/disk.h sys/disklabel.h sys/ioctl.h sys/mkdev.h sys/mount.h sys/queue.h sys/sockio.h sys/socket.h sys/sysmacros.h sys/time.h sys/stat.h sys/types.h sys/wait.h sys/resource.h net/if.h net/if_dl.h netinet/in.h)
 AC_FUNC_VPRINTF
 dnl Check to see if dirent has member d_reclen. On cygwin those d_reclen
 dnl is not decleared.
index 63ca354..c95f1dd 100644 (file)
@@ -1,5 +1,10 @@
 2004-09-17  Theodore Ts'o  <tytso@mit.edu>
 
+       * getsize.c: Clean up header #include's.  Include sys/disk.h if
+               present since this is the new place where the
+               DIOCGMEDIASIZE ioctl is defined on FreeBSD systems.
+               (Addresses Debian bug #264630)
+
        * llseek.c (blkid_llseek): On non-linux systems, use lseek64() if
                it is present.  (Addresses Debian bug #269044)
 
index 5d389e3..94e00fa 100644 (file)
 #include <errno.h>
 #endif
 #include <fcntl.h>
-#ifdef HAVE_LINUX_FD_H
+#ifdef HAVE_SYS_IOCTL_H
 #include <sys/ioctl.h>
+#endif
+#ifdef HAVE_LINUX_FD_H
 #include <linux/fd.h>
-#endif /* HAVE_LINUX_FD_H */
+#endif
 #ifdef HAVE_SYS_DISKLABEL_H
-#include <sys/ioctl.h>
 #include <sys/disklabel.h>
 #include <sys/stat.h>
-#endif /* HAVE_SYS_DISKLABEL_H */
+#endif
+#ifdef HAVE_SYS_DISK_H
+#ifdef HAVE_SYS_QUEUE_H
+#include <sys/queue.h> /* for LIST_HEAD */
+#endif
+#include <sys/disk.h>
+#endif
 #ifdef __linux__
 #include <sys/utsname.h>
 #endif
 
 #include "blkidP.h"
 
+
 #if defined(__linux__) && defined(_IO) && !defined(BLKGETSIZE)
 #define BLKGETSIZE _IO(0x12,96)        /* return device size */
 #endif
@@ -44,9 +52,6 @@
 #endif
 
 #ifdef APPLE_DARWIN
-#include <sys/ioctl.h>
-#include <sys/disk.h>
-
 #define BLKGETSIZE DKIOCGETBLOCKCOUNT32
 #endif /* APPLE_DARWIN */
 
index edf9afc..036a502 100644 (file)
@@ -1,5 +1,7 @@
 2004-09-17  Theodore Ts'o  <tytso@mit.edu>
 
+       * getsize.c: Clean up header #include's.
+
        * llseek.c (ext2fs_llseek): On non-linux systems, use lseek64() if
                it is present.  (Addresses Debian bug #269044)
 
index 0567a03..360ecdf 100644 (file)
 #include <errno.h>
 #endif
 #include <fcntl.h>
-#ifdef HAVE_LINUX_FD_H
+#ifdef HAVE_SYS_IOCTL_H
 #include <sys/ioctl.h>
+#endif
+#ifdef HAVE_LINUX_FD_H
 #include <linux/fd.h>
 #endif
 #ifdef HAVE_SYS_DISKLABEL_H
-#include <sys/ioctl.h>
 #include <sys/disklabel.h>
-#endif /* HAVE_SYS_DISKLABEL_H */
+#endif
 #ifdef HAVE_SYS_DISK_H
+#ifdef HAVE_SYS_QUEUE_H
 #include <sys/queue.h> /* for LIST_HEAD */
+#endif
 #include <sys/disk.h>
-#endif /* HAVE_SYS_DISK_H */
+#endif
 #ifdef __linux__
 #include <sys/utsname.h>
 #endif
@@ -48,9 +51,6 @@
 #endif
 
 #ifdef APPLE_DARWIN
-#include <sys/ioctl.h>
-#include <sys/disk.h>
-
 #define BLKGETSIZE DKIOCGETBLOCKCOUNT32
 #endif /* APPLE_DARWIN */