Bundler and C Extensions that need special flags

Ran into this just today because my homebrew installation is in ~/.brew (which has caused me very few issues overall).  Bundle installation for Pastie was failing because the oniguruma gem couldn't find it's headers (in ~/.brew). 

The answer was present but slightly hidden on the Bundler site:


$ bundle config build.oniguruma \
$ bundle install