[ML] Include C++ 3rd party notices in X-Pack combined NOTICES file (elastic/x-pack-elasticsearch#953)

relates elastic/x-pack-elasticsearch#620

Original commit: elastic/x-pack-elasticsearch@5d73bd340c
This commit is contained in:
David Roberts 2017-04-10 12:40:07 +01:00 committed by GitHub
parent 63c04ef19d
commit e8337344a6
1 changed files with 14 additions and 0 deletions

View File

@ -158,6 +158,9 @@ gradle.taskGraph.whenReady { taskGraph ->
project.bundlePlugin.from {
zipTree(configurations.nativeBundle.singleFile)
}
project.extractNativeLicenses.from {
zipTree(configurations.nativeBundle.singleFile)
}
}
}
@ -271,6 +274,11 @@ forbiddenPatterns {
exclude '**/*.zip'
}
task extractNativeLicenses(type: Copy) {
into "${buildDir}"
include 'platform/licenses/**'
}
// TODO: standardize packaging config for plugins
bundlePlugin {
from('bin/x-pack') {
@ -279,6 +287,9 @@ bundlePlugin {
from('config/x-pack') {
into 'config'
}
// We don't ship the individual nativeBundle licenses - instead
// they get combined into the top level NOTICES file we ship
exclude 'platform/licenses/**'
}
// add api jar for extension authors to compile against
@ -311,6 +322,9 @@ project.afterEvaluate {
}
}
}
// Add an extra licenses directory to the combined notices
project.tasks.findByName('generateNotice').dependsOn extractNativeLicenses
project.tasks.findByName('generateNotice').licensesDir new File("${project.buildDir}/platform/licenses")
}
integTestRunner {