Re: git: 27626082ac4c - main - emulators/dosbox-x: fix build on powerpc64*
Date: Sun, 01 Nov 2026 17:30:11 UTC
Hello Piotr, Thanks for commit. Are these changes upstreamed? Thanks, Piotr Kubaj <pkubaj@freebsd.org> escreveu (sábado, 31/10/2026 à(s) 15:16): > The branch main has been updated by pkubaj: > > URL: > https://cgit.FreeBSD.org/ports/commit/?id=27626082ac4cc1c9d254fce0a4cd586c8ca27cca > > commit 27626082ac4cc1c9d254fce0a4cd586c8ca27cca > Author: Piotr Kubaj <pkubaj@FreeBSD.org> > AuthorDate: 2026-10-27 18:49:49 +0000 > Commit: Piotr Kubaj <pkubaj@FreeBSD.org> > CommitDate: 2026-10-31 15:13:52 +0000 > > emulators/dosbox-x: fix build on powerpc64* > > dosbox-x assumes long double is the x87 80-bit type on everything that > isn't x86 or ARM. It isn't on powerpc64*, so the FPU register union is > wrong there and 2026.10.01 doesn't even compile. Use the float80 path > like aarch64 does. Also fix the bundled lzma endianness check, FreeBSD > defines _LITTLE_ENDIAN on big-endian too. > --- > emulators/dosbox-x/files/patch-include_dosbox.h | 12 > ++++++++++++ > .../dosbox-x/files/patch-src_libs_libchdr_lzma_CpuArch.h | 10 > ++++++++++ > 2 files changed, 22 insertions(+) > > diff --git a/emulators/dosbox-x/files/patch-include_dosbox.h > b/emulators/dosbox-x/files/patch-include_dosbox.h > new file mode 100644 > index 000000000000..7685f059a3a0 > --- /dev/null > +++ b/emulators/dosbox-x/files/patch-include_dosbox.h > @@ -0,0 +1,12 @@ > +--- include/dosbox.h.orig 2026-10-27 11:58:28 UTC > ++++ include/dosbox.h > +@@ -104,6 +104,9 @@ > + #elif defined(__arm__) || defined(__aarch64__) > + // ARMv7 (Raspberry Pi) does not have long double, sizeof(long double) > == sizeof(double) > + // ARM 64 has a quadruple-precision float instead of the 80-bit extended > precision one used by x87 > ++#elif defined(__LDBL_MANT_DIG__) && __LDBL_MANT_DIG__ != 64 > ++// long double is not the x87 80-bit extended format: either the same as > double (FreeBSD/powerpc64 > ++// and powerpc64le before 16.0) or IEEE binary128 (Linux ppc64le, > riscv64, s390x, loongarch64) > + #else > + // GCC, other compilers, have sizeof(long double) == 10 80-bit IEEE > + #define HAS_LONG_DOUBLE 1 > diff --git > a/emulators/dosbox-x/files/patch-src_libs_libchdr_lzma_CpuArch.h > b/emulators/dosbox-x/files/patch-src_libs_libchdr_lzma_CpuArch.h > new file mode 100644 > index 000000000000..2f311f1d5d1b > --- /dev/null > +++ b/emulators/dosbox-x/files/patch-src_libs_libchdr_lzma_CpuArch.h > @@ -0,0 +1,10 @@ > +--- src/libs/libchdr/lzma/CpuArch.h.orig 2026-01-14 10:48:42 UTC > ++++ src/libs/libchdr/lzma/CpuArch.h > +@@ -247,7 +247,6 @@ MY_CPU_64BIT means that processor can work with 64-bit > + || defined(MY_CPU_ARM_LE) \ > + || defined(MY_CPU_ARM64_LE) \ > + || defined(MY_CPU_IA64_LE) \ > +- || defined(_LITTLE_ENDIAN) \ > + || defined(__LITTLE_ENDIAN__) \ > + || defined(__ARMEL__) \ > + || defined(__THUMBEL__) \ > > -- Nuno Teixeira FreeBSD UNIX: <eduardo@FreeBSD.org> Web: https://FreeBSD.org