Fix unused variable warning in Ruby wrappers when using gcc -Wall
Fix gcc -Waddress warning in variables examples
Fix some gcc -Wall unused warnings in the Ruby wrappers

Fixes SF bug 1333.