From: hsbt@... Date: 2020-10-05T11:21:17+00:00 Subject: [ruby-dev:50966] [Ruby master Bug#17212] FreeBSDで3.0.0-preview1のビルドが失敗する Issue #17212 has been updated by hsbt (Hiroshi SHIBATA). FreeBSD 13 については、https://bugs.ruby-lang.org/issues/16674 にあるように `--disable-dtrace` つけるとどうでしょうか? ---------------------------------------- Bug #17212: FreeBSDで3.0.0-preview1のビルドが失敗する https://bugs.ruby-lang.org/issues/17212#change-87885 * Author: yasuhirokimura (Yasuhiro KIMURA) * Status: Open * Priority: Normal * Backport: 2.5: UNKNOWN, 2.6: UNKNOWN, 2.7: UNKNOWN ---------------------------------------- 題名の通り、FreeBSDで3.0.0-preview1のビルドが失敗します。 再現手順は以下の通り 1. tar xfpvJ ruby-3.0.0-preview1.tar.xz 2. cd ruby-3.0.0-preview1 3. ./configure 4. make FreeBSD 12.1-RELEASE amd64では、以下のようなエラーとなります。 ``` building .ext/include/x86_64-freebsd12.1/rb_mjit_min_header-3.0.0.h ./miniruby -I./lib -I. -I.ext/common ./tool/transform_mjit_header.rb "clang -fdeclspec -O3 -ggdb3 -Wall -Wextra -Werror=deprecated-declarations -Werror=division-by-zero -Werror=implicit-function-declaration -Werror=implicit-int -Werror=pointer-arith -Werror=shorten-64-to-32 -Werror=write-strings -Wmissing-noreturn -Wno-constant-logical-operand -Wno-long-long -Wno-missing-field-initializers -Wno-overlength-strings -Wno-parentheses-equality -Wno-self-assign -Wno-tautological-compare -Wno-unused-parameter -Wno-unused-value -Wunused-variable -Werror=extra-tokens -std=gnu99 " rb_mjit_header.h .ext/include/x86_64-freebsd12.1/rb_mjit_min_header-3.0.0.h transform_mjit_header: making external definition static inline: rb_vm_lvar_exposed, Init_vm_stack_canary, rb_vm_opt_cfunc_p, rb_find_defined_class_by_owner, rb_vm_rewrite_cref, rb_vm_block_ep_update, rb_vm_cref_new_toplevel, rb_vm_frame_block_handler, rb_vm_cframe_keyword_p, rb_vm_ep_local_ep transform_mjit_header: making declaration static inline: rb_vm_lvar_exposed, Init_vm_stack_canary, rb_vm_rewrite_cref, rb_vm_frame_block_handler, rb_vm_block_ep_update, rb_vm_ep_local_ep transform_mjit_header: SKIPPED to transform: toupper_l, tolower_l, digittoint_l, isxdigit_l, isupper_l, isspecial_l, isspace_l, isrune_l, ispunct_l, isprint_l, isphonogram_l, isnumber_l, islower_l, isideogram_l, ishexnumber_l, isgraph_l, isdigit_l, iscntrl_l, isblank_l, isalpha_l, isalnum_l, __sbistype_l, __sbmaskrune_l ln -sf ../../../.ext/include/x86_64-freebsd12.1/rb_mjit_min_header-3.0.0.h include/ruby-3.0.0/x86_64-freebsd12.1/rb_mjit_min_header-3.0.0.h ./revision.h unchanged generating encdb.h encdb.h updated generating enc.mk making srcs under enc generating transdb.h transdb.h updated compiling dln.c compiling localeinit.c creating verconf.h verconf.h updated compiling loadpath.c builtin_binary.inc updated compiling builtin.c generating a glommed object with DTrace probes for static library ld: error: attempted static link of dynamic object /usr/lib/libgcc_s.so ld: error: attempted static link of dynamic object /usr/lib/libgcc_s.so clang: error: linker command failed with exit code 1 (use -v to see invocation) *** Error code 1 Stop. make: stopped in /usr0/tmp/ruby-3.0.0-preview1 ``` また FreeBSD 11.4-RELEASE amd64では、以下のような少し違った結果となります。 ``` building .ext/include/x86_64-freebsd11.4/rb_mjit_min_header-3.0.0.h ./miniruby -I./lib -I. -I.ext/common ./tool/transform_mjit_header.rb "clang -fdeclspec -O3 -ggdb3 -Wall -Wextra -Werror=deprecated-declarations -Werror=division-by-zero -Werror=implicit-function-declaration -Werror=implicit-int -Werror=misleading-indentation -Werror=pointer-arith -Werror=shorten-64-to-32 -Werror=write-strings -Wmissing-noreturn -Wno-constant-logical-operand -Wno-long-long -Wno-missing-field-initializers -Wno-overlength-strings -Wno-parentheses-equality -Wno-self-assign -Wno-tautological-compare -Wno-unused-parameter -Wno-unused-value -Wunused-variable -Werror=extra-tokens -std=gnu99 " rb_mjit_header.h .ext/include/x86_64-freebsd11.4/rb_mjit_min_header-3.0.0.h transform_mjit_header: making external definition static inline: rb_vm_lvar_exposed, Init_vm_stack_canary, rb_vm_opt_cfunc_p, rb_find_defined_class_by_owner, rb_vm_rewrite_cref, rb_vm_block_ep_update, rb_vm_cref_new_toplevel, rb_vm_frame_block_handler, rb_vm_cframe_keyword_p, rb_vm_ep_local_ep transform_mjit_header: making declaration static inline: rb_vm_lvar_exposed, Init_vm_stack_canary, rb_vm_rewrite_cref, rb_vm_frame_block_handler, rb_vm_block_ep_update, rb_vm_ep_local_ep transform_mjit_header: SKIPPED to transform: toupper_l, tolower_l, digittoint_l, isxdigit_l, isupper_l, isspecial_l, isspace_l, isrune_l, ispunct_l, isprint_l, isphonogram_l, isnumber_l, islower_l, isideogram_l, ishexnumber_l, isgraph_l, isdigit_l, iscntrl_l, isblank_l, isalpha_l, isalnum_l, __sbistype_l, __sbmaskrune_l ln -sf ../../../.ext/include/x86_64-freebsd11.4/rb_mjit_min_header-3.0.0.h include/ruby-3.0.0/x86_64-freebsd11.4/rb_mjit_min_header-3.0.0.h ./revision.h unchanged generating encdb.h encdb.h updated generating enc.mk making srcs under enc generating transdb.h transdb.h updated compiling dln.c compiling localeinit.c creating verconf.h verconf.h updated compiling loadpath.c builtin_binary.inc updated compiling builtin.c generating a glommed object with DTrace probes for static library /usr/bin/ld: cannot find -lgcc_s clang: error: linker command failed with exit code 1 (use -v to see invocation) *** Error code 1 Stop. make: stopped in /usr0/tmp/ruby-3.0.0-preview1 ``` 念のためOSをクリーンインストールしてbase system以外のアプリケーションやライブラリが一切インストールされていない状況で試してみましたが、結果は同じでした。 -- https://bugs.ruby-lang.org/