Hi,
I’ve been using Gradle for some months now (starting from Gradle 2.2).
Amongst others I use the C plugin.
I use a non-supported compiler in parallel with gcc.
For both I use the standard mechanism to build source sets.
The custom compiler is fed with a file list build from the source sets.
With Gradle 2.2 I can print out such a list with
task printSources << {
sources.main.c.source.each { src ->
println project.relativePath(src.path)
}
}
In the meantime some things changed and Gradle 2.3 provides componentSpec which lets me use a similar syntax.
How can I do it with Gradle 2.5, however?
The configuration - to keep it simple - is:
model {
components {
main(NativeLibrarySpec) {
sources {
c {
source {
srcDirs "src/main"
include "*.c"
}
}
}
}
}
I found a hint in the release notes but I feel somehow lost in darkness…
Thx in advance!