// for install4j
JAVA_MIN_VERSION = JAVA_VERSION
JAVA_MAX_VERSION = JAVA_VERSION
- def jreInstallsDir = string(jre_installs_dir)
+ jreInstallsDir = string(jre_installs_dir)
if (jreInstallsDir.startsWith("~/")) {
jreInstallsDir = System.getProperty("user.home") + jreInstallsDir.substring(1)
}
- macosJavaVMDir = string("${jreInstallsDir}/jre-${JAVA_INTEGER_VERSION}-mac-x64/jre")
- windowsJavaVMDir = string("${jreInstallsDir}/jre-${JAVA_INTEGER_VERSION}-windows-x64/jre")
- linuxJavaVMDir = string("${jreInstallsDir}/jre-${JAVA_INTEGER_VERSION}-linux-x64/jre")
- macosJavaVMTgz = string("${jreInstallsDir}/tgz/jre_${JAVA_INTEGER_VERSION}_mac_x64.tar.gz")
- windowsJavaVMTgz = string("${jreInstallsDir}/tgz/jre_${JAVA_INTEGER_VERSION}_windows_x64.tar.gz")
- linuxJavaVMTgz = string("${jreInstallsDir}/tgz/jre_${JAVA_INTEGER_VERSION}_linux_x64.tar.gz")
install4jDir = string("${jalviewDir}/${install4j_utils_dir}")
install4jConfFileName = string("jalview-install4j-conf.install4j")
install4jConfFile = file("${install4jDir}/${install4jConfFileName}")
'JAVA_VERSION': JAVA_VERSION,
'JAVA_INTEGER_VERSION': JAVA_INTEGER_VERSION,
'VERSION': JALVIEW_VERSION,
- 'MACOS_JAVA_VM_DIR': macosJavaVMDir,
- 'WINDOWS_JAVA_VM_DIR': windowsJavaVMDir,
- 'LINUX_JAVA_VM_DIR': linuxJavaVMDir,
- 'MACOS_JAVA_VM_TGZ': macosJavaVMTgz,
- 'WINDOWS_JAVA_VM_TGZ': windowsJavaVMTgz,
- 'LINUX_JAVA_VM_TGZ': linuxJavaVMTgz,
+
'COPYRIGHT_MESSAGE': install4j_copyright_message,
'BUNDLE_ID': install4jBundleId,
'INTERNAL_ID': install4jInternalId,
'WINDOWS_ICONS_FILE': install4jWindowsIconsFile,
'PNG_ICON_FILE': install4jPngIconFile,
'BACKGROUND': install4jBackground,
-
]
+
+
+ //macosJavaVMDir = string("${jreInstallsDir}/jre-${JAVA_INTEGER_VERSION}-mac-x64/jre")
+ //windowsJavaVMDir = string("${jreInstallsDir}/jre-${JAVA_INTEGER_VERSION}-windows-x64/jre")
+ //linuxJavaVMDir = string("${jreInstallsDir}/jre-${JAVA_INTEGER_VERSION}-linux-x64/jre")
+ //macosJavaVMTgz = string("${jreInstallsDir}/tgz/jre_${JAVA_INTEGER_VERSION}_mac_x64.tar.gz")
+ //windowsJavaVMTgz = string("${jreInstallsDir}/tgz/jre_${JAVA_INTEGER_VERSION}_windows_x64.tar.gz")
+ //linuxJavaVMTgz = string("${jreInstallsDir}/tgz/jre_${JAVA_INTEGER_VERSION}_linux_x64.tar.gz")
+
+ def varNameMap = [
+ 'mac': 'MACOS',
+ 'windows': 'WINDOWS',
+ 'linux': 'LINUX'
+ ]
+
+ // these are the bundled OS/architecture VMs needed by install4j
+ def osArch = [
+ [ "mac", "x64" ],
+ [ "mac", "aarch64" ],
+ [ "windows", "x64" ],
+ [ "linux", "x64" ],
+ [ "linux", "aarch64" ]
+ ]
+ osArch.forEach { os, arch ->
+ variables[ sprintf("%s_%s_JAVA_VM_DIR", varNameMap[os], arch.toUpperCase(Locale.ROOT)) ] = sprintf("%s/jre-%s-%s-%s/jre", jreInstallsDir, JAVA_INTEGER_VERSION, os, arch)
+ // N.B. For some reason install4j requires the below filename to have underscores and not hyphens
+ // otherwise running `gradle installers` generates a non-useful error:
+ // `install4j: compilation failed. Reason: java.lang.NumberFormatException: For input string: "windows"`
+ variables[ sprintf("%s_%s_JAVA_VM_TGZ", varNameMap[os], arch.toUpperCase(Locale.ROOT)) ] = sprintf("%s/tgz/jre_%s_%s_%s.tar.gz", jreInstallsDir, JAVA_INTEGER_VERSION, os, arch)
+ }
- //println("INSTALL4J VARIABLES:")
- //variables.each{k,v->println("${k}=${v}")}
+ println("INSTALL4J VARIABLES:")
+ variables.each{k,v->println("${k}=${v}")}
destination = "${jalviewDir}/${install4jBuildDir}"
buildSelected = true
inputs.dir(getdownAppBaseDir)
inputs.file(install4jConfFile)
inputs.file("${install4jDir}/${install4j_info_plist_file_associations}")
- inputs.dir(macosJavaVMDir)
- inputs.dir(windowsJavaVMDir)
outputs.dir("${jalviewDir}/${install4j_build_dir}/${JAVA_VERSION}")
}
<?xml version="1.0" encoding="UTF-8"?>
-<install4j version="9.0.5" transformSequenceNumber="9">
+<install4j version="9.0.7" transformSequenceNumber="9">
<directoryPresets config="bin/jalview" />
<application name="${compiler:JALVIEW_APPLICATION_NAME}" applicationId="${compiler:WINDOWS_APPLICATION_ID}" mediaDir="${compiler:BUILD_DIR}" lzmaCompression="true" shortName="${compiler:INTERNAL_ID}" publisher="University of Dundee" publisherWeb="https://www.jalview.org/" version="${compiler:JALVIEW_VERSION}" allPathsRelative="true" macVolumeId="5aac4968c304f65" javaMinVersion="${compiler:JAVA_MIN_VERSION}" javaMaxVersion="${compiler:JAVA_MAX_VERSION}" allowBetaVM="true" jdkMode="jdk" jdkName="JDK 11.0">
<searchSequence>
<variable name="JAVA_VERSION" value="11" />
<variable name="JAVA_INTEGER_VERSION" value="11" />
<variable name="VERSION" value="DEVELOPMENT" />
- <variable name="MACOS_JAVA_VM_DIR" value="${compiler:env.HOME}/buildtools/jre/jre-${compiler:JAVA_INTEGER_VERSION}-mac-x64/jre" />
- <variable name="WINDOWS_JAVA_VM_DIR" value="${compiler:env.HOME}/buildtools/jre/jre-${compiler:JAVA_INTEGER_VERSION}-windows-x64/jre" />
- <variable name="LINUX_JAVA_VM_DIR" value="${compiler:env.HOME}/buildtools/jre/jre-${compiler:JAVA_INTEGER_VERSION}-linux-x64/jre" />
- <variable name="MACOS_JAVA_VM_TGZ" value="${compiler:env.HOME}/buildtools/jre/tgz/jre_${compiler:JAVA_INTEGER_VERSION}_mac_x64.tar.gz" />
- <variable name="WINDOWS_JAVA_VM_TGZ" value="${compiler:env.HOME}/buildtools/jre/tgz/jre_${compiler:JAVA_INTEGER_VERSION}_windows_x64.tar.gz" />
- <variable name="LINUX_JAVA_VM_TGZ" value="${compiler:env.HOME}/buildtools/jre/tgz/jre_${compiler:JAVA_INTEGER_VERSION}_linux_x64.tar.gz" />
+ <variable name="MACOS_X64_JAVA_VM_DIR" value="${compiler:env.HOME}/buildtools/jre/jre-${compiler:JAVA_INTEGER_VERSION}-mac-x64/jre" />
+ <variable name="MACOS_AARCH64_JAVA_VM_DIR" value="${compiler:env.HOME}/buildtools/jre/jre-${compiler:JAVA_INTEGER_VERSION}-mac-aarch64/jre" />
+ <variable name="WINDOWS_X64_JAVA_VM_DIR" value="${compiler:env.HOME}/buildtools/jre/jre-${compiler:JAVA_INTEGER_VERSION}-windows-x64/jre" />
+ <variable name="LINUX_X64_JAVA_VM_DIR" value="${compiler:env.HOME}/buildtools/jre/jre-${compiler:JAVA_INTEGER_VERSION}-linux-x64/jre" />
+ <variable name="LINUX_AARCH64_JAVA_VM_DIR" value="${compiler:env.HOME}/buildtools/jre/jre-${compiler:JAVA_INTEGER_VERSION}-linux-aarch64/jre" />
+ <variable name="MACOS_X64_JAVA_VM_TGZ" value="${compiler:env.HOME}/buildtools/jre/tgz/jre_${compiler:JAVA_INTEGER_VERSION}_mac_x64.tar.gz" />
+ <variable name="MACOS_AARCH64_JAVA_VM_TGZ" value="${compiler:env.HOME}/buildtools/jre/tgz/jre_${compiler:JAVA_INTEGER_VERSION}_mac_aarch64.tar.gz" />
+ <variable name="WINDOWS_X64_JAVA_VM_TGZ" value="${compiler:env.HOME}/buildtools/jre/tgz/jre_${compiler:JAVA_INTEGER_VERSION}_windows_x64.tar.gz" />
+ <variable name="LINUX_X64_JAVA_VM_TGZ" value="${compiler:env.HOME}/buildtools/jre/tgz/jre_${compiler:JAVA_INTEGER_VERSION}_linux_x64.tar.gz" />
+ <variable name="LINUX_AARCH64_JAVA_VM_TGZ" value="${compiler:env.HOME}/buildtools/jre/tgz/jre_${compiler:JAVA_INTEGER_VERSION}_linux_aarch64.tar.gz" />
<variable name="COPYRIGHT_MESSAGE" value="..." />
<variable name="BUNDLE_ID" value="org.jalview.jalview-desktop" />
<variable name="INTERNAL_ID" value="Jalview" />
<variable name="WINDOWS_APPLICATION_ID" value="6595-2347-1923-0725" />
- <variable name="MACOS_DMG_DS_STORE" value="jalview_dmg_DS_Store" />
- <variable name="MACOS_DMG_BG_IMAGE" value="jalview_dmg_background-72dpi.png" />
+ <variable name="MACOS_DMG_DS_STORE" value="jalview_default_dmg_DS_Store" />
+ <variable name="MACOS_DMG_BG_IMAGE" value="jalview_default_dmg_background-72dpi.png" />
<variable name="WRAPPER_LINK" value="jalview" />
<variable name="BASH_WRAPPER_SCRIPT" value="jalview.sh" />
<variable name="WRAPPER_SCRIPT_BIN_DIR" value="bin" />
<files defaultUninstallMode="2" preserveSymlinks="false">
<filesets>
<fileset name="Full file set" id="734" customizedId="FULL_FILE_SET" />
- <fileset name="Mac OS X JRE" id="880" />
- <fileset name="Windows JRE" id="882" />
- <fileset name="Jalview application" id="1873" />
</filesets>
<roots>
<root id="735" fileset="734" />
- <root id="881" fileset="880" />
- <root id="883" fileset="882" />
- <root id="1874" fileset="1873" />
</roots>
<mountPoints>
- <mountPoint id="454" />
<mountPoint id="736" root="735" />
- <mountPoint id="884" root="881" />
- <mountPoint id="885" root="883" />
- <mountPoint id="1875" root="1874" />
</mountPoints>
<entries>
- <dirEntry mountPoint="454" file="${compiler:JALVIEW_DIR}/${compiler:GETDOWN_FILES_DIR}/${compiler:JAVA_VERSION}" uninstallMode="2" overrideOverwriteMode="true" overrideUninstallMode="true" subDirectory="files" />
<dirEntry mountPoint="736" file="${compiler:JALVIEW_DIR}/${compiler:GETDOWN_CHANNEL_DIR}/${compiler:JAVA_VERSION}" uninstallMode="2" overrideOverwriteMode="true" overrideUninstallMode="true" subDirectory="files">
<exclude>
<entry location="${compiler:WRAPPER_SCRIPT_BIN_DIR}" />
</dirEntry>
<dirEntry mountPoint="736" file="${compiler:JALVIEW_DIR}/examples" overwriteMode="1" uninstallMode="2" overrideFileMode="true" overrideOverwriteMode="true" overrideUninstallMode="true" entryMode="subdir" subDirectory="examples" />
<dirEntry mountPoint="736" file="${compiler:JALVIEW_DIR}/${compiler:GETDOWN_CHANNEL_DIR}/${compiler:JAVA_VERSION}/${compiler:WRAPPER_SCRIPT_BIN_DIR}" fileMode="755" overrideFileMode="true" overrideUninstallMode="true" entryMode="subdir" subDirectory="${compiler:WRAPPER_SCRIPT_BIN_DIR}" overrideDirMode="true" />
- <dirEntry mountPoint="884" file="${compiler:MACOS_JAVA_VM_DIR}" fileMode="755" overrideFileMode="true" overrideUninstallMode="true" entryMode="subdir" subDirectory="${compiler:JRE_DIR}" />
- <dirEntry mountPoint="885" file="${compiler:WINDOWS_JAVA_VM_DIR}" fileMode="755" overrideFileMode="true" overrideUninstallMode="true" entryMode="subdir" subDirectory="${compiler:JRE_DIR}" />
- <dirEntry mountPoint="1875" file="${compiler:JALVIEW_DIR}/${compiler:GETDOWN_CHANNEL_DIR}/${compiler:JAVA_VERSION}/${compiler:GETDOWN_DIST_DIR}" overwriteMode="1" uninstallMode="2" overrideFileMode="true" overrideOverwriteMode="true" overrideUninstallMode="true" entryMode="subdir" subDirectory="${compiler:GETDOWN_DIST_DIR}" overrideDirMode="true" />
</entries>
<components>
<component name="jalview_getdown" id="1031">
<entry filesetId="734" />
</include>
</component>
- <component name="macos_java_vm" id="1155">
- <include>
- <entry filesetId="880" />
- </include>
- </component>
- <component name="windows_java_vm" id="1156">
- <include>
- <entry filesetId="882" />
- </include>
- </component>
- <component name="getdown" id="1276">
- <include>
- <entry defaultFileset="true" />
- </include>
- </component>
- <component name="jalview" id="1881">
- <include>
- <entry filesetId="1873" />
- </include>
- </component>
</components>
</files>
<launchers>
</installerGui>
<mediaSets>
<windows name="Windows x64 EXE Installer" id="743" customizedId="WINDOWS-X64-EXE" mediaFileName="${compiler:APPLICATION_FOLDER}-${compiler:JALVIEW_VERSION}-${compiler:sys.platform}-java_${compiler:JAVA_INTEGER_VERSION}" installDir="${compiler:APPLICATION_FOLDER}" runPostProcessor="true" postProcessor="${compiler:JSIGN_SH} $EXECUTABLE" customInstallBaseDir="~/AppData/Local">
- <excludedComponents>
- <component id="1155" />
- <component id="1156" />
- <component id="1276" />
- <component id="1881" />
- </excludedComponents>
+ <excludedBeans>
+ <bean refId="2746" />
+ </excludedBeans>
<exclude>
<entry defaultFileset="true" />
- <entry filesetId="880" />
- <entry filesetId="882" />
- <entry filesetId="1873" />
- <entry filesetId="2105" />
</exclude>
- <jreBundle jreBundleSource="preCreated" includedJre="${compiler:WINDOWS_JAVA_VM_TGZ}" manualJreEntry="true" />
+ <jreBundle jreBundleSource="preCreated" includedJre="${compiler:WINDOWS_X64_JAVA_VM_TGZ}" manualJreEntry="true" />
</windows>
- <macosArchive name="macOS Disk Image" id="878" customizedId="MACOS-X64-DMG" mediaFileName="${compiler:APPLICATION_FOLDER}-${compiler:JALVIEW_VERSION}-${compiler:sys.platform}-java_${compiler:JAVA_INTEGER_VERSION}" volumeName="${compiler:INSTALLER_NAME}" launcherId="737" executeSetupApp="true" setupAppId="2746">
- <excludedComponents>
- <component id="1156" />
- <component id="1276" />
- <component id="1881" />
- </excludedComponents>
+ <macosArchive name="macOS x64 Disk Image" id="878" customizedId="MACOS-X64-DMG" mediaFileName="${compiler:APPLICATION_FOLDER}-${compiler:JALVIEW_VERSION}-macOS_x64-${compiler:sys.platform}-java_${compiler:JAVA_INTEGER_VERSION}" volumeName="${compiler:INSTALLER_NAME}" launcherId="737" setupAppId="2746">
<exclude>
<entry defaultFileset="true" />
- <entry filesetId="882" />
- <entry filesetId="1873" />
</exclude>
<jreBundle jreBundleSource="none" />
<topLevelFiles>
<symlink name="" "" target="/Applications" />
- <file name=".background/jalview_dmg_background.png" file="${compiler:JALVIEW_DIR}/${compiler:MACOS_DMG_BG_IMAGE}" />
- <file name=".DS_Store" file="${compiler:JALVIEW_DIR}/${compiler:MACOS_DMG_DS_STORE}" />
+ <file name=".background/jalview_dmg_background.png" file="${compiler:JALVIEW_DIR}/utils/channels/default/images/${compiler:MACOS_DMG_BG_IMAGE}" />
+ <file name=".DS_Store" file="${compiler:JALVIEW_DIR}/utils/channels/default/images/${compiler:MACOS_DMG_DS_STORE}" />
+ <file name="${compiler:JALVIEW_APPLICATION_NAME}.app/Contents/Resources/Jalview-File.icns" file="${compiler:JALVIEW_DIR}/${compiler:INSTALL4J_UTILS_DIR}/Jalview-File.icns" />
+ <file name="${compiler:JALVIEW_APPLICATION_NAME}.app/Contents/Resources/jvl_file.icns" file="${compiler:JALVIEW_DIR}/${compiler:INSTALL4J_UTILS_DIR}/jvl_file.icns" />
+ <symlink name="${compiler:JALVIEW_APPLICATION_NAME}.app/Contents/MacOS/${compiler:WRAPPER_LINK}" target="../Resources/app/${compiler:WRAPPER_SCRIPT_BIN_DIR}/${compiler:BASH_WRAPPER_SCRIPT}" />
+ </topLevelFiles>
+ </macosArchive>
+ <macosArchive name="macOS aarch64 Disk Image" id="2796" customizedId="MACOS-AARCH64-DMG" mediaFileName="${compiler:APPLICATION_FOLDER}-${compiler:JALVIEW_VERSION}-macOS_aarch64-${compiler:sys.platform}-java_${compiler:JAVA_INTEGER_VERSION}" volumeName="${compiler:INSTALLER_NAME}" architecture="aarch64" launcherId="737" setupAppId="2746">
+ <exclude>
+ <entry defaultFileset="true" />
+ </exclude>
+ <jreBundle jreBundleSource="none" />
+ <topLevelFiles>
+ <symlink name="" "" target="/Applications" />
+ <file name=".background/jalview_dmg_background.png" file="${compiler:JALVIEW_DIR}/utils/channels/default/images/${compiler:MACOS_DMG_BG_IMAGE}" />
+ <file name=".DS_Store" file="${compiler:JALVIEW_DIR}/utils/channels/default/images/${compiler:MACOS_DMG_DS_STORE}" />
<file name="${compiler:JALVIEW_APPLICATION_NAME}.app/Contents/Resources/Jalview-File.icns" file="${compiler:JALVIEW_DIR}/${compiler:INSTALL4J_UTILS_DIR}/Jalview-File.icns" />
<file name="${compiler:JALVIEW_APPLICATION_NAME}.app/Contents/Resources/jvl_file.icns" file="${compiler:JALVIEW_DIR}/${compiler:INSTALL4J_UTILS_DIR}/jvl_file.icns" />
<symlink name="${compiler:JALVIEW_APPLICATION_NAME}.app/Contents/MacOS/${compiler:WRAPPER_LINK}" target="../Resources/app/${compiler:WRAPPER_SCRIPT_BIN_DIR}/${compiler:BASH_WRAPPER_SCRIPT}" />
</topLevelFiles>
</macosArchive>
<unixInstaller name="Linux x64 Shell Installer" id="1595" customizedId="LINUX-X64-SH" mediaFileName="${compiler:UNIX_APPLICATION_FOLDER}-${compiler:JALVIEW_VERSION}-linux_x64-java_${compiler:JAVA_INTEGER_VERSION}" installDir="${compiler:UNIX_APPLICATION_FOLDER}" customInstallBaseDir="~/opt/">
- <excludedComponents>
- <component id="1155" />
- <component id="1156" />
- <component id="1276" />
- <component id="1881" />
- </excludedComponents>
+ <excludedBeans>
+ <bean refId="2746" />
+ </excludedBeans>
+ <exclude>
+ <entry defaultFileset="true" />
+ </exclude>
+ <jreBundle jreBundleSource="preCreated" includedJre="${compiler:LINUX_X64_JAVA_VM_TGZ}" manualJreEntry="true" />
+ </unixInstaller>
+ <unixInstaller name="Linux aarch64 Shell Installer" id="2782" customizedId="LINUX-AARCH64-SH" mediaFileName="${compiler:UNIX_APPLICATION_FOLDER}-${compiler:JALVIEW_VERSION}-linux_aarch64-java_${compiler:JAVA_INTEGER_VERSION}" installDir="${compiler:UNIX_APPLICATION_FOLDER}" customInstallBaseDir="~/opt/">
+ <excludedBeans>
+ <bean refId="2746" />
+ </excludedBeans>
<exclude>
<entry defaultFileset="true" />
- <entry filesetId="880" />
- <entry filesetId="882" />
- <entry filesetId="1873" />
- <entry filesetId="2105" />
</exclude>
- <jreBundle jreBundleSource="preCreated" includedJre="${compiler:LINUX_JAVA_VM_TGZ}" manualJreEntry="true" />
+ <jreBundle jreBundleSource="preCreated" includedJre="${compiler:LINUX_AARCH64_JAVA_VM_TGZ}" manualJreEntry="true" />
</unixInstaller>
<unixArchive name="Unix .tar.gz Archive" id="1596" customizedId="UNIX--TGZ" mediaFileName="${compiler:UNIX_APPLICATION_FOLDER}-${compiler:JALVIEW_VERSION}-${compiler:sys.platform}-java_${compiler:JAVA_INTEGER_VERSION}" installDir="${compiler:UNIX_APPLICATION_FOLDER}">
- <excludedComponents>
- <component id="1155" />
- <component id="1156" />
- <component id="1276" />
- <component id="1881" />
- </excludedComponents>
+ <excludedBeans>
+ <bean refId="2746" />
+ </excludedBeans>
<exclude>
<entry defaultFileset="true" />
- <entry filesetId="880" />
- <entry filesetId="882" />
- <entry filesetId="1873" />
- <entry filesetId="2105" />
</exclude>
- <jreBundle jreBundleSource="none" includedJre="${compiler:LINUX_JAVA_VM_TGZ}" manualJreEntry="true" />
+ <jreBundle jreBundleSource="none" includedJre="${compiler:LINUX_X64_JAVA_VM_TGZ}" manualJreEntry="true" />
</unixArchive>
<unixInstaller name="Unix Shell Installer" id="2639" customizedId="UNIX--SH" mediaFileName="${compiler:UNIX_APPLICATION_FOLDER}-${compiler:JALVIEW_VERSION}-${compiler:sys.platform}-java_${compiler:JAVA_INTEGER_VERSION}" installDir="${compiler:UNIX_APPLICATION_FOLDER}" customInstallBaseDir="~/opt/">
- <excludedComponents>
- <component id="1155" />
- <component id="1156" />
- <component id="1276" />
- <component id="1881" />
- </excludedComponents>
+ <excludedBeans>
+ <bean refId="2746" />
+ </excludedBeans>
<exclude>
<entry defaultFileset="true" />
- <entry filesetId="880" />
- <entry filesetId="882" />
- <entry filesetId="1873" />
- <entry filesetId="2105" />
</exclude>
- <jreBundle jreBundleSource="none" includedJre="${compiler:LINUX_JAVA_VM_TGZ}" manualJreEntry="true" />
+ <jreBundle jreBundleSource="none" includedJre="${compiler:LINUX_X64_JAVA_VM_TGZ}" manualJreEntry="true" />
</unixInstaller>
</mediaSets>
<buildIds>