I am adding a new configuration for my newly added sourceset.
Sourceset: tools configuration: toolsCompile
In the toolsCompile I am adding few java files as dependencies. The problem is since configuration flattens the fileTree all java files loses their package/folder structure. As a result compilation fails saying Package doesn’t exist.