Eruby-mysql-already initialized constant

Hi. I am getting a pile of “already initialized constant” errors when
trying to use eruby.

They look like this:
/usr/lib/ruby/site_ruby/1.6/DBD/Mysql/Mysql.rb:33: warning: already
initialized constant CR_MIN_ERROR
/usr/lib/ruby/site_ruby/1.6/DBD/Mysql/Mysql.rb:33: warning: already
initialized constant CR_MAX_ERROR

There are many more of them…

Here’s where the problem arises–if I try to access my rhtml page, it gives
me a server error.
If I run “eruby testfile.rhtml” and then cut/paste the resulting output
from the console to a new file and load it in a browser, it works fine.

So, I suspect that all those errors are being output to the browser before
the relevant HTML doctype, etc. (I could be wrong…)

This doesn’t happen the first time I start Apache and load an rhtml
page–it only happens later, after I edit a page and try to reload it.

Any ideas on why these errors are occurring? Any suggestions on how to fix
them short of redirecting STDERR in every one of my pages?

I’m using Ruby 1.6.6, mod_ruby-1.0, eruby-0.9.8 and mysql-ruby-2.4.3 on
linux. (Mandrake 8.2) Could this have been caused by compiling these in the
wrong order? What order is it supposed to happen in?

Thanks,
Jason