Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

@org_lzma_lzma does not compile on aarch64 #380

Open
hzeller opened this issue Feb 19, 2025 · 0 comments
Open

@org_lzma_lzma does not compile on aarch64 #380

hzeller opened this issue Feb 19, 2025 · 0 comments

Comments

@hzeller
Copy link
Collaborator

hzeller commented Feb 19, 2025

Compiling on an aarch64 machine (Raspberry Pi 5)

Linux pi5 6.6.62+rpt-rpi-2712 #1 SMP PREEMPT Debian 1:6.6.62-1+rpt1 (2024-11-25) aarch64 GNU/Linux

the @org_lzma_lzma compilation fails:

bazel build @org_lzma_lzma//... --keep_going
Starting local Bazel server and connecting to it...
INFO: Analyzed 3 targets (65 packages loaded, 482 targets configured).
ERROR: /home/pi/.cache/bazel/_bazel_pi/0cde8161736ea9e02205f75b95c5e10c/external/org_lzma_lzma/BUILD.bazel:52:11: Compiling src/liblzma/check/crc64_fast.c failed: (Exit 1): gcc failed: error executing CppCompile command (from target @@org_lzma_lzma//:lzma) /usr/bin/gcc -U_FORTIFY_SOURCE -fstack-protector -Wall -Wunused-but-set-parameter -Wno-free-nonheap-object -fno-omit-frame-pointer -MD -MF ... (remaining 42 arguments skipped)

Use --sandbox_debug to see verbose messages from the sandbox and retain the sandbox build root for debugging
external/org_lzma_lzma/src/liblzma/check/crc64_fast.c:69:25: fatal error: cpuid.h: No such file or directory
   69 | #               include <cpuid.h>
      |                         ^~~~~~~~~
compilation terminated.

Apparently, this needs some defines and/or bazelselect() somewhere to do different things depending on architecture (cpuid is only something available on x86).

(I noticed that in the compilation of XLS)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant