diff options
author | Brad King <brad.king@kitware.com> | 2020-01-30 09:49:22 -0500 |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2020-01-30 09:49:22 -0500 |
commit | 824956c40df6df495e84a2e4cdc84c29cacd8fdf (patch) | |
tree | 74760dcfd97851e5d9b4ffce1e73b8300599617f | |
parent | 9ebb248419786e116b2533353c27ae6277cf1e7b (diff) | |
download | libarchive-824956c40df6df495e84a2e4cdc84c29cacd8fdf.tar.gz |
libarchive: Fix detection of 'major' on Solaris 11.4
In `archive_pack_dev.c` there is code checking the `HAVE_MAJOR` macro,
but it is not computed. Port the equivalent logic from
`archive_entry.c` to define the macro.
-rw-r--r-- | libarchive/archive_pack_dev.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/libarchive/archive_pack_dev.c b/libarchive/archive_pack_dev.c index a5e57ac2..f8286d82 100644 --- a/libarchive/archive_pack_dev.c +++ b/libarchive/archive_pack_dev.c @@ -57,11 +57,12 @@ __RCSID("$NetBSD$"); #ifdef HAVE_SYS_STAT_H #include <sys/stat.h> #endif -#ifdef HAVE_SYS_SYSMACROS_H -#include <sys/sysmacros.h> -#endif -#ifdef HAVE_SYS_MKDEV_H +#if MAJOR_IN_MKDEV #include <sys/mkdev.h> +#define HAVE_MAJOR +#elif MAJOR_IN_SYSMACROS +#include <sys/sysmacros.h> +#define HAVE_MAJOR #endif #ifdef HAVE_UNISTD_H #include <unistd.h> |