Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

git push heroku master: Error occurred while installing sqlite3

I'm going crazy with this problem.

I'm new in Heroku and today I was trying deploy my app, but I couldn't.I could build it once, but it gave me an "internal server error ".

Error:

When I run git push heroku master, after do the commit, it returns:

-----> Ruby app detected
-----> Compiling Ruby/Rails
-----> Using Ruby version: ruby-2.0.0
###### WARNING:
       Removing `Gemfile.lock` because it was generated on Windows.
       Bundler will do a full resolve so native gems are handled properly.
       This may result in unexpected gem versions being used in your app.
       In rare occasions Bundler may not be able to resolve your dependencies at all.
       https://devcenter.heroku.com/articles/bundler-windows-gemfile
-----> Installing dependencies using 1.7.12
       Running: bundle install --without development:test --path vendor/bundle --binstubs vendor/bundle/bin -j4
       Fetching gem metadata from https://rubygems.org/.........
       Resolving dependencies...
       Using json 1.8.2
       Using i18n 0.7.0
       ...
       Using sass-rails 5.0.3
       Using turbolinks 2.5.3
       Installing bootstrap-sass 3.2.0.2
       Gem::Installer::ExtensionBuildError: ERROR: Failed to build gem native extension.
       /tmp/build_4e3945a34652ba20ca13b13d160a9dd7/vendor/ruby-2.0.0/bin/ruby extconf.rb
       checking for sqlite3.h... no
       sqlite3.h is missing. Try 'port install sqlite3 +universal',
       'yum install sqlite-devel' or 'apt-get install libsqlite3-dev'
       and check your shared library search path (the
       location where your sqlite3 shared library is located).
       *** extconf.rb failed ***
       Could not create Makefile due to some reason, probably lack of necessary
       libraries and/or headers.  Check the mkmf.log file for more details.  You may
       need configuration options.
       Provided configuration options:
       --with-opt-dir
       --without-opt-dir
       --with-opt-include
       --without-opt-include=${opt-dir}/include
       --with-opt-lib
       --without-opt-lib=${opt-dir}/lib
       --with-make-prog
       --without-make-prog
       --srcdir=.
       --curdir
       --ruby=/tmp/build_4e3945a34652ba20ca13b13d160a9dd7/vendor/ruby-2.0.0/bin/ruby
       --with-sqlite3-dir
       --without-sqlite3-dir
       --with-sqlite3-include
       --without-sqlite3-include=${sqlite3-dir}/include
       --with-sqlite3-lib
       --without-sqlite3-lib=${sqlite3-dir}/
       Gem files will remain installed in /tmp/build_4e3945a34652ba20ca13b13d160a9dd7/vendor/bundle/ruby/2.0.0/gems/sqlite3-1.3.10 for inspection.
       Results logged to /tmp/build_4e3945a34652ba20ca13b13d160a9dd7/vendor/bundle/ruby/2.0.0/gems/sqlite3-1.3.10/ext/sqlite3/gem_make.out
       An error occurred while installing sqlite3 (1.3.10), and Bundler cannot
       continue.
       Make sure that `gem install sqlite3 -v '1.3.10'` succeeds before bundling.
       Bundler Output: Fetching gem metadata from https://rubygems.org/.........
       Resolving dependencies...
       Using json 1.8.2
       Using i18n 0.7.0
       ...
       Using sass-rails 5.0.3
       Using turbolinks 2.5.3
       Installing bootstrap-sass 3.2.0.2
       
       Gem::Installer::ExtensionBuildError: ERROR: Failed to build gem native extension.
       
       /tmp/build_4e3945a34652ba20ca13b13d160a9dd7/vendor/ruby-2.0.0/bin/ruby extconf.rb
       checking for sqlite3.h... no
       sqlite3.h is missing. Try 'port install sqlite3 +universal',
       'yum install sqlite-devel' or 'apt-get install libsqlite3-dev'
       and check your shared library search path (the
       location where your sqlite3 shared library is located).
       *** extconf.rb failed ***
       Could not create Makefile due to some reason, probably lack of necessary
       libraries and/or headers.  Check the mkmf.log file for more details.  You may
       need configuration options.
       
       Provided configuration options:
       --with-opt-dir
       --without-opt-dir
       --with-opt-include
       --without-opt-include=${opt-dir}/include
       --with-opt-lib
       --without-opt-lib=${opt-dir}/lib
       --with-make-prog
       --without-make-prog
       --srcdir=.
       --curdir
       --ruby=/tmp/build_4e3945a34652ba20ca13b13d160a9dd7/vendor/ruby-2.0.0/bin/ruby
       --with-sqlite3-dir
       --without-sqlite3-dir
       --with-sqlite3-include
       --without-sqlite3-include=${sqlite3-dir}/include
       --with-sqlite3-lib
       --without-sqlite3-lib=${sqlite3-dir}/
       
       Gem files will remain installed in /tmp/build_4e3945a34652ba20ca13b13d160a9dd7/vendor/bundle/ruby/2.0.0/gems/sqlite3-1.3.10 for inspection.
       Results logged to /tmp/build_4e3945a34652ba20ca13b13d160a9dd7/vendor/bundle/ruby/2.0.0/gems/sqlite3-1.3.10/ext/sqlite3/gem_make.out
       An error occurred while installing sqlite3 (1.3.10), and Bundler cannot
       continue.
       Make sure that `gem install sqlite3 -v '1.3.10'` succeeds before bundling.
 !
 !     Failed to install gems via Bundler.
 !     
 !     Detected sqlite3 gem which is not supported on Heroku.
 !     https://devcenter.heroku.com/articles/sqlite3
 !
 !     Push rejected, failed to compile Ruby app

Forgive me if it's a simple mistake. But it is getting me a headache.

like image 682
David Amrani Avatar asked Jul 09 '26 00:07

David Amrani


1 Answers

Resolved

Mistake: I didn't know I must commit the changes.

  1. git commit -am "comment line"
  2. git push
  3. git push heroku master

That's all. Thanks, @suslov

like image 189
David Amrani Avatar answered Jul 11 '26 15:07

David Amrani