I managed to fix my own problem. I added the following to my build.gradle
:
eclipse {
classpath {
file {
whenMerged {
// Find the "source" entry and add the exclude for the folder containing our super-source code
def src = entries.find { it.path == 'source' }
src.each {
it.excludes = ["com/mycompany/project/gwt/**"]
}
}
}
}
}
This adds the necessary exclusion where I need it. It feels very inelegant though. If anybody knows of a more declarative way to achieve the same end, I would much appreciate it.