Cannot find lmgp

64 views
Skip to first unread message

Francesco

unread,
Jun 10, 2017, 1:56:58 PM6/10/17
to RubyInstaller
I try to install json but i get the error "cannot find -lgmp in ld.exe". I have already tried and read everything about the same error on internet but i couldn't find the right answer. I have to say that i am on windows and i think that i installed correclty the gmp library.

Windows 10
ruby 2.4.1p111
gem version 2.3.0
The problem occures when i do the following command: gem install json --platform=ruby

And here is the cmd:

C:\DevKit-mingw64-64-4.7.2-20130224-1432-sfx>gem install json --platform=ruby
Temporarily enhancing PATH for MSYS/MINGW...
Building native extensions.  This could take a while...
ERROR:  Error installing json:
    ERROR: Failed to build gem native extension.

C:/Ruby24-x64/bin/ruby.exe extconf.rb
creating Makefile

make "DESTDIR=" clean

make "DESTDIR="
generating generator-x64-mingw32.def
compiling generator.c
linking shared-object json/ext/generator.so
c:/devkit-mingw64-64-4.7.2-20130224-1432-sfx/mingw/bin/../lib/gcc/x86_64-w64-mingw32/4.7.2/../../../../x86_64-w64-mingw32/bin/ld.exe: cannot find -lgmp
collect2.exe: error: ld returned 1 exit status
make: *** [generator.so] Error 1

make failed, exit code 2

Gem files will remain installed in C:/Ruby24-x64/lib/ruby/gems/2.4.0/gems/json-2.1.0 for inspection.
Results logged to C:/Ruby24-x64/lib/ruby/gems/2.4.0/extensions/x64-mingw32/2.4.0/json-2.1.0/gem_make.out



Reply all
Reply to author
Forward
0 new messages