On the offchance it helps, I found an old config file from MySQL from a defunct Java project where I had similar problems. You need to specify utf8 for both the database and client connections. Here are the relevant parts from my old my.cnf:
I guess you don't need telling that changing the platform encodings won't 'fix' problems in existing data? You'll almost certainly have to empty your tables and repopulate them after an encoding change.