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

ldd errors with precompiled gems on Alpine Linux #188

Closed
x-yuri opened this issue Mar 24, 2021 · 2 comments
Closed

ldd errors with precompiled gems on Alpine Linux #188

x-yuri opened this issue Mar 24, 2021 · 2 comments

Comments

@x-yuri
Copy link

x-yuri commented Mar 24, 2021

ldd reports errors for *.so files installed with nokogiri, google-protobuf, grpc (and possibly others). nokogiri and google-protobuf gets required successfully, but whether the ldd errors have any consequences... I'm not sure. grpc ends with an error.

Workaround. BUNDLE_FORCE_RUBY_PLATFORM=1 (bundler) or --platform ruby (gem).

a.sh:

#!/bin/sh -eux
apk add build-base

case "$1" in
nokogiri)
    gem install nokogiri -v 1.11.2
    ldd /usr/local/bundle/gems/nokogiri-*/lib/nokogiri/2.6/nokogiri.so || true
    ruby -e 'require "nokogiri"'
    ;;
google-protobuf)
    gem install google-protobuf -v 3.15.6
    ldd /usr/local/bundle/gems/google-protobuf-*/lib/google/2.6/protobuf_c.so || true
    ruby -e 'require "google/protobuf"'
    ;;
grpc)
    gem install grpc -v 1.36.0
    ldd /usr/local/bundle/gems/grpc-*/src/ruby/lib/grpc/2.6/grpc_c.so || true
    ruby -e 'require "grpc"'
    ;;
esac
$ docker run --rm -v $PWD/a.sh:/a.sh ruby:2.6-alpine3.13 ./a.sh nokogiri
...
+ ldd /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so
	/lib/ld-musl-x86_64.so.1 (0x7f2485fcd000)
	libm.so.6 => /lib/ld-musl-x86_64.so.1 (0x7f2485fcd000)
	libdl.so.2 => /lib/ld-musl-x86_64.so.1 (0x7f2485fcd000)
	libc.so.6 => /lib/ld-musl-x86_64.so.1 (0x7f2485fcd000)
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_iv_get: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_enc_str_new_static: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_string_value_cstr: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_str_concat: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_raise: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_block_proc: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_exc_new_str: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_num2dbl: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_ary_entry: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_obj_as_string: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_range_beg_len: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_num2int: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_str_new_static: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: st_foreach: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_hash_aref: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_gc_unregister_address: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: st_insert: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_str_cat: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_ensure: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_string_value: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_ary_new: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_ary_new_from_args: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_class_new_instance: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_str_cat_cstr: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_ary_new_capa: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_data_object_zalloc: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_intern: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_funcallv: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_str_conv_enc: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_utf8_encoding: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_data_object_wrap: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_respond_to: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_hash_aset: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_check_type: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_yield: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_string_value_ptr: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_define_private_method: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_ary_clear: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_gc_mark: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_iv_set: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_const_set: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_external_str_new_with_enc: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: st_init_numtable_with_size: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_str_new_cstr: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_obj_classname: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_define_method: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_define_singleton_method: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_num2long: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_obj_is_kind_of: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_error_arity: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_Integer: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_rescue: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_exc_raise: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_gc_register_address: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_obj_class: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_float_new: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_ary_push: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_default_internal_encoding: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_define_alloc_func: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_define_module: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_str_new: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_define_module_under: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_block_given_p: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_const_get_at: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_str_split: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_define_class_under: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_intern2: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_obj_call_init: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_need_block: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: st_free_table: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_fix2int: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_ary_new_from_values: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_hash_new: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_cObject: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: ruby_xfree: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: ruby_xrealloc: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: ruby_xmalloc: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: ruby_strdup: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_eStandardError: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_eRuntimeError: symbol not found
Error relocating /usr/local/bundle/gems/nokogiri-1.11.2-x86_64-linux/lib/nokogiri/2.6/nokogiri.so: rb_eArgError: symbol not found
+ true
+ ruby -e 'require "nokogiri"'
$ docker run --rm -v $PWD/a.sh:/a.sh ruby:2.6-alpine3.13 ./a.sh google-protobuf
...
+ ldd /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_ll2inum: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_gc_writebarrier_unprotect: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_str_concat: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_error_frozen_object: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_raise: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_extend_object: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_block_proc: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_id2name: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_funcall_with_block: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_data_typed_object_wrap: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_require: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_num2dbl: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_ary_entry: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_enc_str_coderange: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_define_module_id: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_range_beg_len: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_enc_associate: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_eval_string: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: ruby_vsnprintf: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_num2int: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_get_alloc_func: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_str_new_static: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_num2uint: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_hash_aref: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_inspect: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_block_call: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_obj_freeze: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_str_cat: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_num2ull: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: ruby_xfree: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_ascii8bit_encoding: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_obj_encoding: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_ary_new: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_ary_new_from_args: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_num2ll: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_check_typeddata: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_class_new_instance: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_str_cat_cstr: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_ary_new_capa: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_ivar_get: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_equal: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_intern: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_funcallv: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_utf8_encoding: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_hash_lookup: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_str_append: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_hash_aset: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: ruby_xmalloc: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_check_type: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_yield: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_define_class_id: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_hash_foreach: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_define_private_method: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_hash_lookup2: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_gc_mark: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_class2name: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_str_new_cstr: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_define_method: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_define_singleton_method: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_num2long: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_obj_is_kind_of: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_error_arity: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_str_plus: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_const_get: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_id2str: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_freeze_singleton_class: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_enc_from_encoding: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_str_encode: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_gc_register_address: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_float_new: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_ary_push: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_id2sym: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_ary_detransient: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_sym2id: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_time_timespec: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_ull2inum: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_include_module: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_define_alloc_func: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_define_module: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_str_new: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_define_module_under: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_warn: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_yield_values2: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_define_class_under: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_intern2: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_define_const: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_call_super: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_ivar_set: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_fix2int: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_hash_new: symbol not found
	/lib/ld-musl-x86_64.so.1 (0x7fa51cba9000)
	libm.so.6 => /lib/ld-musl-x86_64.so.1 (0x7fa51cba9000)
	libc.so.6 => /lib/ld-musl-x86_64.so.1 (0x7fa51cba9000)
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_cObject: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_cFloat: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_cTime: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_cNumeric: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_cString: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_cNilClass: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_eEncodingError: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_eRangeError: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_cTrueClass: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_cFalseClass: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_eRuntimeError: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_cInteger: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_mEnumerable: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_eArgError: symbol not found
Error relocating /usr/local/bundle/gems/google-protobuf-3.15.6-x86_64-linux/lib/google/2.6/protobuf_c.so: rb_cSymbol: symbol not found
+ true
+ ruby -e 'require "google/protobuf"'
$ docker run --rm -v $PWD/a.sh:/a.sh ruby:2.6-alpine3.13 ./a.sh grpc
...
+ ldd /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so
	/lib/ld-musl-x86_64.so.1 (0x7fa4d9593000)
	libm.so.6 => /lib/ld-musl-x86_64.so.1 (0x7fa4d9593000)
	libc.so.6 => /lib/ld-musl-x86_64.so.1 (0x7fa4d9593000)
Error loading shared library ld-linux-x86-64.so.2: No such file or directory (needed by /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so)
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_ivar_set: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_check_typeddata: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_struct_aref: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_const_get: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_struct_define: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_define_class_under: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_sym2id: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: __strftime_l: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_hash_aref: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_protect: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_str_new_static: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_hash_aset: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_obj_freeze: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_id2name: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_define_method: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_fix2int: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_str_new: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_define_class: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_struct_new: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_rescue: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: __strdup: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_thread_call_without_gvl: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_float_value: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_hash_foreach: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_hash_new: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_define_module: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_string_value_ptr: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_string_value_cstr: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_mutex_lock: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_num2uint: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_error_arity: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_intern2: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_str_cat: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_num2int: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_str_new_cstr: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: ruby_xmalloc: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_obj_is_proc: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_obj_classname: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_funcallv: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_global_variable: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_define_alias: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_num2long: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_ary_new: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_define_module_under: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_mutex_unlock: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_ary_entry: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_define_module_function: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_gc_mark: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_define_alloc_func: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_ivar_get: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_raise: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_intern: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_id2sym: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_check_type: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_mutex_new: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: ruby_xfree: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: ruby_xmalloc2: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_str_buf_new: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_struct_aset: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_data_typed_object_wrap: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_class2name: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_define_const: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_ary_push: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_thread_create: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_obj_class: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_jump_tag: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_eTypeError: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_cInteger: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_cStruct: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_eRangeError: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_cTime: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_eLoadError: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_eNameError: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_cTrueClass: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_eException: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_eRuntimeError: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_cSymbol: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_cFloat: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_cNilClass: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_eArgError: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_cObject: symbol not found
Error relocating /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so: rb_cFalseClass: symbol not found
+ true
+ ruby -e 'require "grpc"'
/usr/local/lib/ruby/2.6.0/rubygems/core_ext/kernel_require.rb:54:in `require': Error loading shared library ld-linux-x86-64.so.2: No such file or directory (needed by /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so) - /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/2.6/grpc_c.so (LoadError)
	from /usr/local/lib/ruby/2.6.0/rubygems/core_ext/kernel_require.rb:54:in `require'
	from /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc/grpc.rb:20:in `<top (required)>'
	from /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc.rb:19:in `require_relative'
	from /usr/local/bundle/gems/grpc-1.36.0-x86_64-linux/src/ruby/lib/grpc.rb:19:in `<top (required)>'
	from /usr/local/lib/ruby/2.6.0/rubygems/core_ext/kernel_require.rb:130:in `require'
	from /usr/local/lib/ruby/2.6.0/rubygems/core_ext/kernel_require.rb:130:in `rescue in require'
	from /usr/local/lib/ruby/2.6.0/rubygems/core_ext/kernel_require.rb:34:in `require'
	from -e:1:in `<main>'
/usr/local/lib/ruby/2.6.0/rubygems/core_ext/kernel_require.rb:54:in `require': cannot load such file -- grpc (LoadError)
	from /usr/local/lib/ruby/2.6.0/rubygems/core_ext/kernel_require.rb:54:in `require'
	from -e:1:in `<main>'
@larskanis
Copy link
Member

The missing symbols are normal. In rake-compiler-dock we use a nasty trick to avoid library name mismatches to libruby: We don't link the shared object of the gem to libruby at all, but assume that libruby is already loaded and symbols can be resolved at runtime. See here and here.

The issue Error loading shared library ld-linux-x86-64.so.2: No such file or directory (needed by grpc_c.so) seems to be related to grpc. I found this ticket where one solution was to install apk add libc6-compat .

@x-yuri
Copy link
Author

x-yuri commented Mar 25, 2021

@larskanis Then it appears the only issue is with the grpc gem. grpc fails to get required on Alpine Linux unless installed with --platform ruby. libc6-compat doesn't help. If so, this one can be closed.

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

2 participants