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

Precompiled binary for Alpine Linux #107

Closed
zacksiri opened this issue Jan 11, 2025 · 4 comments
Closed

Precompiled binary for Alpine Linux #107

zacksiri opened this issue Jan 11, 2025 · 4 comments

Comments

@zacksiri
Copy link
Contributor

I saw that in earlier version there was support for alpine linux. However it seems this support was removed.

Is it possible to have prebuilt binary for alpine? Or is this simply not feasible?

@zacksiri
Copy link
Contributor Author

I just tried to build it in Alpine 3.20 and ran into this issue

INFO: Found 1 target...
[0 / 10] [Prepa] BazelWorkspaceStatusAction stable-status.txt
[5 / 2,424] Compiling llvm/lib/Demangle/ItaniumDemangle.cpp [for tool]; 1s local ... (36 actions, 35 running)
[9 / 2,424] Compiling llvm/lib/Demangle/ItaniumDemangle.cpp [for tool]; 2s local ... (36 actions, 35 running)
ERROR: /root/.cache/xla_extension/xla-fd58925adee147d38c25a085354e15427a12d00a/xla/service/cpu/BUILD:939:11: Compiling xla/service/cpu/runtime_conv2d_mkl.cc failed: (Exit 1): gcc failed: error executing command (from target //xla/service/cpu:runtime_conv2d_mkl) /usr/bin/gcc -U_FORTIFY_SOURCE -fstack-protector -Wall -Wunused-but-set-parameter -Wno-free-nonheap-object -fno-omit-frame-pointer -g0 -O2 '-D_FORTIFY_SOURCE=1' -DNDEBUG -ffunction-sections ... (remaining 116 arguments skipped)
In file included from xla/service/cpu/runtime_conv2d_mkl.cc:15:
./xla/service/cpu/runtime_conv2d_mkl.h:25:29: error: 'int64_t' has not been declared
   25 |     float* lhs, float* rhs, int64_t input_batch, int64_t input_rows,
      |                             ^~~~~~~
./xla/service/cpu/runtime_conv2d_mkl.h:25:50: error: 'int64_t' has not been declared
   25 |     float* lhs, float* rhs, int64_t input_batch, int64_t input_rows,
      |                                                  ^~~~~~~
./xla/service/cpu/runtime_conv2d_mkl.h:26:5: error: 'int64_t' has not been declared
   26 |     int64_t input_cols, int64_t input_channels, int64_t kernel_rows,
      |     ^~~~~~~
./xla/service/cpu/runtime_conv2d_mkl.h:26:25: error: 'int64_t' has not been declared
   26 |     int64_t input_cols, int64_t input_channels, int64_t kernel_rows,
      |                         ^~~~~~~
./xla/service/cpu/runtime_conv2d_mkl.h:26:49: error: 'int64_t' has not been declared
   26 |     int64_t input_cols, int64_t input_channels, int64_t kernel_rows,
      |                                                 ^~~~~~~
./xla/service/cpu/runtime_conv2d_mkl.h:27:5: error: 'int64_t' has not been declared
   27 |     int64_t kernel_cols, int64_t kernel_channels, int64_t kernel_filters,
      |     ^~~~~~~
./xla/service/cpu/runtime_conv2d_mkl.h:27:26: error: 'int64_t' has not been declared
   27 |     int64_t kernel_cols, int64_t kernel_channels, int64_t kernel_filters,
      |                          ^~~~~~~
./xla/service/cpu/runtime_conv2d_mkl.h:27:51: error: 'int64_t' has not been declared
   27 |     int64_t kernel_cols, int64_t kernel_channels, int64_t kernel_filters,
      |                                                   ^~~~~~~
./xla/service/cpu/runtime_conv2d_mkl.h:28:5: error: 'int64_t' has not been declared
   28 |     int64_t output_rows, int64_t output_cols, int64_t row_stride,
      |     ^~~~~~~
./xla/service/cpu/runtime_conv2d_mkl.h:28:26: error: 'int64_t' has not been declared
   28 |     int64_t output_rows, int64_t output_cols, int64_t row_stride,
      |                          ^~~~~~~
./xla/service/cpu/runtime_conv2d_mkl.h:28:47: error: 'int64_t' has not been declared
   28 |     int64_t output_rows, int64_t output_cols, int64_t row_stride,
      |                                               ^~~~~~~
./xla/service/cpu/runtime_conv2d_mkl.h:29:5: error: 'int64_t' has not been declared
   29 |     int64_t col_stride, int64_t padding_top, int64_t padding_bottom,
      |     ^~~~~~~
./xla/service/cpu/runtime_conv2d_mkl.h:29:25: error: 'int64_t' has not been declared
   29 |     int64_t col_stride, int64_t padding_top, int64_t padding_bottom,
      |                         ^~~~~~~
./xla/service/cpu/runtime_conv2d_mkl.h:29:46: error: 'int64_t' has not been declared
   29 |     int64_t col_stride, int64_t padding_top, int64_t padding_bottom,
      |                                              ^~~~~~~
./xla/service/cpu/runtime_conv2d_mkl.h:30:5: error: 'int64_t' has not been declared
   30 |     int64_t padding_left, int64_t padding_right, int64_t lhs_row_dilation,
      |     ^~~~~~~
./xla/service/cpu/runtime_conv2d_mkl.h:30:27: error: 'int64_t' has not been declared
   30 |     int64_t padding_left, int64_t padding_right, int64_t lhs_row_dilation,
      |                           ^~~~~~~
./xla/service/cpu/runtime_conv2d_mkl.h:30:50: error: 'int64_t' has not been declared
   30 |     int64_t padding_left, int64_t padding_right, int64_t lhs_row_dilation,
      |                                                  ^~~~~~~
./xla/service/cpu/runtime_conv2d_mkl.h:31:5: error: 'int64_t' has not been declared
   31 |     int64_t lhs_col_dilation, int64_t rhs_row_dilation,
      |     ^~~~~~~
./xla/service/cpu/runtime_conv2d_mkl.h:31:31: error: 'int64_t' has not been declared
   31 |     int64_t lhs_col_dilation, int64_t rhs_row_dilation,
      |                               ^~~~~~~
./xla/service/cpu/runtime_conv2d_mkl.h:32:5: error: 'int64_t' has not been declared
   32 |     int64_t rhs_col_dilation);
      |     ^~~~~~~
Target //xla/extension:xla_extension failed to build
Use --verbose_failures to see the command lines of failed build steps.
INFO: Elapsed time: 3.600s, Critical Path: 3.41s
INFO: 45 processes: 38 internal, 7 local.
FAILED: Build did NOT complete successfully
make: *** [Makefile:26: /root/.cache/xla/0.8.0/build/xla_extension-0.8.0-x86_64-linux-musl-cpu.tar.gz] Error 1

Any idea how to fix?

@josevalim
Copy link
Contributor

IIRC the issue is exactly that getting XLA to build on Alpine is non trivial, but I may be wrong (or outdated) (or both).

@zacksiri
Copy link
Contributor Author

Ok thank you.

@jonatanklosko
Copy link
Member

Yeah, in the past Sean got it to compile by applying patches to xla and llvm, but at some point when updating XLA the patches no longer worked and I dropped support for Alpine. Unfortunately, from maintenance perspective it's counterproductive to support environments not supported properly upstream and keep revisiting patches whenever stuff breaks.

@jonatanklosko jonatanklosko closed this as not planned Won't fix, can't repro, duplicate, stale Jan 11, 2025
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

3 participants