Fixes #81: I consider this a Gradle bug but luckily there is a workaround.