]> git.ipfire.org Git - thirdparty/libarchive.git/commitdiff
Always use our supplied la_queue.h (#2222)
authorSevan Janiyan <venture37@geeklan.co.uk>
Tue, 11 Jun 2024 03:42:13 +0000 (04:42 +0100)
committerGitHub <noreply@github.com>
Tue, 11 Jun 2024 03:42:13 +0000 (20:42 -0700)
On legacy systems the OS supplied `sys/queue.h` may lack the required
macros, so to avoid having to verify if the version of queue.h is of
use, opt to always to `la_queue.h` which will match expectations.

Allows libarchive to build on legacy Darwin where `STAILQ_FOREACH` would
be missing from `sys/queue.h`.

Resolves #2220

CMakeLists.txt
build/cmake/config.h.in
configure.ac
libarchive/config_freebsd.h
unzip/bsdunzip.c

index 51c8c08141982f8f36ddd9835031c559487e057c..3c86789c8b2be7c14b0e0bb9b69546f427f3135f 100644 (file)
@@ -743,7 +743,6 @@ LA_CHECK_INCLUDE_FILE("sys/mkdev.h" HAVE_SYS_MKDEV_H)
 LA_CHECK_INCLUDE_FILE("sys/mount.h" HAVE_SYS_MOUNT_H)
 LA_CHECK_INCLUDE_FILE("sys/param.h" HAVE_SYS_PARAM_H)
 LA_CHECK_INCLUDE_FILE("sys/poll.h" HAVE_SYS_POLL_H)
-LA_CHECK_INCLUDE_FILE("sys/queue.h" HAVE_SYS_QUEUE_H)
 LA_CHECK_INCLUDE_FILE("sys/richacl.h" HAVE_SYS_RICHACL_H)
 LA_CHECK_INCLUDE_FILE("sys/select.h" HAVE_SYS_SELECT_H)
 LA_CHECK_INCLUDE_FILE("sys/stat.h" HAVE_SYS_STAT_H)
index d47694c0c1f1a3e2c25d205f903b398ae0a065d4..d6e54879219257871f55157733153ed8d8aba227 100644 (file)
@@ -1132,9 +1132,6 @@ typedef uint64_t uintmax_t;
 /* Define to 1 if you have the <sys/poll.h> header file. */
 #cmakedefine HAVE_SYS_POLL_H 1
 
-/* Define to 1 if you have the <sys/queue.h> header file. */
-#cmakedefine HAVE_SYS_QUEUE_H 1
-
 /* Define to 1 if you have the <sys/richacl.h> header file. */
 #cmakedefine HAVE_SYS_RICHACL_H 1
 
index c4c219f1cc1352303f4386cdb8152ac94f25cd4f..7250b686faecc2cc3720c4863e108b2bb11a0770 100644 (file)
@@ -362,7 +362,7 @@ AC_CHECK_HEADERS([locale.h membership.h paths.h poll.h pthread.h pwd.h])
 AC_CHECK_HEADERS([readpassphrase.h signal.h spawn.h])
 AC_CHECK_HEADERS([stdarg.h stdint.h stdlib.h string.h])
 AC_CHECK_HEADERS([sys/acl.h sys/cdefs.h sys/ea.h sys/extattr.h])
-AC_CHECK_HEADERS([sys/ioctl.h sys/mkdev.h sys/mount.h sys/queue.h])
+AC_CHECK_HEADERS([sys/ioctl.h sys/mkdev.h sys/mount.h])
 AC_CHECK_HEADERS([sys/param.h sys/poll.h sys/richacl.h])
 AC_CHECK_HEADERS([sys/select.h sys/statfs.h sys/statvfs.h sys/sysmacros.h])
 AC_CHECK_HEADERS([sys/time.h sys/utime.h sys/utsname.h sys/vfs.h sys/xattr.h])
index d0f3e2300c9d00cd57856edd141cdfc74461a312..a1bf0dfe9f793da67f301f0a4c7e7cbf0df765e2 100644 (file)
 #define HAVE_SYS_MOUNT_H 1
 #define HAVE_SYS_PARAM_H 1
 #define HAVE_SYS_POLL_H 1
-#define HAVE_SYS_QUEUE_H 1
 #define HAVE_SYS_SELECT_H 1
 #define HAVE_SYS_STATVFS_H 1
 #define HAVE_SYS_STAT_H 1
index cec1810483c9191d8e256f1217582fe9294a6904..50e08e39955811f7e3268c1815ad2b84269f2973 100644 (file)
 
 #include "bsdunzip_platform.h"
 
-#ifdef HAVE_SYS_QUEUE_H
-#include <sys/queue.h>
-#else
 #include "la_queue.h"
-#endif
 #ifdef HAVE_SYS_STAT_H
 #include <sys/stat.h>
 #endif