Dockerfile: prefer ld for building against arm64

We already prefer ld for cross-building arm64 but that seems
not enough as native arm64 build also has a linker issue with lld
so we need to also prefer ld for native arm64 build.

Signed-off-by: CrazyMax <crazy-max@users.noreply.github.com>
(cherry picked from commit d2d6ef431f)
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
This commit is contained in:
CrazyMax 2023-01-19 16:34:34 +01:00 committed by Sebastiaan van Stijn
parent 9ea2300535
commit a21381a55a
No known key found for this signature in database
GPG key ID: 76698F39D527CE8C

View file

@ -583,7 +583,7 @@ ARG PACKAGER_NAME
ENV PREFIX=/tmp
RUN <<EOT
# in bullseye arm64 target does not link with lld so configure it to use ld instead
if xx-info is-cross && [ "$(xx-info arch)" = "arm64" ]; then
if [ "$(xx-info arch)" = "arm64" ]; then
XX_CC_PREFER_LINKER=ld xx-clang --setup-target-triple
fi
EOT