Gradle not using JAVA_HOME when building in Eclipse/Buildship

I have Java 7 and Java 8 installed with JAVA_HOME set to Java 7 location and Java 8 being the default on the PATH.
When I execute the gradle build from command line it correctly uses Java 7 for the build but within Eclipse/Buildship it uses the default Java 8. How can I correctly launch the build within eclipse to use the Java 7?

Executing a Gradle task from Eclipse should work similarly to the command line. The build should pick up the org.gradle.java.home property from the build environment.