question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Bundle install fails on CircleCI for mini_racer 0.6.0

See original GitHub issue

When running the bundle install command on CircleCI with mini_racer 0.6.0 in the Gemfile, the build fails. This did not occur with mini_racer 0.3.1. Output:

Installing libv8-node 16.10.0.0 (x86_64-linux-musl)
Fetching mini_racer 0.6.0
Installing mini_racer 0.6.0 with native extensions
Gem::Ext::BuildError: ERROR: Failed to build gem native extension.

current directory:
/home/circleci/project/vendor/bundle/ruby/3.0.0/gems/mini_racer-0.6.0/ext/mini_racer_extension
/usr/local/bin/ruby -I /usr/local/lib/ruby/3.0.0 -r
./siteconf20220110-93-zv602o.rb extconf.rb
checking for -lpthread... yes
creating Makefile

current directory:
/home/circleci/project/vendor/bundle/ruby/3.0.0/gems/mini_racer-0.6.0/ext/mini_racer_extension
make DESTDIR\= clean

current directory:
/home/circleci/project/vendor/bundle/ruby/3.0.0/gems/mini_racer-0.6.0/ext/mini_racer_extension
make DESTDIR\=
compiling mini_racer_extension.cc
linking shared-object mini_racer_extension.so
g++: error:
/home/circleci/project/vendor/bundle/ruby/3.0.0/gems/libv8-node-16.10.0.0-x86_64-linux-musl/vendor/v8/x86_64-linux/libv8/obj/libv8_monolith.a:
No such file or directory
make: *** [Makefile:262: mini_racer_extension.so] Error 1

make failed, exit code 2

Gem files will remain installed in
/home/circleci/project/vendor/bundle/ruby/3.0.0/gems/mini_racer-0.6.0 for
inspection.
Results logged to
/home/circleci/project/vendor/bundle/ruby/3.0.0/extensions/x86_64-linux/3.0.0/mini_racer-0.6.0/gem_make.out

An error occurred while installing mini_racer (0.6.0), and Bundler
cannot continue.
Make sure that `gem install mini_racer -v '0.6.0' --source
'https://rubygems.org/'` succeeds before bundling.

In Gemfile:
  mini_racer

Exited with code exit status 5
CircleCI received exit code 5

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:11 (1 by maintainers)

github_iconTop GitHub Comments

8reactions
chrisalleycommented, Jan 18, 2022

Solved with:

bundle lock --add-platform aarch64-linux
bundle lock --add-platform x86_64-linux

In Gemfile:

gem 'mini_racer', '~> 0.6.2'

In Dockerfile:

FROM ruby:3.0.3
...
RUN gem install bundler --version=2.3.5
RUN bundle install

Only aarch64-linux was required as an added platform for CircleCI to succeed in installing mini_racer, but another gem (ransack) failed to install without x86_64-linux being added also.

3reactions
tisbacommented, Jan 17, 2022

If you are running into this issue, please make sure to update bundler (currently 2.3.5) and check if the platform you’re running on is properly set in Gemfile.lock (via bundle lock --add-platform aarch64-linux).

mini_racer 0.6.2 should work fine with Ruby 2.6.9, 2.7.5, 3.0.x and 3.1.0 (I tested a lot of those combination across x86 and aarch64 recently). Especially with the recent 0.6.2 the last issues with pre Ruby 3 environments got fixed.

@mdh: awesome 👍 @justinsnair, @cmoad: Could you try with mini_racer 0.6.2?

Read more comments on GitHub >

github_iconTop Results From Across the Web

Bundle install fails only in CircleCI(mysql2) - Stack Overflow
I modified the config.yml as follows and was able to build steps: - checkout: path: ~/myapp - run: name: default mysql client install...
Read more >
Error with installing bundler - Feedback & Bug Reports
I've tried clearing the caches and re-running, and the problem is persisting. Builds were previously running with the same circle ci ...
Read more >
Latest Bundler fails to be used even when explicitly installed
I am running into issues when attempting to use latest bundler (2.1.4) with docker. Even when checking bundler's version I get errors: #!...
Read more >
Bundler fails to find appropriate version, despite installing ...
We set bundler to a fixed version (1.10.6) on CircleCI. We have a block in circle.yml as follows to set up that dependency:...
Read more >
`bundle install` stopped working today in 2.0 using circleci ...
bundle install stopped working today. The fix we did was to upgrade bundler version to 1.16, cos 1.15 which is available was casing...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found