0

I have been searching a lot and unable to find the exact solution to my problem.

I have installed ruby c extension on ruby 2.2 and it works fine. when I have updated my ruby to 2.6.5 it fails saying that .so file is not found

Error:- in ruby 2.6.5

irb(main):001:0> require 'ibm_db'
Traceback (most recent call last):
       13: from C:/Ruby26/bin/irb.cmd:31:in `<main>'
       12: from C:/Ruby26/bin/irb.cmd:31:in `load'
       11: from C:/Ruby26/lib/ruby/gems/2.6.0/gems/irb-1.0.0/exe/irb:11:in `<top (required)>'
       10: from (irb):1
        9: from C:/Ruby26/lib/ruby/2.6.0/rubygems/core_ext/kernel_require.rb:34:in `require'
        8: from C:/Ruby26/lib/ruby/2.6.0/rubygems/core_ext/kernel_require.rb:130:in `rescue in require'
        7: from C:/Ruby26/lib/ruby/2.6.0/rubygems/core_ext/kernel_require.rb:130:in `require'
        6: from C:/Ruby26/lib/ruby/gems/2.6.0/gems/ibm_db-4.0.0-x86-mingw32/lib/ibm_db.rb:21:in `<top (required)>'
        5: from C:/Ruby26/lib/ruby/2.6.0/rubygems/core_ext/kernel_require.rb:54:in `require'
        4: from C:/Ruby26/lib/ruby/2.6.0/rubygems/core_ext/kernel_require.rb:54:in `require'
        3: from C:/Ruby26/lib/ruby/gems/2.6.0/gems/ibm_db-4.0.0-x86-mingw32/lib/mswin32/ibm_db.rb:90:in `<top (required)>'
        2: from C:/Ruby26/lib/ruby/2.6.0/rubygems/core_ext/kernel_require.rb:54:in `require'
        1: from C:/Ruby26/lib/ruby/2.6.0/rubygems/core_ext/kernel_require.rb:54:in `require'
LoadError (126: The specified module could not be found.   - C:/Ruby26/lib/ruby/gems/2.6.0/gems/ibm_db-4.0.0-x86-mingw32/lib/mswin32/rb2x/i386/ibm_db.so)
anothermh
  • 9,815
  • 3
  • 33
  • 52
akhil
  • 105
  • 10
  • how about reinstalling the gem? gem install ibm_db – Fernand Jan 21 '20 at 07:37
  • Also, if ruby 2.6 really is incompatible, the *very first thing* you should do is bisect the version number to find out where is actually beaks. `2.3.x`, `2.4.`, `2.5.x` or `2.6.x`? Which patch release? – Tom Lord Jan 21 '20 at 09:22
  • I think this might help: https://stackoverflow.com/q/56850201/10313894 – ARK Jan 21 '20 at 12:22
  • Thanks...@TomLord that helped me. Solution is wee need to add all the dependencies in RUBY_DLL_PATH (environmental variable) – akhil Jan 28 '20 at 06:22

1 Answers1

0

we need to set RUBY_DLL_PATH=clidriver/bin (environmental variable).

Thanks

akhil
  • 105
  • 10