Build warnings

Most build warnings should be gone now.
I haven't fixed the build warnings in realm-annotations and realm-annotations-processor.

We cannot solve this reliable for all users unless we require that people also install JDK 6 and have a specific environment variable. Some discussion on this can be found here http://stackoverflow.com/questions/15882586/bootstrap-class-path-not-set

Currently Jenkins has JDK 7 installed. To be safe we should probably downgrade to JDK 6, unless there is a reason for JDK 7. 

This doesn't prevent the build warnings, but ensures that no errors slip past the build server.

Note, upgrading the project to Java7 isn't a solution as you get the same error if you have Java8 installed.

@emanuelez @kneth @bmunkholm 
It does not below in this PR (with current title). If it fixes a bug, we also need to update the changelog.