Date: Wed, 17 Oct 2018 20:10:05 +0000 From: bugzilla-noreply@freebsd.org To: bugs@FreeBSD.org Subject: [Bug 231965] [PowerPC64] Cross compiling powerpc64 from amd64 results in nonfunctional locale installations Message-ID: <bug-231965-227-klNvomkh3w@https.bugs.freebsd.org/bugzilla/> In-Reply-To: <bug-231965-227@https.bugs.freebsd.org/bugzilla/> References: <bug-231965-227@https.bugs.freebsd.org/bugzilla/>
next in thread | previous in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D231965 Yuri Pankov <yuripv@FreeBSD.org> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |yuripv@FreeBSD.org --- Comment #2 from Yuri Pankov <yuripv@FreeBSD.org> --- Looking at this, I wonder if powerpc ISOs (at least, 12-ALPHA10 snapshot) cross-compiled on amd64 as the locale data files are matching the ones on my amd64 system. In any case, it looks like the check in lib/libc/locale/endian.h needs to include __powerpc__ as well, or just check for big endian. I've cross-comp= iled libc with the following change on amd64, and was able to run simple test program just doing setlocale(), and even run tmux preloading the resulting libc.so.7: diff --git a/lib/libc/locale/endian.h b/lib/libc/locale/endian.h index d3b822788688..ade03bdc8997 100644 --- a/lib/libc/locale/endian.h +++ b/lib/libc/locale/endian.h @@ -45,7 +45,7 @@ * correct macros here. */ -#if BYTE_ORDER =3D=3D BIG_ENDIAN && defined(__mips__) +#if BYTE_ORDER =3D=3D BIG_ENDIAN #define BSWAP(x) le32toh(x) #else #define BSWAP(x) x I'm NOT sure if this is correct for all cases, and if it will not break nat= ive powerpc builds, need to investigate a bit more. --=20 You are receiving this mail because: You are the assignee for the bug.=
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-231965-227-klNvomkh3w>