The solution A worked in the past, the solution B should work now. I'm sorry, the syntax of exports addition has changed at least three times since I started using it (the first one was -XaddExports:). You must use those VM arguments with the "java" command and you might need to use them with javac too.