build scripts: extract jps-model modules into separate JAR in all IDEs

Previously 'jps-model-impl' and 'jps-model-serialization' were extracted into a separate JAR in IDEA only (because we need this for external build process), all other IDEs included these modules into the main productName.jar. This requires hacky code in IDEA build scripts and complicates unification of JARs layout for all IDEs (e.g. extracting common platform JARs).
This commit is contained in:
nik
2017-11-21 16:59:26 +03:00
parent 8fda7577db
commit 8155eeb35e
4 changed files with 4 additions and 5 deletions

View File

@@ -55,7 +55,6 @@ abstract class BaseIdeaProperties extends ProductProperties {
productLayout.additionalPlatformJars.put("jps-builders-6.jar", "jps-builders-6")
productLayout.additionalPlatformJars.put("aether-dependency-resolver.jar", "aether-dependency-resolver")
productLayout.additionalPlatformJars.put("jshell-protocol.jar", "jshell-protocol")
productLayout.additionalPlatformJars.putAll("jps-model.jar", ["jps-model-impl", "jps-model-serialization"])
productLayout.additionalPlatformJars.putAll("resources.jar", ["resources", "resources-en"])
productLayout.additionalPlatformJars.
putAll("javac2.jar", ["javac2", "forms-compiler", "forms_rt", "instrumentation-util", "instrumentation-util-8", "javac-ref-scanner-8"])

View File

@@ -33,8 +33,7 @@ class IdeaCommunityProperties extends BaseIdeaProperties {
buildCrossPlatformDistribution = true
productLayout.platformApiJarModules = CommunityRepositoryModules.PLATFORM_API_MODULES
//jps modules are packed into a separate JAR to include into build process's classpath so we need to exclude them from the main platform JAR
productLayout.platformImplJarModules = CommunityRepositoryModules.PLATFORM_IMPLEMENTATION_MODULES - ["jps-model-impl", "jps-model-serialization"]
productLayout.platformImplJarModules = CommunityRepositoryModules.PLATFORM_IMPLEMENTATION_MODULES
productLayout.productApiModules = JAVA_API_MODULES
productLayout.productImplementationModules = JAVA_IMPLEMENTATION_MODULES +
["duplicates-analysis", "structuralsearch", "structuralsearch-java", "typeMigration", "platform-main"]

View File

@@ -64,8 +64,6 @@ class CommunityRepositoryModules {
"editor-ui-ex",
"images",
"indexing-impl",
"jps-model-impl",
"jps-model-serialization",
"json",
"lang-impl",
"lvcs-impl",

View File

@@ -114,6 +114,9 @@ class DistributionJARsBuilder {
withModule("platform-resources", "resources.jar")
withModule("colorSchemes", "resources.jar")
withModule("platform-resources-en", productLayout.mainJarName)
withModule("jps-model-serialization", "jps-model.jar")
withModule("jps-model-impl", "jps-model.jar")
if (allProductDependencies.contains("coverage-common") && !productLayout.bundledPluginModules.contains("coverage")) {
withModule("coverage-common", productLayout.mainJarName)
}