Alon Bar-Lev has posted comments on this change.

Change subject: packaging: Find and check JVM during setup (#834436)
......................................................................


Patch Set 3: (3 inline comments)

....................................................
File packaging/fedora/setup/engine-setup.py
Line 1913:         logging.debug("The java version \"%s\" is not supported." % 
javaVersion)
Line 1914:         return False
Line 1915: 
Line 1916:     # Check that it is an OpenJDK:
Line 1917:     match = re.search(r'^OpenJDK .*$', str(javaErr), re.MULTILINE)
We can warn... but at this stage it is not that important...
Line 1918:     if not match:
Line 1919:         logging.debug("The Java launcher \"%s\" is not OpenJDK." % 
javaLauncher)
Line 1920:         return False
Line 1921: 


Line 1921: 
Line 1922:     # It passed all the checks, so it is valid JVM:
Line 1923:     return True
Line 1924: 
Line 1925: def checkJdk(jvmPath):
But JDK cannot be installed without JRE... or I miss something...

JAVA_HOME/bin/java should exist even if jdk is installed.
Line 1926:     # We assume that this JVM path has already been checked and that 
it
Line 1927:     # contains a valid JVM, so we only need to check that it also
Line 1928:     # contains a Java compiler:
Line 1929:     javaCompiler = os.path.join(jvmPath, "bin", "javac")


Line 1949:                     targetPath = targetName
Line 1950:                 else:
Line 1951:                     targetPath = os.path.join(javaDir, targetName)
Line 1952:                 if not os.path.islink(targetPath):
Line 1953:                     jvmLinks.append(filePath)
ACK :(
Line 1954: 
Line 1955:     # For each possible JVM path check that it really contain a JVM 
and
Line 1956:     # that the version is supported:
Line 1957:     jvmLinks = [x for x in jvmLinks if checkJvm(x)]


--
To view, visit http://gerrit.ovirt.org/7549
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: Ib279ea8111825ec35a25f9ba6ee37b481ed4354f
Gerrit-PatchSet: 3
Gerrit-Project: ovirt-engine
Gerrit-Branch: master
Gerrit-Owner: Juan Hernandez <[email protected]>
Gerrit-Reviewer: Alex Lourie <[email protected]>
Gerrit-Reviewer: Alon Bar-Lev <[email protected]>
Gerrit-Reviewer: Juan Hernandez <[email protected]>
Gerrit-Reviewer: Moran Goldboim <[email protected]>
Gerrit-Reviewer: oVirt Jenkins CI Server
_______________________________________________
Engine-patches mailing list
[email protected]
http://lists.ovirt.org/mailman/listinfo/engine-patches

Reply via email to