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

Issue installing yajl-ruby 1.2.1 gem file #8

Closed
Chammz opened this issue Aug 30, 2017 · 3 comments
Closed

Issue installing yajl-ruby 1.2.1 gem file #8

Chammz opened this issue Aug 30, 2017 · 3 comments

Comments

@Chammz
Copy link

Chammz commented Aug 30, 2017

Hello!

When running bundle install, it appears that yajl-ruby 1.2.1 is having some trouble being installed and prevents the bundler operation from continuing further. First time I ran this, I checked my ruby version: ruby 2.4.0p0 (2016-12-24 revision 57164) [x86_64-darwin16]. I then tried changing my version to 2.3.3 instead to see if this would change anything and still got this very long message. Any ideas?

Gem::Ext::BuildError: ERROR: Failed to build gem native extension.

    current directory: /Users/chris/.rvm/gems/ruby-2.4.0/gems/yajl-ruby-1.2.1/ext/yajl
/Users/chris/.rvm/rubies/ruby-2.4.0/bin/ruby -r ./siteconf20170829-6350-13a9klw.rb extconf.rb
creating Makefile

current directory: /Users/chris/.rvm/gems/ruby-2.4.0/gems/yajl-ruby-1.2.1/ext/yajl
make "DESTDIR=" clean

current directory: /Users/chris/.rvm/gems/ruby-2.4.0/gems/yajl-ruby-1.2.1/ext/yajl
make "DESTDIR="
compiling yajl.c
compiling yajl_alloc.c
compiling yajl_buf.c
compiling yajl_encode.c
compiling yajl_ext.c
yajl_ext.c:42:19: warning: implicit conversion loses integer precision: 'long' to 'int' [-Wshorten-64-to-32]
        int len = RARRAY_LEN(wrapper->builderStack);
            ~~~   ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/Users/chris/.rvm/rubies/ruby-2.4.0/include/ruby-2.4.0/ruby/ruby.h:1022:23: note: expanded from macro 'RARRAY_LEN'
#define RARRAY_LEN(a) rb_array_len(a)
                      ^~~~~~~~~~~~~~~
yajl_ext.c:47:19: warning: implicit conversion loses integer precision: 'long' to 'int' [-Wshorten-64-to-32]
        int len = RARRAY_LEN(wrapper->builderStack);
            ~~~   ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/Users/chris/.rvm/rubies/ruby-2.4.0/include/ruby-2.4.0/ruby/ruby.h:1022:23: note: expanded from macro 'RARRAY_LEN'
#define RARRAY_LEN(a) rb_array_len(a)
                      ^~~~~~~~~~~~~~~
yajl_ext.c:83:11: warning: implicit conversion loses integer precision: 'long' to 'int' [-Wshorten-64-to-32]
    len = RARRAY_LEN(wrapper->builderStack);
        ~ ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/Users/chris/.rvm/rubies/ruby-2.4.0/include/ruby-2.4.0/ruby/ruby.h:1022:23: note: expanded from macro 'RARRAY_LEN'
#define RARRAY_LEN(a) rb_array_len(a)
                      ^~~~~~~~~~~~~~~
yajl_ext.c:201:19: warning: implicit conversion loses integer precision: 'long' to 'unsigned int' [-Wshorten-64-to-32]
            len = RSTRING_LEN(str);
                ~ ^~~~~~~~~~~~~~~~
/Users/chris/.rvm/rubies/ruby-2.4.0/include/ruby-2.4.0/ruby/ruby.h:976:6: note: expanded from macro 'RSTRING_LEN'
     RSTRING_EMBED_LEN(str) : \
     ^~~~~~~~~~~~~~~~~~~~~~
/Users/chris/.rvm/rubies/ruby-2.4.0/include/ruby-2.4.0/ruby/ruby.h:972:6: note: expanded from macro 'RSTRING_EMBED_LEN'
     (long)((RBASIC(str)->flags >> RSTRING_EMBED_LEN_SHIFT) & \
     ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
yajl_ext.c:201:19: warning: implicit conversion loses integer precision: 'long' to 'unsigned int' [-Wshorten-64-to-32]
            len = RSTRING_LEN(str);
                ~ ^~~~~~~~~~~~~~~~
/Users/chris/.rvm/rubies/ruby-2.4.0/include/ruby-2.4.0/ruby/ruby.h:977:28: note: expanded from macro 'RSTRING_LEN'
     RSTRING(str)->as.heap.len)
     ~~~~~~~~~~~~~~~~~~~~~~^~~
yajl_ext.c:209:19: warning: implicit conversion loses integer precision: 'long' to 'unsigned int' [-Wshorten-64-to-32]
            len = RSTRING_LEN(obj);
                ~ ^~~~~~~~~~~~~~~~
/Users/chris/.rvm/rubies/ruby-2.4.0/include/ruby-2.4.0/ruby/ruby.h:976:6: note: expanded from macro 'RSTRING_LEN'
     RSTRING_EMBED_LEN(str) : \
     ^~~~~~~~~~~~~~~~~~~~~~
/Users/chris/.rvm/rubies/ruby-2.4.0/include/ruby-2.4.0/ruby/ruby.h:972:6: note: expanded from macro 'RSTRING_EMBED_LEN'
     (long)((RBASIC(str)->flags >> RSTRING_EMBED_LEN_SHIFT) & \
     ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
yajl_ext.c:209:19: warning: implicit conversion loses integer precision: 'long' to 'unsigned int' [-Wshorten-64-to-32]
            len = RSTRING_LEN(obj);
                ~ ^~~~~~~~~~~~~~~~
/Users/chris/.rvm/rubies/ruby-2.4.0/include/ruby-2.4.0/ruby/ruby.h:977:28: note: expanded from macro 'RSTRING_LEN'
     RSTRING(str)->as.heap.len)
     ~~~~~~~~~~~~~~~~~~~~~~^~~
yajl_ext.c:217:23: warning: implicit conversion loses integer precision: 'long' to 'unsigned int' [-Wshorten-64-to-32]
                len = RSTRING_LEN(str);
                    ~ ^~~~~~~~~~~~~~~~
/Users/chris/.rvm/rubies/ruby-2.4.0/include/ruby-2.4.0/ruby/ruby.h:976:6: note: expanded from macro 'RSTRING_LEN'
     RSTRING_EMBED_LEN(str) : \
     ^~~~~~~~~~~~~~~~~~~~~~
/Users/chris/.rvm/rubies/ruby-2.4.0/include/ruby-2.4.0/ruby/ruby.h:972:6: note: expanded from macro 'RSTRING_EMBED_LEN'
     (long)((RBASIC(str)->flags >> RSTRING_EMBED_LEN_SHIFT) & \
     ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
yajl_ext.c:217:23: warning: implicit conversion loses integer precision: 'long' to 'unsigned int' [-Wshorten-64-to-32]
                len = RSTRING_LEN(str);
                    ~ ^~~~~~~~~~~~~~~~
/Users/chris/.rvm/rubies/ruby-2.4.0/include/ruby-2.4.0/ruby/ruby.h:977:28: note: expanded from macro 'RSTRING_LEN'
     RSTRING(str)->as.heap.len)
     ~~~~~~~~~~~~~~~~~~~~~~^~~
yajl_ext.c:223:23: warning: implicit conversion loses integer precision: 'long' to 'unsigned int' [-Wshorten-64-to-32]
                len = RSTRING_LEN(str);
                    ~ ^~~~~~~~~~~~~~~~
/Users/chris/.rvm/rubies/ruby-2.4.0/include/ruby-2.4.0/ruby/ruby.h:976:6: note: expanded from macro 'RSTRING_LEN'
     RSTRING_EMBED_LEN(str) : \
     ^~~~~~~~~~~~~~~~~~~~~~
/Users/chris/.rvm/rubies/ruby-2.4.0/include/ruby-2.4.0/ruby/ruby.h:972:6: note: expanded from macro 'RSTRING_EMBED_LEN'
     (long)((RBASIC(str)->flags >> RSTRING_EMBED_LEN_SHIFT) & \
     ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
yajl_ext.c:223:23: warning: implicit conversion loses integer precision: 'long' to 'unsigned int' [-Wshorten-64-to-32]
                len = RSTRING_LEN(str);
                    ~ ^~~~~~~~~~~~~~~~
/Users/chris/.rvm/rubies/ruby-2.4.0/include/ruby-2.4.0/ruby/ruby.h:977:28: note: expanded from macro 'RSTRING_LEN'
     RSTRING(str)->as.heap.len)
     ~~~~~~~~~~~~~~~~~~~~~~^~~
yajl_ext.c:492:15: warning: implicit conversion loses integer precision: 'long' to 'unsigned int' [-Wshorten-64-to-32]
        len = RSTRING_LEN(input);
            ~ ^~~~~~~~~~~~~~~~~~
/Users/chris/.rvm/rubies/ruby-2.4.0/include/ruby-2.4.0/ruby/ruby.h:976:6: note: expanded from macro 'RSTRING_LEN'
     RSTRING_EMBED_LEN(str) : \
     ^~~~~~~~~~~~~~~~~~~~~~
/Users/chris/.rvm/rubies/ruby-2.4.0/include/ruby-2.4.0/ruby/ruby.h:972:6: note: expanded from macro 'RSTRING_EMBED_LEN'
     (long)((RBASIC(str)->flags >> RSTRING_EMBED_LEN_SHIFT) & \
     ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
yajl_ext.c:492:15: warning: implicit conversion loses integer precision: 'long' to 'unsigned int' [-Wshorten-64-to-32]
        len = RSTRING_LEN(input);
            ~ ^~~~~~~~~~~~~~~~~~
/Users/chris/.rvm/rubies/ruby-2.4.0/include/ruby-2.4.0/ruby/ruby.h:977:28: note: expanded from macro 'RSTRING_LEN'
     RSTRING(str)->as.heap.len)
     ~~~~~~~~~~~~~~~~~~~~~~^~~
yajl_ext.c:498:19: warning: implicit conversion loses integer precision: 'long' to 'unsigned int' [-Wshorten-64-to-32]
            len = RSTRING_LEN(parsed);
                ~ ^~~~~~~~~~~~~~~~~~~
/Users/chris/.rvm/rubies/ruby-2.4.0/include/ruby-2.4.0/ruby/ruby.h:976:6: note: expanded from macro 'RSTRING_LEN'
     RSTRING_EMBED_LEN(str) : \
     ^~~~~~~~~~~~~~~~~~~~~~
/Users/chris/.rvm/rubies/ruby-2.4.0/include/ruby-2.4.0/ruby/ruby.h:972:6: note: expanded from macro 'RSTRING_EMBED_LEN'
     (long)((RBASIC(str)->flags >> RSTRING_EMBED_LEN_SHIFT) & \
     ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
yajl_ext.c:498:19: warning: implicit conversion loses integer precision: 'long' to 'unsigned int' [-Wshorten-64-to-32]
            len = RSTRING_LEN(parsed);
                ~ ^~~~~~~~~~~~~~~~~~~
/Users/chris/.rvm/rubies/ruby-2.4.0/include/ruby-2.4.0/ruby/ruby.h:977:28: note: expanded from macro 'RSTRING_LEN'
     RSTRING(str)->as.heap.len)
     ~~~~~~~~~~~~~~~~~~~~~~^~~
yajl_ext.c:538:15: warning: implicit conversion loses integer precision: 'long' to 'unsigned int' [-Wshorten-64-to-32]
        len = RSTRING_LEN(chunk);
            ~ ^~~~~~~~~~~~~~~~~~
/Users/chris/.rvm/rubies/ruby-2.4.0/include/ruby-2.4.0/ruby/ruby.h:976:6: note: expanded from macro 'RSTRING_LEN'
     RSTRING_EMBED_LEN(str) : \
     ^~~~~~~~~~~~~~~~~~~~~~
/Users/chris/.rvm/rubies/ruby-2.4.0/include/ruby-2.4.0/ruby/ruby.h:972:6: note: expanded from macro 'RSTRING_EMBED_LEN'
     (long)((RBASIC(str)->flags >> RSTRING_EMBED_LEN_SHIFT) & \
     ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
yajl_ext.c:538:15: warning: implicit conversion loses integer precision: 'long' to 'unsigned int' [-Wshorten-64-to-32]
        len = RSTRING_LEN(chunk);
            ~ ^~~~~~~~~~~~~~~~~~
/Users/chris/.rvm/rubies/ruby-2.4.0/include/ruby-2.4.0/ruby/ruby.h:977:28: note: expanded from macro 'RSTRING_LEN'
     RSTRING(str)->as.heap.len)
     ~~~~~~~~~~~~~~~~~~~~~~^~~
yajl_ext.c:881:22: error: use of undeclared identifier 'rb_cFixnum'
    rb_define_method(rb_cFixnum, "to_json", rb_yajl_json_ext_fixnum_to_json, -1);
                     ^
17 warnings and 1 error generated.
make: *** [yajl_ext.o] Error 1

make failed, exit code 2

Gem files will remain installed in /Users/chris/.rvm/gems/ruby-2.4.0/gems/yajl-ruby-1.2.1 for inspection.
Results logged to /Users/chris/.rvm/gems/ruby-2.4.0/extensions/x86_64-darwin-16/2.4.0/yajl-ruby-1.2.1/gem_make.out

An error occurred while installing yajl-ruby (1.2.1), and Bundler cannot continue.
Make sure that `gem install yajl-ruby -v '1.2.1'` succeeds before bundling.

In Gemfile:
  jekyll was resolved to 2.5.3, which depends on
    pygments.rb was resolved to 0.6.3, which depends on
      yajl-ruby
@T2hhbmEK
Copy link

T2hhbmEK commented Oct 18, 2017

try bundle update

@erquhart
Copy link
Contributor

Any dependency related issues should be addressed as of #20 merge.

@exenin
Copy link

exenin commented Apr 29, 2019

what worked for me was to comment out yajl gem in Gemfile
rails/rails#27450

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

4 participants