[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#1018203: kodi-inputstream-adaptive: FTBFS on ppc64el (regression in endian detection)



Package: kodi-inputstream-adaptive
Version: 20.2.0+ds1-1
Severity: serious
Tags: patch
Justification: ftbfs
User: ubuntu-devel@lists.ubuntu.com
Usertags: origin-ubuntu kinetic ubuntu-patch

Hi Vasyl,

The kodi-inputstream-adaptive package is failing to build on ppc64el in
Debian because it fails to detect the endianness of the platform.

The attached patch fixes this build failure by making use of the
general-purpose macros that are exported by default by gcc.  (This also
fixes the build on riscv64, which is not a release architecture in Debian
but is in Ubuntu.)

Please consider applying this patch in Debian.

-- 
Steve Langasek                   Give me a lever long enough and a Free OS
Debian Developer                   to set it on, and I can move the world.
Ubuntu Developer                                   https://www.debian.org/
slangasek@ubuntu.com                                     vorlon@debian.org
diff -Nru kodi-inputstream-adaptive-20.2.0+ds1/debian/patches/byte-order-all-archs kodi-inputstream-adaptive-20.2.0+ds1/debian/patches/byte-order-all-archs
--- kodi-inputstream-adaptive-20.2.0+ds1/debian/patches/byte-order-all-archs	1969-12-31 16:00:00.000000000 -0800
+++ kodi-inputstream-adaptive-20.2.0+ds1/debian/patches/byte-order-all-archs	2022-08-26 14:04:30.000000000 -0700
@@ -0,0 +1,18 @@
+Description: fix endian detection to be portable to all gcc archs
+Author: Steve Langasek <steve.langasek@ubuntu.com>
+Last-Update: 2022-08-26
+Forwarded: no
+
+Index: kodi-inputstream-adaptive-20.2.0+ds1/bento4-embedded/Source/C++/Core/Ap4Config.h
+===================================================================
+--- kodi-inputstream-adaptive-20.2.0+ds1.orig/bento4-embedded/Source/C++/Core/Ap4Config.h
++++ kodi-inputstream-adaptive-20.2.0+ds1/bento4-embedded/Source/C++/Core/Ap4Config.h
+@@ -56,7 +56,7 @@
+ #if defined(_M_IX86) || defined(_M_X64) || defined(_M_ARM) || defined(_M_ARM64)
+ #define AP4_PLATFORM_BYTE_ORDER AP4_PLATFORM_BYTE_ORDER_LITTLE_ENDIAN
+ #endif
+-#elif defined(__i386__) || defined(__x86_64__) || defined(__arm__) || defined(__arm64__) || defined(__aarch64__)
++#elif defined(__i386__) || defined(__x86_64__) || defined(__arm__) || defined(__arm64__) || defined(__aarch64__) || (__BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__)
+ #define AP4_PLATFORM_BYTE_ORDER AP4_PLATFORM_BYTE_ORDER_LITTLE_ENDIAN
+ #endif
+ #endif
diff -Nru kodi-inputstream-adaptive-20.2.0+ds1/debian/patches/series kodi-inputstream-adaptive-20.2.0+ds1/debian/patches/series
--- kodi-inputstream-adaptive-20.2.0+ds1/debian/patches/series	2022-08-04 00:19:38.000000000 -0700
+++ kodi-inputstream-adaptive-20.2.0+ds1/debian/patches/series	2022-08-26 13:54:03.000000000 -0700
@@ -1,2 +1,3 @@
 0001-Use-packaged-libwebm.patch
 0002-CVE-2019-17452-2021-32265-etc.patch
+byte-order-all-archs

Reply to: