Search Issue Tracker

Fixed

Fixed in 1.8.25

Votes

0

Found in [Package]

1.8.24

Issue ID

BUR-2898

Regression

Yes

[Android] Burst Compiler fails during linker stage when Stack Protector is set to All for 32-bit Android builds

Package: Burst

-

How to reproduce:
1. Open the “ReproProject.zip“ project
2. Open the “SampleScene“
3. Build for Android

Expected result: Build does not fail
Actual result: Build fails with the burst compiler errors

Reproducible with: 1.8.20 (6000.0.13f1), 1.8.21 (6000.0.13f1, 6000.0.49f1), 1.8.24 (2022.3.66f1, 6000.0.57f1, 6000.2.3f1, 6000.3.0b1)
Not reproducible with: 1.8.17, 1.8.18, 1.8.19 (6000.0.13f1)

Reproducible environment: macOS 15.6.1 (M4 Max), Windows 11 (Reporters)
Not reproducible environment: No other environment tested

Note: In the “Edit > Project Settings > Burst AOT Settings > Android“ Stack Protector must be set to “All“ and in the “Edit > Project Settings > Player > Android > Configuration“ under Target Architecture, ARMv7 must be enabled to reproduce the issue

Errors:
Library/Bee/artifacts/Android/AsyncPluginsFromLinker: ld.lld: error: relocation R_ARM_THM_MOVW_PREL_NC cannot be used against symbol '__stack_chk_guard'; recompile with -fPIC

Library/Bee/artifacts/Android/AsyncPluginsFromLinker: Burst internal compiler error: Burst.Compiler.IL.Aot.AotLinkerException: Non 0 exit code | The native link step failed.

  1. Resolution Note (fix version 1.8.25):

    The error occurs because the Stack Protector feature introduces references to `__stack_chk_guard`, which require position-independent code (PIC). By default, the PIC level for 32-bit Android builds was insufficient ("small").

    The solution was to set the PIC level to "big" for 32-bit Android builds. This ensures that all code generated is fully position-independent and compatible with the stack protector requirements and linker expectations.

Add comment

Log in to post comment

All about bugs

View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.