mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
build scripts: generate third-party libraries list when building from sources
This commit is contained in:
+16
-10
@@ -190,6 +190,7 @@ class DistributionJARsBuilder {
|
||||
buildLib()
|
||||
buildBundledPlugins()
|
||||
buildNonBundledPlugins()
|
||||
buildThirdPartyLibrariesList()
|
||||
|
||||
def loadingOrderFilePath = buildContext.productProperties.productLayout.classesLoadingOrderFilePath
|
||||
if (loadingOrderFilePath != null) {
|
||||
@@ -224,17 +225,11 @@ class DistributionJARsBuilder {
|
||||
|
||||
void buildAdditionalArtifacts() {
|
||||
def productProperties = buildContext.productProperties
|
||||
buildContext.messages.block("Generate table of licenses for used third-party libraries") {
|
||||
def generator = new LibraryLicensesListGenerator(buildContext.messages, buildContext.project, productProperties.allLibraryLicenses)
|
||||
|
||||
String thirdPartyLibrariesFilePath = "$buildContext.paths.distAll/$THIRD_PARTY_LIBRARIES_FILE_PATH"
|
||||
generator.generateLicensesTable(thirdPartyLibrariesFilePath, usedModules)
|
||||
|
||||
if (productProperties.generateLibrariesLicensesTable) {
|
||||
String artifactNamePrefix = productProperties.getBaseArtifactName(buildContext.applicationInfo, buildContext.buildNumber)
|
||||
buildContext.ant.
|
||||
copy(file: thirdPartyLibrariesFilePath, tofile: "$buildContext.paths.artifacts/$artifactNamePrefix-third-party-libraries.html")
|
||||
}
|
||||
if (productProperties.generateLibrariesLicensesTable) {
|
||||
String artifactNamePrefix = productProperties.getBaseArtifactName(buildContext.applicationInfo, buildContext.buildNumber)
|
||||
buildContext.ant.copy(file: getThirdPartyLibrariesFilePath(),
|
||||
tofile: "$buildContext.paths.artifacts/$artifactNamePrefix-third-party-libraries.html")
|
||||
}
|
||||
|
||||
if (productProperties.scrambleMainJar) {
|
||||
@@ -251,6 +246,17 @@ class DistributionJARsBuilder {
|
||||
}
|
||||
}
|
||||
|
||||
private void buildThirdPartyLibrariesList() {
|
||||
buildContext.messages.block("Generate table of licenses for used third-party libraries") {
|
||||
def generator = new LibraryLicensesListGenerator(buildContext.messages, buildContext.project, buildContext.productProperties.allLibraryLicenses)
|
||||
generator.generateLicensesTable(getThirdPartyLibrariesFilePath(), usedModules)
|
||||
}
|
||||
}
|
||||
|
||||
private String getThirdPartyLibrariesFilePath() {
|
||||
"$buildContext.paths.distAll/$THIRD_PARTY_LIBRARIES_FILE_PATH"
|
||||
}
|
||||
|
||||
private void buildLib() {
|
||||
def ant = buildContext.ant
|
||||
def layoutBuilder = createLayoutBuilder()
|
||||
|
||||
Reference in New Issue
Block a user