Unable build 8.10.1 on s390x
Summary
On s390x build stops with:
[ 4466s] "inplace/bin/ghc-stage1" -optc-Wall -optc-Wno-return-type -optc-Wall -optc-Wextra -optc-Wstrict-prototypes -optc-Wmissing-prototypes -optc-Wmissing-declarations -optc-Winline -optc-Wpointer-arith -optc-Wmissing-noreturn -optc-Wnested-externs -optc-Wredundant-decls -optc-Wno-aggregate-return -optc-Iincludes -optc-Iincludes/dist -optc-Iincludes/dist-derivedconstants/header -optc-Iincludes/dist-ghcconstants/header -optc-Iincludes/dist-install/build -optc-Irts -optc-Irts/dist/build -optc-DCOMPILING_RTS -optc-DFS_NAMESPACE=rts -optc-DUSE_LIBFFI_FOR_ADJUSTORS -optc-fno-strict-aliasing -optc-fno-common -optc-Irts/dist/build/./autogen -optc-Werror=unused-but-set-variable -optc-Wno-error=inline -optc-O2 -optc-fomit-frame-pointer -optc-g -optc-DRtsWay=\"rts_thr\" -optc-ffunction-sections -optc-fdata-sections -static -optc-DTHREADED_RTS -H32m -O -Wall -Iincludes -Iincludes/dist -Iincludes/dist-derivedconstants/header -Iincludes/dist-ghcconstants/header -Iincludes/dist-install/build -Irts -Irts/dist/build -DCOMPILING_RTS -DFS_NAMESPACE=rts -this-unit-id rts -dcmm-lint -i -irts -irts/dist/build -Irts/dist/build -irts/dist/build/./autogen -Irts/dist/build/./autogen -O2 -Wcpp-undef -Wnoncanonical-monad-instances -c rts/StgPrimFloat.c -o rts/dist/build/StgPrimFloat.thr_o
[ 4466s] In file included from includes/Stg.h:318,
[ 4466s]
[ 4466s] from rts/StgCRun.c:45:0: error:
[ 4466s]
[ 4466s] includes/stg/Regs.h:442:2: error:
[ 4466s] error: #error BaseReg must be in a register for THREADED_RTS
[ 4466s] 442 | #error BaseReg must be in a register for THREADED_RTS
[ 4466s] | ^~~~~
[ 4466s] |
[ 4466s] 442 | #error BaseReg must be in a register for THREADED_RTS
[ 4466s] | ^
[ 4466s] In file included from includes/Stg.h:318,
[ 4466s]
[ 4466s] from rts/StgCRun.c:45:0: error:
[ 4466s] rts/StgCRun.c: In function 'StgRun':
[ 4466s]
[ 4466s] includes/stg/Regs.h:444:46: error:
[ 4466s] error: 'MainCapability' undeclared (first use in this function); did you mean 'markCapability'?
[ 4466s] 444 | #define BaseReg (&((struct PartCapability_ *)MainCapability)->r)
[ 4466s] | ^~~~~~~~~~~~~~
[ 4466s] |
[ 4466s] 444 | #define BaseReg (&((struct PartCapability_ *)MainCapability)->r)
[ 4466s] | ^
[ 4466s]
[ 4466s] includes/stg/Regs.h:161:14: error:
[ 4466s] note: in expansion of macro 'BaseReg'
[ 4466s] 161 | # define R1 (BaseReg->rR1)
[ 4466s] | ^~~~~~~
[ 4466s] |
[ 4466s] 161 | # define R1 (BaseReg->rR1)
[ 4466s] | ^
[ 4466s]
[ 4466s] rts/StgCRun.c:83:27: error:
[ 4466s] note: in expansion of macro 'R1'
[ 4466s] 83 | return (StgRegTable *)R1.p;
[ 4466s] | ^~
[ 4466s] |
[ 4466s] 83 | return (StgRegTable *)R1.p;
[ 4466s] | ^
[ 4466s]
[ 4466s] includes/stg/Regs.h:444:46: error:
[ 4466s] note: each undeclared identifier is reported only once for each function it appears in
[ 4466s] 444 | #define BaseReg (&((struct PartCapability_ *)MainCapability)->r)
[ 4466s] | ^~~~~~~~~~~~~~
[ 4466s] |
[ 4466s] 444 | #define BaseReg (&((struct PartCapability_ *)MainCapability)->r)
[ 4466s] | ^
[ 4466s]
[ 4466s] includes/stg/Regs.h:161:14: error:
[ 4466s] note: in expansion of macro 'BaseReg'
[ 4466s] 161 | # define R1 (BaseReg->rR1)
[ 4466s] | ^~~~~~~
[ 4466s] |
[ 4466s] 161 | # define R1 (BaseReg->rR1)
[ 4466s] | ^
[ 4466s]
[ 4466s] rts/StgCRun.c:83:27: error:
[ 4466s] note: in expansion of macro 'R1'
[ 4466s] 83 | return (StgRegTable *)R1.p;
[ 4466s] | ^~
[ 4466s] |
[ 4466s] 83 | return (StgRegTable *)R1.p;
[ 4466s] | ^
[ 4466s] `cc' failed in phase `C Compiler'. (Exit code: 1)
[ 4466s] make[1]: *** [rts/ghc.mk:322: rts/dist/build/StgCRun.thr_o] Error 1
[ 4466s] make[1]: *** Waiting for unfinished jobs....
[ 4466s] make: *** [Makefile:128: all] Error 2
[ 4466s] error: Bad exit status from /var/tmp/rpm-tmp.J0wvxD (%build)
Steps to reproduce
./configure
./make
Expected behaviour
build ghc
Environment
s390x
- GHC version used:
for bootstrapping 8.8.3
Optional:
- Operating System: openSUSE Tumbleweed zSystems
- System Architecture: s390x