How can I pass a parameter for gem installation when I run bundle install?
You need to set a build config option like so:
bundle config build.pg --with-pg-config=/path/to/pg_config
More info can be found in the bundle config command documentation
RVM doesn't recognize installed gem, so bundle install fails
Finally found answer: How can I pass a parameter for gem installation when I run bundle install?
So in my case:
bundle config build.pg --with-pg-include=/usr/pgsql-9.3/include --with-pg-dir=/usr/pgsql-9.3
bundle install
And that took a day, well could have been worse
Bundler installing gem that's already installed
Try running bundle env
to verify that the install location is what you expect.
If not, check whether there is a .bundle/config
or ~/.bundle/config
file overriding the install path. The output of bundle env
will tell you what configuration it is using and how it was determined (i.e., which file it was in or whether it was picked up from an environment variable).
Related Topics
In Ruby's Test::Unit::Testcase, How to Override the Initialize Method
How to Pass a Parameter for Gem Installation When I Run Bundle Install
Rails - Cannot Run App: Unable to Load the Eventmachine C Extension;
Passing Multiple Error Classes to Ruby's Rescue Clause in a Dry Fashion
Block Syntax Difference Causes "Localjumperror: No Block Given (Yield)"
How to Check for File Existence
How to List Ruby Production Only Dependencies Using Gemfile.Lock and Lockfileparser Class
How (Replace|Create) an Enum Field on Rails 2.0 Migrations
Rails - the System Cannot Find the Path Specified
Tcpserver Error: Address Already in Use - Bind(2)
Rails: Should Partials Be Aware of Instance Variables
Role Does Not Exist and Unable to Create Database When Using Postgresql
How to Use Rspec's Should_Raise with Any Kind of Exception
Trying to Set Up Postgres for Ror App, Getting Error - Fe_Sendauth: No Password Supplied
Encoding::Undefinedconversionerror
How to Remove Permission Denied @ Rb_Sysopen - Gem Install Error