Himanshu Prakash
2014-Jul-22 16:14 UTC
Unable to install pg gem: Could not create Makefile due to some reason
Hi All,
While installing postgres gem, getting following error-
#===== ERROR MESSAGE START ==========
Building native extensions. This could take a while...
/System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/rubygems/ext/builder.rb:54:
warning: Insecure world writable dir /usr/local in PATH, mode 040777
ERROR: Error installing pg:
ERROR: Failed to build gem native extension.
/System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/bin/ruby
extconf.rb
checking for pg_config... yes
Using config values from /usr/local/bin/pg_config
checking for libpq-fe.h... yes
checking for libpq/libpq-fs.h... yes
checking for pg_config_manual.h... yes
checking for PQconnectdb() in -lpq... no
checking for PQconnectdb() in -llibpq... no
checking for PQconnectdb() in -lms/libpq... no
Can't find the PostgreSQL client library (libpq)
*** 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=/System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/bin/ruby
--with-pg
--without-pg
--with-pg-config
--without-pg-config
--with-pg_config
--without-pg_config
--with-pg-dir
--without-pg-dir
--with-pg-include
--without-pg-include=${pg-dir}/include
--with-pg-lib
--without-pg-lib=${pg-dir}/
--with-pqlib
--without-pqlib
--with-libpqlib
--without-libpqlib
--with-ms/libpqlib
--without-ms/libpqlib
Gem files will remain installed in
/Users/apple/.rvm/gems/ruby-2.1.2@learning/gems/pg-0.17.1 for inspection.
Results logged to /Users/apple/.rvm/gems/ruby-2.1.2@learning
/gems/pg-0.17.1/ext/gem_make.out
#===== ERROR MESSAGE END ==========
Googled a lot, but could not found any working solution. Could anyone
please suggest what should be the resolution?
Here is my gem environment-
#=========== GEM ENVIRONMENT START =================
RubyGems Environment:
- RUBYGEMS VERSION: 2.0.14
- RUBY VERSION: 2.0.0 (2014-02-24 patchlevel 451)
[universal.x86_64-darwin13]
- INSTALLATION DIRECTORY: /Users/apple/.rvm/gems/ruby-2.1.2@learning
- RUBY EXECUTABLE:
/System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/bin/ruby
- EXECUTABLE DIRECTORY: /Users/apple/.rvm/gems/ruby-2.1.2@learning/bin
- RUBYGEMS PLATFORMS:
- ruby
- universal-darwin-13
- GEM PATHS:
- /Users/apple/.rvm/gems/ruby-2.1.2@learning
- /Users/apple/.rvm/gems/ruby-2.1.2@global
- GEM CONFIGURATION:
- :update_sources => true
- :verbose => true
- :backtrace => false
- :bulk_threshold => 1000
- REMOTE SOURCES:
- https://rubygems.org/
#=========== GEM ENVIRONMENT END =================
I am using OS X 10.9.4
I appreciate any help..
Thanks,
Himanshu Prakash
--
You received this message because you are subscribed to the Google Groups
"Ruby on Rails: Talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to
rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
To post to this group, send email to
rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
To view this discussion on the web visit
https://groups.google.com/d/msgid/rubyonrails-talk/CANQThmuzCg4Scu4S_cSL%2BBRcHLzOg6LVTgPeuRpGKx0RAReHPQ%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.