On Wed, November 22, 2017 18:06, Jeremie Courreges-Anglas wrote: > On Wed, Nov 22 2017, "Kirill Bychkov" <ki...@linklevel.net> wrote: >> On Tue, November 21, 2017 19:19, Jeremie Courreges-Anglas wrote: >>> On Tue, Nov 21 2017, Sol?ne Rapenne <sol...@perso.pw> wrote: >>>> Building games/tome4 on powerpc (macppc kernel) fail >>>> >>>> [-----] >>>> ==== Building luajit2 (release) ==== >>>> Creating ../obj/Release/luajit2 >>>> mkdir -p ../obj/Release/luajit2 >>>> Running pre-build commands >>>> [---cut----] >>>> In file included from ../src/luajit2/src/lj_obj.h:14:0, >>>> from ../src/luajit2/src/lj_dispatch.c:9: >>>> ../src/luajit2/src/lj_arch.h:321:2: error: #error "No support for >>>> little-endian PowerPC" >>>> #error "No support for little-endian PowerPC" >>>> ^ >>>> >>>> I propose to remove powerpc as a supported arch >>> >>> Fair proposal. lang/luajit has a patch to explicitely disable this >>> error message, plus another one for the generated asm. >>> >>> What I don't understand, though, is why luajit thinks that powerpc is >>> little-endian: our powerpc architecture is definitely big-endian. >>> >>> Could you please try to run ''make test'' in lang/luajit on powerpc? >> >> Hi! >> I'm currently trying to build tome4 on macppc. It will take some more time >> on my single core G5 :) >> But... audio/openal uses COMPILER=base-clang ports-clang ports-gcc and have >> no chance to be built on powerpc because llvm is marked broken on that arch. >> It builds with ports-gcc. > > Yep, this is not nice. > > The problem that kills luajit and tome4 is silly: our sys/_endian.h > header always defines _LITTLE_ENDIAN and _BIG_ENDIAN. To check > endianness, one should check the value of _BYTE_ORDER. > > (BYTE_ORDER if including <endian.h>) > > I don't know how upstream ended up with this additional check, but it > probably doesn't receive much attention, given that Linux defines > __LITTLE_ENDIAN, not _LITTLE_ENDIAN. So who's actually building > little-endian powerpc programs? I think it makes sense to just patch > out the offending test.
I like the idea. > Then we can take a look at COMPILER ordering. > tome4 is probably not the only affected port... I'm sure there are plenty of them. tome4 builds and starts (currently with a black screen) on my G5 with both patches taken from lang/luajit. >