I am trying to define a jar task for all subprojects (around 30). I tried to perform the following task:
jar {
destinationDir = file('../../../../_temp/core/modules')
archiveName = baseName + '.' + extension
metaInf {
from 'ejbModule/META-INF/' exclude 'MANIFEST.MF'
}
def manifestClasspath = configurations.runtime.collect { it.getName() }.join(',')
manifest {
attributes("Manifest-Version" : "1.0",
"Created-By" : vendor,
"Specification-Title" : appName,
"Specification-Version" : version,
"Specification-Vendor" : vendor,
"Implementation-Title" : appName,
"Implementation-Version" : version,
"Implementation-Vendor" : vendor,
"Main-Class" : "com.dcx.epep.Start",
"Class-Path" : manifestClasspath
)
}
}
My problem is that dependencies between helper projects are not included in the manifest class path. I tried changing the configuration of the runtime to the compilation configuration, but this leads to the following error.
- What went wrong: There was a problem evaluating the project ': EskoordClient'.
You cannot change a configuration that is not in an unauthorized state!
This is my complete build file for the EskoordClient project:
dependencies {
compile project(':ePEPClient')
}
Most of my subproject projects only create files to define project dependencies. Third-party library dependencies are defined in the superproject assembly file.
( ) .