Error Installing Sqlite3 Ruby Mac
here for a quick overview of the site Help Center Detailed answers to any questions you might have Meta Discuss the workings and policies of this site About Us Learn more about Stack Overflow the company Business install sqlite3 mac Learn more about hiring developers or posting ads with us Stack Overflow Questions Jobs Documentation sqlite3 gem Tags Users Badges Ask Question x Dismiss Join the Stack Overflow Community Stack Overflow is a community of 4.7 million programmers, just like you, helping each other. Join them; it only takes a minute: Sign up Install sqlite3 on mac osx? up vote 4 down vote favorite 1 I just bought a new MBP I've read online Sqlite3 already exists on OSX. I've downloaded mac ports (and installed it) as well as the bin file for sqlite3 from the official web site. In a guide I'm reading about rails, which tells me to update sqlite3, I run the following in terminal: sudo port upgrade sqlite3 I receive the following error: Error: sqlite3 is not installed I am so lost! Please help ruby-on-rails ruby osx sqlite3 share|improve this question edited Jul 17 '09 at 15:31 Simone Carletti 122k23250297 asked Jul 17 '09 at 14:54 Elliot 5,2352162105 add a comment| 4 Answers 4 active oldest votes up vote 2 down vote accepted It's not installed via mac ports, so port doesn't know about it. You could either do an install via port or get rails to use the one that's installed on the Mac already. share|improve this answer answered Jul 17 '09 at 14:56 Lou Franco 62.6k1096150 sorry, but I am an extreme newb, how can I go about doing that? –Elliot Jul 17 '09 at 14:59 sudo port install sqlite3 seems to be doing it :) –Elliot Jul 17 '09 at 15:00 add a comment| up vote 7 down vote I don't remember the default configuration, but like you i installed sqlite myself. You can check your sqlite installation is complete by typing using the which command in the OS X terminal: $ which sqlite3 /opt/local/bin/sqlite3 If which doesn't reveal anything, then sqlite3 isn't in your system's PATH. Use the cat command to see how that's set up (in your /etc/profile file;) $ cat /etc/profile # System-wide .profile for sh(1) if [ -x /usr/libexec/path_helper ]; then eval `/usr/libexec/path_helper -s` fi if [ "${BASH-no}" != "no" ]; then [ -r /etc/bashrc ] && . /etc/bashrc fi export PATH="/usr/local/bin:/usr/local/sbin:$PATH" export PATH="/usr/local/mysql/bin:$PATH" export PATH="/opt/svn/subversion-1.4.3/bin:$PATH" export PATH="/opt/ruby/bin:$PATH" export PATH="/opt/sqlite/
here for a quick overview of the site Help Center Detailed answers to any questions you might have Meta Discuss the workings and policies of this site About Us Learn more about Stack Overflow the company Business Learn more about hiring developers or posting ads with us Stack Overflow Questions Jobs Documentation Tags Users Badges Ask Question http://stackoverflow.com/questions/1143776/install-sqlite3-on-mac-osx x Dismiss Join the Stack Overflow Community Stack Overflow is a community of 4.7 million programmers, just like you, helping each other. Join them; it only takes a minute: Sign up sqlite3 gem fails to install up vote 16 down vote favorite 7 I'm trying to install http://stackoverflow.com/questions/5025680/sqlite3-gem-fails-to-install the "sqlite3-ruby" gem (or the "sqlite3" gem) on OS X 10.6. I'm using ruby-1.9.2 and I currently get the following: $ sqlite3 --version 3.7.4 $ sudo gem install sqlite3 Building native extensions. This could take a while... ERROR: Error installing sqlite3-ruby: ERROR: Failed to build gem native extension. /Users/folken/.rvm/rubies/ruby-1.9.2-head/bin/ruby extconf.rb checking for sqlite3.h... *** 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=/Users/folken/.rvm/rubies/ruby-1.9.2-head/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}/lib /Users/folken/.rvm/rubies/ruby-1.9.2-head/lib/ruby/1.9.1/mkmf.rb:368:in `try_do': The complier failed to generate an executable file. (RuntimeError) You have to install development tools first. from /Users/folken/.rvm/rubies/ruby-1.9.2-head/lib/ruby/1.9.1/mkmf.rb:452:in `try_cpp' from /Users/folken/.rvm/rubies/ruby-1.9.2-head/lib/ruby/1.9.1/mkmf.rb:853:in `block in find_header' from /Users/folken/.rvm/rubies/ruby-1.9.2-head/lib/ruby/1.9.1/mkmf.rb:693:in `block in checking_for' from /Users/folken/.rvm/rubies/ruby-1.9.2-head/lib/ruby/1.9.1/mkmf.rb:280:in `block (2 levels) i
here for a quick overview of the site Help Center Detailed answers to any questions you might have Meta Discuss the workings and policies of this site About Us Learn more about Stack http://stackoverflow.com/questions/8424675/installing-sqlite3-gem-error Overflow the company Business Learn more about hiring developers or posting ads with us Stack Overflow Questions Jobs Documentation Tags Users Badges Ask Question x Dismiss Join the Stack Overflow Community Stack Overflow is a community http://www.heatware.net/ruby-rails/solved-installing-sqlite3-ruby-gem-extconf-rb-mkmf-loaderror/ of 4.7 million programmers, just like you, helping each other. Join them; it only takes a minute: Sign up Installing Sqlite3 Gem Error up vote 5 down vote favorite 1 I'm getting the following error when error installing trying to install the Sqlite3 gem on OS X Lion with XCode 4.2 installed: $ gem install sqlite3 Building native extensions. This could take a while... ERROR: Error installing sqlite3: ERROR: Failed to build gem native extension. /Users/me/.rvm/rubies/ruby-1.9.3-p0/bin/ruby extconf.rb checking for sqlite3.h... yes checking for sqlite3_libversion_number() in -lsqlite3... yes checking for rb_proc_arity()... yes checking for sqlite3_initialize()... yes checking for sqlite3_backup_init()... yes checking for sqlite3_column_database_name()... no checking for sqlite3_enable_load_extension()... yes checking for error installing sqlite3 sqlite3_load_extension()... yes creating Makefile make compiling backup.c make: /usr/bin/gcc-4.2: No such file or directory make: *** [backup.o] Error 1 Would linking to /usr/bin/llvm-gcc-4.2 be the only fix (seems a little hack-y)? Or am I missing something? osx sqlite3 gem share|improve this question asked Dec 8 '11 at 0:32 Bullines 2,99053778 Could you do a which gcc-4.2 and a which llvm-gcc-4.2 please? –Alex Dec 8 '11 at 0:41 Alex: which gcc-4.2 yields nothing, and which llvm-gcc-4.2 results in /usr/bin/llvm-gcc-4.2. –Bullines Dec 8 '11 at 1:05 add a comment| 1 Answer 1 active oldest votes up vote 15 down vote accepted It would appear that XCode 4.2 doesn't install gcc-4.2, but instead llvm-gcc-4.2. Clearly Apple feels that LLVM is mature enough to superseed GCC. There are two options I can think of. You should be able to choose either and be OK. Use this GCC installer. Symlink LLVM using sudo ln -s /usr/bin/llvm-gcc-4.2 /usr/bin/gcc-4.2. share|improve this answer answered Dec 8 '11 at 1:29 Alex 7,21712439 I figured that I'd have to symlink. I considered installing GCC, but it seemed redundant with XCode already installed. Thanks. –Bullines Dec 8 '11 at 2:35 add a comment| Your Answer draft saved draft discarded Sign up or log in Sign up
Assurance (QA) Software - General Software Help Databases Cool Websites Other Deals & Bargains News Video Games Hardware Electronics About 13 comments / February 5, 2011 / sood / Programming - Ruby/Rails Solved! Installing sqlite3-ruby gem - extconf.rb mkmf LoadError Are you attempting to install the sqlite3-ruby gem and you are receiving this error? Building native extensions. This could take a while... ERROR: Error installing sqlite3-ruby: ERROR: Failed to build gem native extension. /usr/bin/ruby1.8 extconf.rb extconf.rb:3:in `require': no such file to load -- mkmf (LoadError) from extconf.rb:3 Gem files will remain installed in /usr/lib/ruby/gems/1.8/gems/sqlite3-1.3.3 for inspection. Results logged to /usr/lib/ruby/gems/1.8/gems/sqlite3-1.3.3/ext/sqlite3/gem_make.out Well, we have the solution for you. Your Linux installation requires that the development libraries for SQLite3 to be installed in order to build the gem. Here is the proper way for install this gem: How to install sqlite3-ruby gem sudo apt-get install sqlite3
sudo apt-get install libsqlite3-dev
sudo gem install sqlite3-ruby If you are still having trouble…. Try installing the development package of Ruby 1.8 by using the command below, and then attempt to install Sqlite3: sudo apt-get install ruby1.8-dev Related Posts Solved! Installing mysql gem - extconf.rb failed error Fetch error installing Java on Ubuntu 11.04. Solved! How to install RubyGems on Linux (Ubuntu & Other) How to install Ruby 1.8.7 on CentOS 5.5 Linux Codeigniter 2.0: How to Download & Install 13 comments… add one Matt March 23, 2011, 8:23 am After running the commands you suggest, I am still getting the same error when I try to install the Ruby gem. Any ideas what else I could be missing? Matt March 23, 2011, 8:35 am Figured it out! After searching around to uncover why it was failing to load ‘mkmf', I found that I needed to install the ruby1.8-dev package: sudo apt-get install ruby1.8-dev Kudos goes to: http://mentalized.net/journal/2006/01/24/no_such_file_to_load_mkmf/ Justin Clark-Casey April 25, 2011, 2:35 pm Thanks a lot sood and Matt - that fixed this issue for me on Ubuntu 10.10 without having to hunt over the interwebs. sood April 25, 2011, 10:38 pm Justin, Glad to hear that this post was helpful. I have updated it to include what Matt mentioned. Martin May 18, 2011, 9:08 am Thanks, I really apprecia