Skip to content

Brew grem install fails on fresh environements #618

@jeffsec-aws

Description

@jeffsec-aws

Tested on both WSL Linux and Cloud9:

Admin-OneClick:~/environment $ brew gem install cfn-nag
==> Fetching gem-cfn-nag
==> Fetching cfn-nag from gem source
Fetching cfn-nag-0.8.10.gem
Downloaded cfn-nag-0.8.10
Warning: Cannot verify integrity of 'cfn-nag-0.8.10.gem'.
No checksum was provided.
For your reference, the checksum is:
  sha256 "052aea03f2cd92ff34ea51a2e8fe287b4489dc4c57f04d1ca6e5855fe325d333"
==> /home/linuxbrew/.linuxbrew/opt/ruby/bin/gem install /home/ec2-user/.cache/Homebrew/cfn-nag-0.8.10.gem --no-document --no-wrapper --no-user-install --install-dir /home/linuxbrew/.linuxbrew/Cellar/gem-c
Last 15 lines from /home/ec2-user/.cache/Homebrew/Logs/gem-cfn-nag/01.gem:
        from /home/linuxbrew/.linuxbrew/Cellar/ruby/3.2.2/lib/ruby/3.2.0/mkmf.rb:1209:in `find_header'
        from extconf.rb:10:in `<main>'

To see why this extension failed to compile, please check the mkmf.log which can be found here:

  /home/linuxbrew/.linuxbrew/Cellar/gem-cfn-nag/0.8.10/extensions/x86_64-linux/3.2.0/psych-3.3.4/mkmf.log

extconf failed, exit code 1

Gem files will remain installed in /home/linuxbrew/.linuxbrew/Cellar/gem-cfn-nag/0.8.10/gems/psych-3.3.4 for inspection.
Results logged to /home/linuxbrew/.linuxbrew/Cellar/gem-cfn-nag/0.8.10/extensions/x86_64-linux/3.2.0/psych-3.3.4/gem_make.out

A new release of RubyGems is available: 3.4.10 → 3.4.13!
Run `gem update --system 3.4.13` to update your installation.


Do not report this issue to Homebrew/brew or Homebrew/homebrew-core!

Admin-OneClick:~/environment $ 

On Cloud9 there is even a log at /home/linuxbrew/.linuxbrew/Cellar/gem-cfn-nag/0.8.10/extensions/x86_64-linux/3.2.0/psych-3.3.4/mkmf.log.

On WSL it gives:

~$ cat /home/linuxbrew/.linuxbrew/lib/ruby/gems/3.2.0/extensions/x86_64-linux/3.2.0/psych-3.3.4/mkmf.log
LD_LIBRARY_PATH=.:/home/linuxbrew/.linuxbrew/Cellar/ruby/3.2.2/lib "gcc-11 -o conftest -I/home/linuxbrew/.linuxbrew/Cellar/ruby/3.2.2/include/ruby-3.2.0/x86_64-linux -I/home/linuxbrew/.linuxbrew/Cellar/ruby/3.2.2/include/ruby-3.2.0/ruby/backward -I/home/linuxbrew/.linuxbrew/Cellar/ruby/3.2.2/include/ruby-3.2.0 -I. -I/home/linuxbrew/.linuxbrew/opt/libyaml/include -I/home/linuxbrew/.linuxbrew/opt/openssl@1.1/include -I/home/linuxbrew/.linuxbrew/opt/readline/include   -O3 -fno-fast-math -ggdb3 -Wall -Wextra -Wdeprecated-declarations -Wdiv-by-zero -Wduplicated-cond -Wimplicit-function-declaration -Wimplicit-int -Wmisleading-indentation -Wpointer-arith -Wwrite-strings -Wold-style-definition -Wimplicit-fallthrough=0 -Wmissing-noreturn -Wno-cast-function-type -Wno-constant-logical-operand -Wno-long-long -Wno-missing-field-initializers -Wno-overlength-strings -Wno-packed-bitfield-compat -Wno-parentheses-equality -Wno-self-assign -Wno-tautological-compare -Wno-unused-parameter -Wno-unused-value -Wsuggest-attribute=format -Wsuggest-attribute=noreturn -Wunused-variable -Wundef  -fPIC conftest.c  -L. -L/home/linuxbrew/.linuxbrew/Cellar/ruby/3.2.2/lib -Wl,-rpath,/home/linuxbrew/.linuxbrew/Cellar/ruby/3.2.2/lib -L/home/linuxbrew/.linuxbrew/opt/libyaml/lib -Wl,-rpath,/home/linuxbrew/.linuxbrew/opt/libyaml/lib -L/home/linuxbrew/.linuxbrew/opt/openssl@1.1/lib -Wl,-rpath,/home/linuxbrew/.linuxbrew/opt/openssl@1.1/lib -L/home/linuxbrew/.linuxbrew/opt/readline/lib -Wl,-rpath,/home/linuxbrew/.linuxbrew/opt/readline/lib -L. -fstack-protector-strong -L/home/linuxbrew/.linuxbrew/opt/libyaml/lib  -Wl,-rpath,/home/linuxbrew/.linuxbrew/opt/libyaml/lib -L/home/linuxbrew/.linuxbrew/opt/openssl@1.1/lib  -Wl,-rpath,/home/linuxbrew/.linuxbrew/opt/openssl@1.1/lib -L/home/linuxbrew/.linuxbrew/opt/readline/lib  -Wl,-rpath,/home/linuxbrew/.linuxbrew/opt/readline/lib -rdynamic -Wl,-export-dynamic -Wl,--no-as-needed     -Wl,-rpath,/home/linuxbrew/.linuxbrew/Cellar/ruby/3.2.2/lib -L/home/linuxbrew/.linuxbrew/Cellar/ruby/3.2.2/lib -lruby  -lm -lpthread  -lc"
checked program was:
/* begin */
1: #include "ruby.h"
2:
3: int main(int argc, char **argv)
4: {
5:   return !!argv[argc];
6: }
/* end */

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions