summaryrefslogtreecommitdiffstats
path: root/kttsd/players
diff options
context:
space:
mode:
authorSlávek Banko <slavek.banko@axis.cz>2021-01-26 17:06:34 +0100
committerSlávek Banko <slavek.banko@axis.cz>2021-01-26 17:06:34 +0100
commit32f9e36ff092405084dbf49224ec60092e37b08f (patch)
treee4f10b54b0c1deda729d518ae60417b7bee41d8e /kttsd/players
parent91fc9555abdfd455096b61b350d57ec79943b220 (diff)
downloadtdeaccessibility-32f9e36ff092405084dbf49224ec60092e37b08f.tar.gz
tdeaccessibility-32f9e36ff092405084dbf49224ec60092e37b08f.zip
Define byteswap functions for FreeBSD and NetBSD.
This resolves FTBFS for kttsd alsaplayer. Signed-off-by: Slávek Banko <slavek.banko@axis.cz>
Diffstat (limited to 'kttsd/players')
-rw-r--r--kttsd/players/alsaplayer/formats.h11
1 files changed, 9 insertions, 2 deletions
diff --git a/kttsd/players/alsaplayer/formats.h b/kttsd/players/alsaplayer/formats.h
index 2c4f724..e70380f 100644
--- a/kttsd/players/alsaplayer/formats.h
+++ b/kttsd/players/alsaplayer/formats.h
@@ -1,8 +1,15 @@
#ifndef FORMATS_H
#define FORMATS_H 1
-#include <endian.h>
-#include <byteswap.h>
+#if defined(__FreeBSD__) || defined(__NetBSD__)
+# include <sys/endian.h>
+# define bswap_16(x) bswap16(x)
+# define bswap_32(x) bswap32(x)
+# define bswap_64(x) bswap64(x)
+#else
+# include <endian.h>
+# include <byteswap.h>
+#endif
/* Definitions for .VOC files */