]> git.ipfire.org Git - thirdparty/kmod.git/commitdiff
missing.h: remove be32toh wrapper
authorEmil Velikov <emil.l.velikov@gmail.com>
Thu, 22 Aug 2024 16:04:21 +0000 (17:04 +0100)
committerLucas De Marchi <lucas.de.marchi@gmail.com>
Fri, 23 Aug 2024 18:51:19 +0000 (13:51 -0500)
As the inline comment says, it is applicable for older distributions
like RHEL 5. The extended support for RHEL 5 ended in 2020 (4 years ago)
so we're safe to drop this.

According to the Alpine build logs - the symbol has been present in musl
for years.

Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
Reviewed-by: Lucas De Marchi <lucas.de.marchi@gmail.com>
Link: https://github.com/kmod-project/kmod/pull/86
Signed-off-by: Lucas De Marchi <lucas.de.marchi@gmail.com>
configure.ac
shared/missing.h

index 844350a8af012f6aefe35b786bc55e7dba78b5f6..7acaa8b0460567c73b221b45f543e2d7d522ca7a 100644 (file)
@@ -56,9 +56,6 @@ AC_CHECK_MEMBERS([struct stat.st_mtim], [], [], [#include <sys/stat.h>])
 # not desired here
 AC_CHECK_DECLS_ONCE([[strndupa], [basename]], [], [], [[#include <string.h>]])
 
-# RHEL 5 and older do not have be32toh
-AC_CHECK_DECLS_ONCE([be32toh])
-
 # Check kernel headers
 AC_CHECK_HEADERS_ONCE([linux/module.h])
 
index 0c225a249dab2ee95b37442c7357f09addc10725..137c9a9fd47ebd4d0b80e54d3eb8ae1bcd6bc0b7 100644 (file)
@@ -58,13 +58,3 @@ static inline const char *basename(const char *s)
        return p ? p + 1 : s;
 }
 #endif
-
-#if !HAVE_DECL_BE32TOH
-#include <endian.h>
-#include <byteswap.h>
-#if __BYTE_ORDER == __LITTLE_ENDIAN
-#define be32toh(x) bswap_32 (x)
-#else
-#define be32toh(x) (x)
-#endif
-#endif