app-admin/chrpath: add fix for Solaris
authorFabian Groffen <grobian@gentoo.org>
Mon, 17 Jun 2019 18:35:27 +0000 (20:35 +0200)
committerFabian Groffen <grobian@gentoo.org>
Mon, 17 Jun 2019 18:37:26 +0000 (20:37 +0200)
Signed-off-by: Fabian Groffen <grobian@gentoo.org>
Package-Manager: Portage-2.3.66, Repoman-2.3.11

app-admin/chrpath/chrpath-0.16.ebuild
app-admin/chrpath/files/chrpath-0.16-solaris.patch [new file with mode: 0644]

index 51137b39303e679dac49cead89aee4c0168184bb..323e49a75d976676c311707272b28bac0454ea26 100644 (file)
@@ -17,6 +17,7 @@ IUSE="static-libs"
 PATCHES=(
        "${FILESDIR}"/${P}-multilib.patch
        "${FILESDIR}"/${P}-testsuite-1.patch
+       "${FILESDIR}"/${P}-solaris.patch
 )
 
 src_prepare() {
diff --git a/app-admin/chrpath/files/chrpath-0.16-solaris.patch b/app-admin/chrpath/files/chrpath-0.16-solaris.patch
new file mode 100644 (file)
index 0000000..5e1dd19
--- /dev/null
@@ -0,0 +1,19 @@
+protos: add bswap macros for Solaris
+
+--- a/protos.h
++++ b/protos.h
+@@ -1,7 +1,14 @@
+ #ifndef PROTOS_H
+ #define PROTOS_H
++#if defined(__sun)
++#include <sys/byteorder.h>
++#define bswap_16(x) BSWAP_16(x)
++#define bswap_32(x) BSWAP_32(x)
++#define bswap_64(x) BSWAP_64(x)
++#else
+ #include <byteswap.h>
++#endif
+ #include <elf.h>
+ #include "config.h"