Compilation issue dtoa.c - missing binary operator before token
还没有人认领这个 Issue。
评估
- 难度
- 3/5
- 预计耗时
- 1-2 天
- 新手友好度
- 55/100
- Issue 类型
- 缺陷
- 描述清晰度
- 基本清楚
- 活跃度
- 活跃
- 领域
- build-system
调研方向
Start by reproducing the failure with the Docker command in the issue, then inspect the preprocessor condition around line 214 of missing/dtoa.c, included from missing.c. Check how the condition behaves with the reported compiler and Ruby 3.0.6. Done means the gem builds and loads successfully in that environment.
由索引模型根据 Issue 内容生成。
描述
Hi there; We're just trying to compile the latest release of this gem and hitting an issue:
missing/dtoa.c:214:20: error: missing binary operator before token "("
Replication command:
docker run --rm --user jenkins --env HOME=/home/jenkins rapid7/msf-ubuntu1204-x86-omnibus:2024_04 linux32 bash -lc 'mkdir -p "$HOME/.local/share/gem/ruby/3.0.0/cache" && source /home/jenkins/.rvm/scripts/rvm && rvm use 3.0.6 && gem install bigdecimal -v 4.1.3 --platform ruby --no-document && ruby -rbigdecimal -e '\''abort unless BigDecimal::VERSION == %q(4.1.3) && BigDecimal(%q(1.25)) + BigDecimal(%q(2.75)) == 4; puts %Q(bigdecimal #{BigDecimal::VERSION}: compiled and loaded)'\'''
Error:
Using /home/jenkins/.rvm/gems/ruby-3.0.6
Building native extensions. This could take a while...
ERROR: Error installing bigdecimal:
ERROR: Failed to build gem native extension.
current directory: /home/jenkins/.rvm/gems/ruby-3.0.6/gems/bigdecimal-4.1.3/ext/bigdecimal
/home/jenkins/.rvm/rubies/ruby-3.0.6/bin/ruby -I /home/jenkins/.rvm/rubies/ruby-3.0.6/lib/ruby/3.0.0 -r ./siteconf20261103-186-cilydo.rb extconf.rb
checking for __builtin_clz()... yes
checking for __builtin_clzl()... yes
checking for __builtin_clzll()... yes
checking for float.h... yes
checking for math.h... yes
checking for stdbool.h... yes
checking for stdlib.h... yes
checking for x86intrin.h... yes
checking for _lzcnt_u32() in x86intrin.h... no
checking for _lzcnt_u64() in x86intrin.h... no
checking for intrin.h... no
checking for ruby/atomic.h... yes
checking for ruby/internal/has/builtin.h... yes
checking for ruby/internal/static_assert.h... yes
checking for rb_complex_real() in ruby.h... yes
checking for rb_complex_imag() in ruby.h... yes
checking for rb_opts_exception_p() in ruby.h... yes
checking for rb_category_warn() in ruby.h... yes
checking for RB_WARN_CATEGORY_DEPRECATED in ruby.h... yes
checking for RUBY_TYPED_EMBEDDABLE in ruby.h... no
creating Makefile
current directory: /home/jenkins/.rvm/gems/ruby-3.0.6/gems/bigdecimal-4.1.3/ext/bigdecimal
make DESTDIR\= clean
current directory: /home/jenkins/.rvm/gems/ruby-3.0.6/gems/bigdecimal-4.1.3/ext/bigdecimal
make DESTDIR\=
compiling bigdecimal.c
compiling missing.c
In file included from missing.c:28:0:
missing/dtoa.c:214:20: error: missing binary operator before token "("
cc1: warning: unrecognized command line option "-Wno-tautological-compare" [enabled by default]
cc1: warning: unrecognized command line option "-Wno-self-assign" [enabled by default]
cc1: warning: unrecognized command line option "-Wno-parentheses-equality" [enabled by default]
cc1: warning: unrecognized command line option "-Wno-constant-logical-operand" [enabled by default]
cc1: warning: unrecognized command line option "-Wno-cast-function-type" [enabled by default]
make: *** [missing.o] Error 1
make failed, exit code 2
Gem files will remain installed in /home/jenkins/.rvm/gems/ruby-3.0.6/gems/bigdecimal-4.1.3 for inspection.
Results logged to /home/jenkins/.rvm/gems/ruby-3.0.6/extensions/x86-linux/3.0.0/bigdecimal-4.1.3/gem_make.out
- 主要语言
- C
- 星标
- 152
- 派生
- 99
- 平均合并
- 6 小时 44 分钟
- 30 天内合并 PR
- 2
环境准备
这个项目没有提供开发容器、Dockerfile 或贡献指南,环境需要你自己搭建:先看它的 README,通用步骤见我们的新手贡献指南。
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
ruby/bigdecimal 的其他 Issue
-
难度 5/5 一周以上 新手友好度 35/100
ruby/bigdecimal#566 ·
-
难度 4/5 3-5 天 新手友好度 45/100
ruby/bigdecimal#506 · 4 条评论 ·
-
难度 5/5 一周以上 新手友好度 30/100
ruby/bigdecimal#491 ·
-
难度 5/5 一周以上 新手友好度 35/100
ruby/bigdecimal#444 · 1 条评论 ·
-
难度 3/5 1-2 天 新手友好度 35/100
ruby/bigdecimal#291 · 6 条评论 ·
相似的 Issue
-
难度 2/5 1-3 小时 新手友好度 72/100
containers/bubblewrap#826 ·
维护者通常 1 天内回复
-
[compiler-rt] Rtsan-aarch64-NoInstTest: error: no such file or directory: 'NOTFOUND' (libatomic)未关闭build-problem compiler-rt:rtsan platform:linux
难度 2/5 1-3 小时 新手友好度 63/100
llvm/llvm-project#239039 ·
维护者通常 1 天内回复
-
component:obi contribfest go test
难度 2/5 1 小时以内 新手友好度 83/100
open-telemetry/opentelemetry-ebpf-instrumentation#4143 · 1 条评论 ·
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 64/100
checkpoint-restore/criu#3304 ·
维护者通常 1 天内回复
-
Separate Installation Commands into Individual Code Blocks可能已有人在做 @andrySD 今天认领。 未关闭
难度 1/5 1 小时以内 新手友好度 88/100
colbymchenry/codegraph#3241 ·
维护者通常 1 天内回复