AFAIK, Gradle does not support JDK based profile activation.
@Lance made some related suggestions here.