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`.
@@ -57,8 +57,12 @@ __RCSID("$NetBSD$");
#ifdef HAVE_SYS_STAT_H
#include <sys/stat.h>
#endif
-#ifdef HAVE_SYS_SYSMACROS_H
+#if MAJOR_IN_MKDEV
+#include <sys/mkdev.h>
+#define HAVE_MAJOR
+#elif MAJOR_IN_SYSMACROS
#include <sys/sysmacros.h>
#ifdef HAVE_UNISTD_H
#include <unistd.h>