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:

http://gembundler.com/rationale.html#faq-4

$ bundle config build.oniguruma \
    --with-opt-dir=/Users/jgoebel/.brew/
$ bundle install

Done.