da Bee <redmine / ruby-lang.org> wrote:
> HQ:simple_cms rich$ rails g controller demo index
> /Users/rich/.rvm/gems/ruby-1.9.2-p290/gems/mysql2-0.3.7/lib/mysql2/mysql2.bundle: [BUG] Segmentation fault
> ruby 1.9.2p290 (2011-07-09 revision 32553) [x86_64-darwin10.8.0]
> 
> -- control frame ----------
> c:0022 p:-542184014 s:0065 b:0065 l:000064 d:000064 TOP   
> c:0021 p:---- s:0063 b:0063 l:000062 d:000062 CFUNC  :require

I cannot reproduce this on Linux x86_64 with mysql2 0.3.7 and rails 3.1.0.

Can you check if the MySQL client library used by mysql2 is linked to
OpenSSL, and if so, is it linked to the same version/installation
of OpenSSL as the Ruby "openssl" extension?

On GNU/Linux, this would be done with the ldd command on the ".so"
files, but you might have different-but-equivalent commands on
Darwin/OSX.