add stub implementation of JVM_CurrentClassLoader
don't load libmawt ahead of time when starting the VM

At one point, loading libmawt ahead of time was necessary to make AWT
work, but recent versions of OpenJDK seem to take care this from Java
code, in which case loading it ahead of time causes trouble, so we
comment it out for now until we exactly when it's needed.
provide stub for JVM_UnloadLibrary

It may leak file handles under certain circumstances to do nothing in
JVM_UnloadLibrary, but, for now, an empty implementation is more
useful than one that aborts the process.
filter flags argument to JVM_Open

The class library may pass non-standard flags to JVM_Open which will
confuse the OS if we pass them through, so we must filter them out.
initialize the class if necessary when the "new" operator is invoked

This is one of the conditions specified in
http://docs.oracle.com/javase/specs/jls/se7/html/jls-12.html#jls-12.4.1,
which I had forgotten about.
wait until all non-daemon threads exit before invoking the class library shutdown method

Running the shutdown method prematurely can cause deadlock in
OpenJDK's AWT implementation and may have other nasty effects besides
that.