mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
builds scripts: allow Linux's .tar.gz and Mac's .zip to be skipped
This may be needed e.g. to build cross-platform distribution only.
This commit is contained in:
@@ -52,8 +52,12 @@ class BuildOptions {
|
||||
static final SEARCHABLE_OPTIONS_INDEX_STEP = "search_index"
|
||||
static final PROVIDED_MODULES_LIST_STEP = "provided_modules_list"
|
||||
static final SOURCES_ARCHIVE_STEP = "sources_archive"
|
||||
/** build Mac OS X artifacts */
|
||||
static final MAC_ARTIFACTS = "mac_artifacts"
|
||||
/** product DMG file for Mac OS X. If it is skipped only sit archive will be produced. */
|
||||
static final MAC_DMG_STEP = "mac_dmg"
|
||||
/** product TAR.GZ file for Linux. */
|
||||
static final LINUX_TAR_GZ_STEP = "linux_targz"
|
||||
/** sign additional binary files in Mac OS X distribution */
|
||||
static final MAC_SIGN_STEP = "mac_sign"
|
||||
/** create *.exe installer for Windows distribution. If it is skipped only zip archive will be produced. */
|
||||
|
||||
+12
-10
@@ -66,16 +66,18 @@ class LinuxDistributionBuilder extends OsSpecificDistributionBuilder {
|
||||
|
||||
@Override
|
||||
void buildArtifacts(String osSpecificDistPath) {
|
||||
if (customizer.buildTarGzWithoutBundledJre) {
|
||||
buildTarGz(null, osSpecificDistPath)
|
||||
}
|
||||
def jreDirectoryPath = buildContext.bundledJreManager.extractLinuxJre()
|
||||
if (jreDirectoryPath != null) {
|
||||
buildTarGz(jreDirectoryPath, osSpecificDistPath)
|
||||
buildSnapPackage(jreDirectoryPath, osSpecificDistPath)
|
||||
}
|
||||
else {
|
||||
buildContext.messages.info("Skipping building Linux distribution with bundled JRE because JRE archive is missing")
|
||||
buildContext.executeStep("Build Linux .tar.gz", BuildOptions.LINUX_TAR_GZ_STEP) {
|
||||
if (customizer.buildTarGzWithoutBundledJre) {
|
||||
buildTarGz(null, osSpecificDistPath)
|
||||
}
|
||||
def jreDirectoryPath = buildContext.bundledJreManager.extractLinuxJre()
|
||||
if (jreDirectoryPath != null) {
|
||||
buildTarGz(jreDirectoryPath, osSpecificDistPath)
|
||||
buildSnapPackage(jreDirectoryPath, osSpecificDistPath)
|
||||
}
|
||||
else {
|
||||
buildContext.messages.info("Skipping building Linux distribution with bundled JRE because JRE archive is missing")
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
+11
-9
@@ -93,15 +93,17 @@ class MacDistributionBuilder extends OsSpecificDistributionBuilder {
|
||||
|
||||
@Override
|
||||
void buildArtifacts(String osSpecificDistPath) {
|
||||
def macZipPath = buildMacZip(osSpecificDistPath)
|
||||
if (buildContext.proprietaryBuildTools.macHostProperties == null) {
|
||||
buildContext.messages.info("A Mac OS build agent isn't configured, dmg artifact won't be produced")
|
||||
buildContext.notifyArtifactBuilt(macZipPath)
|
||||
}
|
||||
else {
|
||||
buildContext.executeStep("Build dmg artifact for Mac OS X", BuildOptions.MAC_DMG_STEP) {
|
||||
MacDmgBuilder.signAndBuildDmg(buildContext, customizer, buildContext.proprietaryBuildTools.macHostProperties, macZipPath)
|
||||
buildContext.ant.delete(file: macZipPath)
|
||||
buildContext.executeStep("Build artifacts for Mac OS X", BuildOptions.MAC_ARTIFACTS) {
|
||||
def macZipPath = buildMacZip(osSpecificDistPath)
|
||||
if (buildContext.proprietaryBuildTools.macHostProperties == null) {
|
||||
buildContext.messages.info("A Mac OS build agent isn't configured, dmg artifact won't be produced")
|
||||
buildContext.notifyArtifactBuilt(macZipPath)
|
||||
}
|
||||
else {
|
||||
buildContext.executeStep("Build dmg artifact for Mac OS X", BuildOptions.MAC_DMG_STEP) {
|
||||
MacDmgBuilder.signAndBuildDmg(buildContext, customizer, buildContext.proprietaryBuildTools.macHostProperties, macZipPath)
|
||||
buildContext.ant.delete(file: macZipPath)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user