View Issue Details
| ID | Project | Category | View Status | Date Submitted | Last Update |
|---|---|---|---|---|---|
| 0006615 | unreal | installing | public | 2026-03-07 16:01 | 2026-03-07 19:40 |
| Reporter | PhotoJim | Assigned To | syzop | ||
| Priority | normal | Severity | major | Reproducibility | always |
| Status | feedback | Resolution | open | ||
| Platform | aarch64 | OS | Arch Linux ARM | OS Version | Rolling Disto |
| Product Version | 6.2.3 | ||||
| Summary | 0006615: libsodium does not compile on arm64 with gcc -- replace the .tar.gz | ||||
| Description | Compile fails (doesn't matter if 'unrealircd upgrade' or manual compile: Making all in src make[1]: Entering directory '/usr/src/unrealircd-6.2.3/extras/libsodium-1.0.21/src' Making all in libsodium make[2]: Entering directory '/usr/src/unrealircd-6.2.3/extras/libsodium-1.0.21/src/libsodium' Making all in include make[3]: Entering directory '/usr/src/unrealircd-6.2.3/extras/libsodium-1.0.21/src/libsodium/include' make[3]: Nothing to be done for 'all'. make[3]: Leaving directory '/usr/src/unrealircd-6.2.3/extras/libsodium-1.0.21/src/libsodium/include' make[3]: Entering directory '/usr/src/unrealircd-6.2.3/extras/libsodium-1.0.21/src/libsodium' CC crypto_aead/aegis128l/libsodium_la-aegis128l_soft.lo during RTL pass: subreg1 In file included from crypto_aead/aegis128l/aegis128l_soft.c:52: crypto_aead/aegis128l/aegis128l_common.h: In function 'decrypt_detached': crypto_aead/aegis128l/aegis128l_common.h:252:1: internal compiler error: Bus error 252 | } | ^ 0x1df34bb diagnostic_context::diagnostic_impl(rich_location*, diagnostic_metadata const*, diagnostic_option_id, char const*, std::__va_list*, diagnostic_t) ???:0 0x1e04dd7 internal_error(char const*, ...) ???:0 gcc: internal compiler error: Segmentation fault signal terminated program cc1 Please submit a full bug report, with preprocessed source (by using -freport-bug). See <https://github.com/archlinuxarm/PKGBUILDs/issues> for instructions. make[3]: *** [Makefile:2768: crypto_aead/aegis128l/libsodium_la-aegis128l_soft.lo] Error 1 make[3]: Leaving directory '/usr/src/unrealircd-6.2.3/extras/libsodium-1.0.21/src/libsodium' make[2]: *** [Makefile:3715: all-recursive] Error 1 make[2]: Leaving directory '/usr/src/unrealircd-6.2.3/extras/libsodium-1.0.21/src/libsodium' make[1]: *** [Makefile:413: all-recursive] Error 1 make[1]: Leaving directory '/usr/src/unrealircd-6.2.3/extras/libsodium-1.0.21/src' make: *** [Makefile:528: all-recursive] Error 1 | ||||
| Steps To Reproduce | Attempt to compile, without libsodium having been manually installed. | ||||
| Additional Information | I have two unrealircd servers. Upgrade succeeded on Debian x64 system. Manually installing libsodium seems to work around the error. inxi -b: System: Host: hostname Kernel: 6.19.5-1-aarch64-ARCH arch: aarch64 bits: 64 Console: pty pts/3 Distro: Arch Linux ARM Machine: Type: ARM System: Pine64 PINE A64+ details: N/A serial: 92c000ba83a466c9 CPU: Info: quad core Model N/A [MCP] speed (MHz): avg: 1152 min/max: 648/1152 Graphics: Device-1: sun50i-a64-mali driver: lima v: kernel Device-2: sun50i-a64-dw-hdmi driver: sun8i_dw_hdmi v: N/A Device-3: sun50i-a64-display-engine driver: sun4i_drm v: kernel Display: uns Info: Tools: x11: xprop Network: Device-1: sun50i-a64-emac driver: dwmac_sun8i Drives: Local Storage: total: 29.72 GiB used: 12.51 GiB (42.1%) Info: Memory: total: N/A available: 1.92 GiB used: 317.7 MiB (16.1%) Processes: 155 Uptime: 3d 10h 20m Init: systemd Shell: Bash inxi: 3.3.40 pecified server: N/A driver: N/A tty: 80x24 API: N/A Message: No API data available in console. Headless machine? lscpu: Info: Tools: x11: xprop Network: Device-1: sun50i-a64-emac driver: dwmac_sun8i Drives: Local Storage: total: 29.72 GiB used: 12.51 GiB (42.1%) Info: Memory: total: N/A available: 1.92 GiB used: 317.7 MiB (16.1%) Processes: 155 Uptime: 3d 10h 20m Init: systemd Shell: Bash inxi: 3.3.40 NOTE: manually installing libsodium results in a different failure: https://0bin.xyz/?45e032c832b4569d#4ZqdLA1XkRyb1SSEq2r5YkSHrUoZLYrnBmp82sbnYzJW | ||||
| 3rd party modules | |||||
|
|
In our buildbot we test compile with aarch64 on a raspberry pi 5 VM with 2GB memory. But libsodium package is installed there. I noticed you said it also crashed if you did have libsodium system package but then it crashes later (quoting you):gcc -I/usr/src/unrealircd-6.2.3/include -I/usr/src/unrealircd-6.2.3/extras/argon2/include -g -O2 -fno-strict-aliasing -fno-common -funsigned-char -Wall -Wextra -Waggregate-return -Wformat-nonliteral -Wduplicated-cond -Wduplicated-branches -Wparentheses -Wno-pointer-sign -Wno-format-zero-length -Wno-format-truncation -Wno-format-overflow -Wno-unused -Wno-unused-parameter -Wno-unused-but-set-parameter -Wno-char-subscripts -Wno-sign-compare -Wno-empty-body -Wno-deprecated-non-prototype -Wno-unterminated-string-initialization -Wno-pragmas -std=gnu17 -fno-strict-overflow -D_FORTIFY_SOURCE=3 -fstack-protector-all -Wstack-protector --param ssp-buffer-size=1 -fstack-clash-protection -mbranch-protection=standard -fstrict-flex-arrays=3 -ftrivial-auto-var-init=zero -fPIE -c unrealdb.c
during RTL pass: subreg1
unrealdb.c: In function ‘unrealdb_open’:
unrealdb.c:480:1: internal compiler error: Bus error
480 | }
| ^
0x1df34bb diagnostic_context::diagnostic_impl(rich_location*, diagnostic_metadata const*, diagnostic_option_id, char const*, std::__va_list*, diagnostic_t)
???:0
0x1e04dd7 internal_error(char const*, ...)
???:0
gcc: internal compiler error: Segmentation fault signal terminated program cc1
Please submit a full bug report, with preprocessed source (by using -freport-bCould it be that it is out of memory? Even though you are also on 2GB hmm.. For the make step during configure, so during compiling of libraries we do have a bit weird algorithm at the moment: if [ "$LOWMEM" = 0 ]; then
echo "Running with 4 concurrent build processes by default (make -j4)."
export MAKE='make -j4'
else
echo "System detected with less than 750MB available memory, not forcing parallel build."
fiSo it is 1 process or 4, nothing in-between :D. We should probably tweak that to like 2 processes or something for xxxx memory. |
|
|
I think you hit a memory limit here but it could also be some compiler bug. To work around it you could, after running ./Config, edit the Makefile, and there remove the -O2 part from XCFLAGS. The compiler should take a lot less memory without -O2. If that still doesn't work then try -O0 (minus O zero). Hope that helps :) |
|
|
Managed to remove libsodium system lib on my system (sortof), then I get this error... so not a compiler crash with SIGBUS or SIGSEGV that you had, but a fatal error:crypto_ipcrypt/ipcrypt_armcrypto.c:356:65: error: incompatible type for argument 2 of 'vorrq_u8'
356 | v = vreinterpretq_u64_u8(vorrq_u8(shl, carries));
| ^~~~~~~
| |
| BlockVec {aka uint64x2_t}
/usr/lib/gcc/aarch64-linux-gnu/15/include/arm_neon.h:1193:38: note: expected 'uint8x16_t' but argument is of type 'BlockVec' {aka 'uint64x2_t'}
1193 | vorrq_u8 (uint8x16_t __a, uint8x16_t __b)
| ~~~~~~~~~~~^~~
make[3]: *** [Makefile:2712: crypto_ipcrypt/libarmcrypto_la-ipcrypt_armcrypto.lo] Error 1
make[3]: *** Waiting for unfinished jobs....
make[3]: Leaving directory '/home/bbworker/worker/unreal6-pi/build/extras/libsodium-1.0.21/src/libsodium' |
|
|
Oh and the bugs alice and i get are known and fixed in libsodium: https://github.com/jedisct1/libsodium/issues/1502 https://github.com/jedisct1/libsodium/issues/1509 ...specifically on aarch64 On January 11 2026 someone asked if they could release a 1.0.22, but they didn't do that yet. |
|
|
RAM does not seem to be the problem. 2 GB physical RAM, 1.5 GB swap. Swap is not touched. I watched a compilation with 'watch free' running and it doesn't appear that RAM usage got much over 300 MB. Swap was never used. System settled down to 166 MB used after compilation failed. Overriding the makefile to remove '-O2' (again, with libsodium manually installed) makes compilation succeed. So there are two problems here for sure. |
|
|
If useful: gcc (GCC) 15.2.1 20260209 Copyright (C) 2025 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. [jim@hostname ~]$ gcc -c -Q -O2 --help=optimizers The following options control optimizations: --param=lto-partition-locality-cloning= maximal -O<number> -Ofast -Og -Os -Oz -faggressive-loop-optimizations [enabled] -falign-functions [enabled] -falign-functions= 32:16 -falign-jumps [enabled] -falign-jumps= 4 -falign-labels [enabled] -falign-labels= -falign-loops [enabled] -falign-loops= 32:16 -fallocation-dce [enabled] -fallow-store-data-races [disabled] -fassociative-math [disabled] -fassume-sane-operators-new-delete [available in C++, ObjC++] -fasynchronous-unwind-tables [enabled] -fauto-inc-dec [enabled] -favoid-store-forwarding [disabled] -fbit-tests [enabled] -fbranch-count-reg [enabled] -fbranch-probabilities [disabled] -fcaller-saves [enabled] -fcode-hoisting [enabled] -fcombine-stack-adjustments [enabled] -fcompare-elim [enabled] -fconserve-stack [disabled] -fcprop-registers [enabled] -fcrossjumping [enabled] -fcse-follow-jumps [enabled] -fcx-fortran-rules [disabled] -fcx-limited-range [disabled] -fdce [enabled] -fdefer-pop [enabled] -fdelayed-branch [disabled] -fdelete-dead-exceptions [disabled] -fdelete-null-pointer-checks -fdevirtualize [enabled] -fdevirtualize-speculatively [enabled] -fdse [enabled] -fearly-inlining [enabled] -fexceptions [available in D, Modula-2] -fexcess-precision=[fast|standard|16] [default] -fexpensive-optimizations [enabled] -fext-dce [enabled] -ffast-math -ffinite-loops [disabled] -ffinite-math-only [disabled] -ffloat-store [disabled] -ffold-mem-offsets [enabled] -ffold-simple-inlines [available in C++, ObjC++] -fforward-propagate [enabled] -ffp-contract=[off|on|fast] fast -ffp-int-builtin-inexact [enabled] -ffunction-cse [enabled] -fgcse [enabled] -fgcse-after-reload [disabled] -fgcse-las [disabled] -fgcse-lm [enabled] -fgcse-sm [disabled] -fgraphite [disabled] -fgraphite-identity [disabled] -fguess-branch-probability [enabled] -fhandle-exceptions -fexceptions -fhardcfr-check-exceptions -fhardcfr-check-noreturn-calls=[always|no-xthrow|nothrow|never] [default] -fhardcfr-check-returning-calls -fhardcfr-skip-leaf [disabled] -fharden-compares [disabled] -fharden-conditional-branches [disabled] -fharden-control-flow-redundancy [disabled] -fhoist-adjacent-loads [enabled] -fif-conversion [enabled] -fif-conversion2 [enabled] -findirect-inlining [enabled] -finline [enabled] -finline-atomics [enabled] -finline-functions [enabled] -finline-functions-called-once [enabled] -finline-small-functions [enabled] -finline-stringops [disabled] -finline-stringops= [default] -fipa-bit-cp [enabled] -fipa-cp [enabled] -fipa-cp-clone [disabled] -fipa-icf [enabled] -fipa-icf-functions [enabled] -fipa-icf-variables [enabled] -fipa-modref [enabled] -fipa-profile [enabled] -fipa-pta [disabled] -fipa-pure-const [enabled] -fipa-ra [enabled] -fipa-reference [enabled] -fipa-reference-addressable [enabled] -fipa-reorder-for-locality [disabled] -fipa-sra [enabled] -fipa-stack-alignment [enabled] -fipa-strict-aliasing [enabled] -fipa-vrp [enabled] -fira-algorithm=[CB|priority] CB -fira-hoist-pressure [enabled] -fira-loop-pressure [disabled] -fira-region=[one|all|mixed] one -fira-share-save-slots [enabled] -fira-share-spill-slots [enabled] -fisolate-erroneous-paths-attribute [disabled] -fisolate-erroneous-paths-dereference [enabled] -fivopts [enabled] -fjump-tables [enabled] -fkeep-gc-roots-live [disabled] -flate-combine-instructions [enabled] -flifetime-dse [enabled] -flifetime-dse=<0,2> 2 -flimit-function-alignment [disabled] -flive-patching -flive-patching=inline-clone -flive-patching=[inline-only-static|inline-clone] [default] -flive-range-shrinkage [disabled] -floop-interchange [disabled] -floop-nest-optimize [disabled] -floop-parallelize-all [disabled] -floop-unroll-and-jam [disabled] -flra-remat [enabled] -fmalloc-dce [enabled] -fmalloc-dce=<0,2> 0 -fmath-errno [enabled] -fmin-function-alignment= 0 -fmodulo-sched [disabled] -fmodulo-sched-allow-regmoves [disabled] -fmove-loop-invariants [enabled] -fmove-loop-stores [enabled] -fno-inline-stringops [enabled] -fnon-call-exceptions [disabled] -fnothrow-opt [available in C++, ObjC++] -fomit-frame-pointer [enabled] -fopenmp-target-simd-clone= nohost -fopt-info [disabled] -foptimize-crc [enabled] -foptimize-sibling-calls [enabled] -foptimize-strlen [enabled] -fpack-struct [disabled] -fpack-struct=<number> -fpartial-inlining [enabled] -fpatchable-function-entry= -fpcc-struct-return [disabled] -fpeel-loops [disabled] -fpeephole [enabled] -fpeephole2 [enabled] -fplt [enabled] -fpredictive-commoning [disabled] -fprefetch-loop-arrays -fprintf-return-value [enabled] -fprofile-partial-training [disabled] -fprofile-reorder-functions [disabled] -freciprocal-math [disabled] -free [enabled] -freg-struct-return -fpcc-struct-return -frename-registers [disabled] -freorder-blocks [enabled] -freorder-blocks-algorithm=[simple|stc] stc -freorder-blocks-and-partition [disabled] -freorder-functions [enabled] -frerun-cse-after-loop [enabled] -freschedule-modulo-scheduled-loops [disabled] -frounding-math [disabled] -frtti [available in C++, D, ObjC++] -fsave-optimization-record [disabled] -fsched-critical-path-heuristic [enabled] -fsched-dep-count-heuristic [enabled] -fsched-group-heuristic [enabled] -fsched-interblock [enabled] -fsched-last-insn-heuristic [enabled] -fsched-pressure [enabled] -fsched-rank-heuristic [enabled] -fsched-spec [enabled] -fsched-spec-insn-heuristic [enabled] -fsched-spec-load [disabled] -fsched-spec-load-dangerous [disabled] -fsched-stalled-insns [disabled] -fsched-stalled-insns-dep [enabled] -fsched-stalled-insns-dep=<number> -fsched-stalled-insns=<number> -fsched2-use-superblocks [disabled] -fschedule-fusion [enabled] -fschedule-insns [disabled] -fschedule-insns2 [enabled] -fsection-anchors [enabled] -fsel-sched-pipelining [disabled] -fsel-sched-pipelining-outer-loops [disabled] -fsel-sched-reschedule-pipelined [disabled] -fselective-scheduling [disabled] -fselective-scheduling2 [disabled] -fsemantic-interposition [enabled] -fshort-enums [disabled] -fshort-wchar [disabled] -fshrink-wrap [enabled] -fshrink-wrap-separate [enabled] -fsignaling-nans [disabled] -fsigned-zeros [enabled] -fsimd-cost-model=[unlimited|dynamic|cheap|very-cheap] unlimited -fsingle-precision-constant [disabled] -fsplit-ivs-in-unroller [enabled] -fsplit-loops [disabled] -fsplit-paths [disabled] -fsplit-wide-types [enabled] -fsplit-wide-types-early [disabled] -fssa-backprop [enabled] -fssa-phiopt [enabled] -fstack-check=[no|generic|specific] -fstack-clash-protection [disabled] -fstack-protector [disabled] -fstack-protector-all [disabled] -fstack-protector-explicit [disabled] -fstack-protector-strong [enabled] -fstack-reuse=[all|named_vars|none] all -fstdarg-opt [enabled] -fstore-merging [enabled] -fstrict-aliasing [enabled] -fstrict-enums [available in C++, ObjC++] -fstrict-volatile-bitfields [enabled] -fthread-jumps [enabled] -fno-threadsafe-statics [available in C++, ObjC++] -ftoplevel-reorder [enabled] -ftracer [disabled] -ftrapping-math [enabled] -ftrapv [disabled] -ftree-bit-ccp [enabled] -ftree-builtin-call-dce [enabled] -ftree-ccp [enabled] -ftree-ch [enabled] -ftree-coalesce-vars [enabled] -ftree-copy-prop [enabled] -ftree-cselim [disabled] -ftree-dce [enabled] -ftree-dominator-opts [enabled] -ftree-dse [enabled] -ftree-forwprop [enabled] -ftree-fre [enabled] -ftree-loop-distribute-patterns [enabled] -ftree-loop-distribution [disabled] -ftree-loop-if-convert -ftree-loop-im [enabled] -ftree-loop-ivcanon [enabled] -ftree-loop-optimize [enabled] -ftree-loop-vectorize [enabled] -ftree-lrs [disabled] -ftree-parallelize-loops=<number> 1 -ftree-partial-pre [disabled] -ftree-phiprop [enabled] -ftree-pre [enabled] -ftree-pta [enabled] -ftree-reassoc [enabled] -ftree-scev-cprop [enabled] -ftree-sink [enabled] -ftree-slp-vectorize [enabled] -ftree-slsr [enabled] -ftree-sra [enabled] -ftree-switch-conversion [enabled] -ftree-tail-merge [enabled] -ftree-ter [enabled] -ftree-vectorize [disabled] -ftree-vrp [enabled] -ftrivial-auto-var-init=[uninitialized|pattern|zero] uninitialized -funconstrained-commons [disabled] -funreachable-traps [disabled] -funroll-all-loops [disabled] -funroll-completely-grow-size [disabled] -funroll-loops [disabled] -funsafe-math-optimizations [disabled] -funswitch-loops [disabled] -funwind-tables [enabled] -fvar-tracking [disabled] -fvar-tracking-assignments [disabled] -fvar-tracking-assignments-toggle [disabled] -fvar-tracking-uninit [disabled] -fvariable-expansion-in-unroller [disabled] -fvect-cost-model=[unlimited|dynamic|cheap|very-cheap] very-cheap -fversion-loops-for-strides [disabled] -fvpt [disabled] -fweb [disabled] -fwrapv [disabled] -fwrapv-pointer [disabled] -gstatement-frontiers [disabled] -mearly-ldp-fusion [enabled] -mearly-ra= all -mlate-ldp-fusion [enabled] -mlow-precision-div [disabled] -mlow-precision-recip-sqrt [disabled] -mlow-precision-sqrt [disabled] |
|
|
Yeah indeed. On IRC i concluded it is probably due to that new(er) gcc version. And there were other reports of that gcc version crashing. It will probably be fine on next gcc dot release or something. But the other issue, the regular compiler error, that you triggered by talking about this, is a real thing... it doesn't compile at all for me or alice. And this is a known issue on their github and fixed. So I'll have to replace the .tar.gz. Will keep this issue open for that. |
|
|
I've also updated my BuildBot so it compiles with shipped libraries (so --without-system.....everything... basically). This runs on any changes in extras/. This works correctly if triggered manually: it fails on the pi5 arm64 with gcc and succeeds with clang. Also all other archs/builders it succeeded. Anyway, that should help us with catching these issues in the future when we update dependencies and/or if some standard compiler hates one of our shipped libs. |
| Date Modified | Username | Field | Change |
|---|---|---|---|
| 2026-03-07 16:01 | PhotoJim | New Issue | |
| 2026-03-07 16:43 | syzop | Note Added: 0023620 | |
| 2026-03-07 16:45 | syzop | Note Added: 0023621 | |
| 2026-03-07 16:45 | syzop | Assigned To | => syzop |
| 2026-03-07 16:45 | syzop | Status | new => feedback |
| 2026-03-07 17:08 | syzop | Note Added: 0023622 | |
| 2026-03-07 17:11 | syzop | Note Added: 0023623 | |
| 2026-03-07 18:09 | PhotoJim | Note Added: 0023624 | |
| 2026-03-07 18:16 | PhotoJim | Note Added: 0023625 | |
| 2026-03-07 19:36 | syzop | Note Added: 0023626 | |
| 2026-03-07 19:37 | syzop | Note Edited: 0023626 | |
| 2026-03-07 19:39 | syzop | Note Added: 0023627 | |
| 2026-03-07 19:40 | syzop | Note Edited: 0023627 | |
| 2026-03-07 19:40 | syzop | Summary | Compile fails - "internal compiler error" /usr/src/unreal-6.2.3/extras/libsodium-1.0.21/src/libsodium => libsodium does not compile on arm64 with gcc -- replace the .tar.gz |