Fix define_method for Ruby 1.9.x

Signed-off-by: Ken Barber <ken@bob.sh>