From b6ca96ec95145b453790f519abbbae91cd6c9771 Mon Sep 17 00:00:00 2001 From: Brad King Date: Wed, 4 Jan 2012 09:37:54 -0500 Subject: libarchive: Include linux/types.h before linux/fiemap.h Some Linux API versions do not perform this inclusion automatically, so types like __u64 needed by the latter are not available. --- Utilities/cmlibarchive/CMakeLists.txt | 1 + Utilities/cmlibarchive/build/cmake/config.h.in | 3 +++ Utilities/cmlibarchive/libarchive/archive_read_disk_entry_from_file.c | 3 +++ 3 files changed, 7 insertions(+) diff --git a/Utilities/cmlibarchive/CMakeLists.txt b/Utilities/cmlibarchive/CMakeLists.txt index 2352693..a24bb5d 100644 --- a/Utilities/cmlibarchive/CMakeLists.txt +++ b/Utilities/cmlibarchive/CMakeLists.txt @@ -250,6 +250,7 @@ LA_CHECK_INCLUDE_FILE("inttypes.h" HAVE_INTTYPES_H) LA_CHECK_INCLUDE_FILE("io.h" HAVE_IO_H) LA_CHECK_INCLUDE_FILE("langinfo.h" HAVE_LANGINFO_H) LA_CHECK_INCLUDE_FILE("limits.h" HAVE_LIMITS_H) +LA_CHECK_INCLUDE_FILE("linux/types.h" HAVE_LINUX_TYPES_H) LA_CHECK_INCLUDE_FILE("linux/fiemap.h" HAVE_LINUX_FIEMAP_H) LA_CHECK_INCLUDE_FILE("linux/fs.h" HAVE_LINUX_FS_H) LA_CHECK_INCLUDE_FILE("linux/magic.h" HAVE_LINUX_MAGIC_H) diff --git a/Utilities/cmlibarchive/build/cmake/config.h.in b/Utilities/cmlibarchive/build/cmake/config.h.in index 71a7801..ff97cbd 100644 --- a/Utilities/cmlibarchive/build/cmake/config.h.in +++ b/Utilities/cmlibarchive/build/cmake/config.h.in @@ -603,6 +603,9 @@ typedef uint64_t uintmax_t; /* Define to 1 if you have the `link' function. */ #cmakedefine HAVE_LINK 1 +/* Define to 1 if you have the header file. */ +#cmakedefine HAVE_LINUX_TYPES_H 1 + /* Define to 1 if you have the header file. */ #cmakedefine HAVE_LINUX_FIEMAP_H 1 diff --git a/Utilities/cmlibarchive/libarchive/archive_read_disk_entry_from_file.c b/Utilities/cmlibarchive/libarchive/archive_read_disk_entry_from_file.c index 8ce88b3..fdeb516 100644 --- a/Utilities/cmlibarchive/libarchive/archive_read_disk_entry_from_file.c +++ b/Utilities/cmlibarchive/libarchive/archive_read_disk_entry_from_file.c @@ -73,6 +73,9 @@ __FBSDID("$FreeBSD: head/lib/libarchive/archive_read_disk_entry_from_file.c 2010 #ifdef HAVE_LIMITS_H #include #endif +#ifdef HAVE_LINUX_TYPES_H +#include +#endif #ifdef HAVE_LINUX_FIEMAP_H #include #endif -- cgit v0.12