SqLite3 LoadError: incompatible library version
<p>OS: Ubuntu 16, Rails 4, Ruby 2.1.2
error: <br></p>

<pre><code>LoadError: incompatible library version - /home/user/.rvm/gems/ruby-2.1.2@recipe_box/gems/sqlite3-1.3.11/lib/sqlite3/sqlite3_native.so
/home/user/.rvm/gems/ruby-2.1.2@recipe_box/gems/sqlite3-1.3.11/lib/sqlite3.rb:6:in `require'
/home/user/.rvm/gems/ruby-2.1.2@recipe_box/gems/sqlite3-1.3.11/lib/sqlite3.rb:6:in `rescue in &lt;top (required)&gt;'
/home/user/.rvm/gems/ruby-2.1.2@recipe_box/gems/sqlite3-1.3.11/lib/sqlite3.rb:2:in `&lt;top (required)&gt;'
/home/user/work/cookbook/config/application.rb:7:in `&lt;top (required)&gt;'
/home/user/work/cookbook/Rakefile:4:in `&lt;top (required)&gt;'
LoadError: cannot load such file -- sqlite3/2.3/sqlite3_native
/home/user/.rvm/gems/ruby-2.1.2@recipe_box/gems/sqlite3-1.3.11/lib/sqlite3.rb:4:in `require'
/home/user/.rvm/gems/ruby-2.1.2@recipe_box/gems/sqlite3-1.3.11/lib/sqlite3.rb:4:in `&lt;top (required)&gt;'
/home/user/work/cookbook/config/application.rb:7:in `&lt;top (required)&gt;'
/home/user/work/cookbook/Rakefile:4:in `&lt;top (required)&gt;'
</code></pre>

<p>Gemfile: <br></p>

<pre><code>gem 'rails', '4.2.5.1'
gem 'sqlite3'
</code></pre>

<p>Gemfile.lock</p>

<pre><code>sqlite3 (1.3.11)
</code></pre>

<p>when i change file sqlite3-1.3.11.gemspec
at <code>s.require_paths = ["lib"]</code><br> to <code>s.require_paths= ["lib/sqlite3_native"]</code>  i have the same problem with another gems (about 10) like <a href="https://stackoverflow.com/questions/17643897/cannot-load-such-file-sqlite3-sqlite3-native-loaderror-on-ruby-on-rails">here</a> <br>
<a href="https://stackoverflow.com/questions/36963018/error-incompatible-library-version-sqlite3-1-3-11-in-rails">reinstall</a> gem not working <br><br><br>
what need to do to solve the problem?</p>