Fix for windows build

When the path to the java command contains spaces Runtime.exec(String) can't handle it. Runtime.exec(String[]) actually quotes the arguments and makes the build also work for windows.