SecBSD's official ports repository
This commit is contained in:
commit
2c0afcbbf3
64331 changed files with 5339189 additions and 0 deletions
35
archivers/unshield/patches/patch-lib_internal_h
Normal file
35
archivers/unshield/patches/patch-lib_internal_h
Normal file
|
@ -0,0 +1,35 @@
|
|||
Index: lib/internal.h
|
||||
--- lib/internal.h.orig
|
||||
+++ lib/internal.h
|
||||
@@ -105,30 +105,7 @@ uint8_t* unshield_header_get_buffer(Header* header, ui
|
||||
#define FSIZE(file) ((file) ? unshield_fsize(file) : 0)
|
||||
#define STREQ(s1,s2) (0 == strcmp(s1,s2))
|
||||
|
||||
-#if WORDS_BIGENDIAN
|
||||
-
|
||||
-#if HAVE_BYTESWAP_H
|
||||
-#include <byteswap.h>
|
||||
-#elif HAVE_SYS_BYTESWAP_H
|
||||
-#include <sys/byteswap.h>
|
||||
-#else
|
||||
-
|
||||
-/* use our own functions */
|
||||
-#define IMPLEMENT_BSWAP_XX 1
|
||||
-#define bswap_16 unshield_bswap_16
|
||||
-#define bswap_32 unshield_bswap_32
|
||||
-
|
||||
-uint16_t bswap_16(uint16_t x);
|
||||
-uint32_t bswap_32(uint32_t x);
|
||||
-#endif
|
||||
-
|
||||
-#define letoh16(x) bswap_16(x)
|
||||
-#define letoh32(x) bswap_32(x)
|
||||
-
|
||||
-#else
|
||||
-#define letoh32(x) (x)
|
||||
-#define letoh16(x) (x)
|
||||
-#endif
|
||||
+#include <endian.h>
|
||||
|
||||
static inline uint16_t get_unaligned_le16(const uint8_t *p)
|
||||
{
|
Loading…
Add table
Add a link
Reference in a new issue