Skip to content

Commit

Permalink
LPD-41359 installers: consolidate autodetect-java logic to a single file
Browse files Browse the repository at this point in the history
  • Loading branch information
drewbrokke committed Dec 4, 2024
1 parent be81f2a commit b417509
Show file tree
Hide file tree
Showing 4 changed files with 29 additions and 83 deletions.
38 changes: 0 additions & 38 deletions build/installers/components/autodetect-java-windows.xml

This file was deleted.

70 changes: 29 additions & 41 deletions build/installers/components/autodetect-java.xml
Original file line number Diff line number Diff line change
@@ -1,41 +1,29 @@
<autodetectJava>
<abortOnError>0</abortOnError>
<customErrorMessage>The installer could not find a valid Java(tm) through standard installation paths or environment variables on this machine. Required JDK versions: 1.8 64-Bit JDK or 11 64-Bit JDK. Please click OK and browse a valid java executable file to continue.</customErrorMessage>
<promptUser>1</promptUser>
<ruleList>
<platformTest>
<negate>1</negate>
<type>windows</type>
</platformTest>
</ruleList>
<validVersionList>
<validVersion>
<bitness>64</bitness>
<maxVersion>1.8</maxVersion>
<minVersion>1.8</minVersion>
<requireJDK>1</requireJDK>
<vendor></vendor>
</validVersion>
<validVersion>
<bitness>64</bitness>
<maxVersion>11</maxVersion>
<minVersion>11</minVersion>
<requireJDK>1</requireJDK>
<vendor></vendor>
</validVersion>
<validVersion>
<bitness>64</bitness>
<maxVersion>17</maxVersion>
<minVersion>17</minVersion>
<requireJDK>1</requireJDK>
<vendor></vendor>
</validVersion>
<validVersion>
<bitness>64</bitness>
<maxVersion>21</maxVersion>
<minVersion>21</minVersion>
<requireJDK>1</requireJDK>
<vendor></vendor>
</validVersion>
</validVersionList>
</autodetectJava>
<if>
<actionList>
<autodetectJava>
<promptUser>1</promptUser>
<validVersionList>
<validVersion bitness="64" maxVersion="1.8" minVersion="1.8" requireJDK="1" />
<validVersion bitness="64" maxVersion="11" minVersion="11" requireJDK="1" />
<validVersion bitness="64" maxVersion="17" minVersion="17" requireJDK="1" />
<validVersion bitness="64" maxVersion="21" minVersion="21" requireJDK="1" />
</validVersionList>
</autodetectJava>
</actionList>
<conditionRuleList>
<platformTest type="windows" />
</conditionRuleList>
<elseActionList>
<autodetectJava>
<abortOnError>0</abortOnError>
<customErrorMessage>The installer could not find a valid Java(tm) through standard installation paths or environment variables on this machine. Required JDK versions: 1.8 64-Bit JDK or 11 64-Bit JDK. Please click OK and browse a valid java executable file to continue.</customErrorMessage>
<promptUser>1</promptUser>
<validVersionList>
<validVersion bitness="64" maxVersion="1.8" minVersion="1.8" requireJDK="1" />
<validVersion bitness="64" maxVersion="11" minVersion="11" requireJDK="1" />
<validVersion bitness="64" maxVersion="17" minVersion="17" requireJDK="1" />
<validVersion bitness="64" maxVersion="21" minVersion="21" requireJDK="1" />
</validVersionList>
</autodetectJava>
</elseActionList>
</if>
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,6 @@
</componentList>
<preInstallationActionList>
<include file="../components/autodetect-java.xml" />
<include file="../components/autodetect-java-windows.xml" />
</preInstallationActionList>
<postInstallationActionList>
<actionGroup explanation="Install the main program">
Expand Down
3 changes: 0 additions & 3 deletions build/installers/liferay-workspace/liferay-workspace.xml
Original file line number Diff line number Diff line change
Expand Up @@ -56,9 +56,6 @@
<include>
<file>../components/autodetect-java.xml</file>
</include>
<include>
<file>../components/autodetect-java-windows.xml</file>
</include>
</preInstallationActionList>
<postInstallationActionList>
<createDirectory>
Expand Down

0 comments on commit b417509

Please sign in to comment.