gradle-debian-helper/2.2 already checks if the JDK supports modules before adding the --add-opens options, but it checks the default JDK and not the one specified by JAVA_HOME, that's why it fails when OpenJDK 8 is used.
__ This is the maintainer address of Debian's Java team <https://alioth-lists.debian.net/cgi-bin/mailman/listinfo/pkg-java-maintainers>. Please use [email protected] for discussions and questions.
