changeset 22287:5cce6c398d70

re-introduced partOfHotSpot to JarJDKDeployedDist to fix mx_jvmci_makefile.py
author Doug Simon <doug.simon@oracle.com>
date Thu, 23 Jul 2015 15:21:13 +0200
parents 2ecfec90e51e
children 240347540e30
files mx.jvmci/mx_jvmci.py mx.jvmci/mx_jvmci_makefile.py
diffstat 2 files changed, 21 insertions(+), 6 deletions(-) [+]
line wrap: on
line diff
--- a/mx.jvmci/mx_jvmci.py	Thu Jul 23 13:06:35 2015 +0200
+++ b/mx.jvmci/mx_jvmci.py	Thu Jul 23 15:21:13 2015 +0200
@@ -93,6 +93,10 @@
         mx.nyi('deploy', self)
 
 class JarJDKDeployedDist(JDKDeployedDist):
+    def __init__(self, name, partOfHotSpot=False):
+        JDKDeployedDist.__init__(self, name)
+        self.partOfHotSpot = partOfHotSpot
+
     def targetDir(self):
         mx.nyi('targetDir', self)
 
@@ -108,14 +112,23 @@
         self._copyToJdk(jdkDir, self.targetDir())
 
 class ExtJDKDeployedDist(JarJDKDeployedDist):
+    def __init__(self, name, partOfHotSpot=False):
+        JarJDKDeployedDist.__init__(self, name, partOfHotSpot)
+
     def targetDir(self):
         return join('jre', 'lib', 'ext')
 
 class LibJDKDeployedDist(JarJDKDeployedDist):
+    def __init__(self, name, partOfHotSpot=False):
+        JarJDKDeployedDist.__init__(self, name, partOfHotSpot)
+
     def targetDir(self):
         return join('jre', 'lib')
 
 class JvmciJDKDeployedDist(JarJDKDeployedDist):
+    def __init__(self, name, partOfHotSpot=False):
+        JarJDKDeployedDist.__init__(self, name, partOfHotSpot)
+
     def targetDir(self):
         return join('jre', 'lib', 'jvmci')
 
@@ -155,9 +168,9 @@
 List of distributions that are deployed into a JDK by mx.
 """
 jdkDeployedDists = [
-    LibJDKDeployedDist('JVMCI_SERVICE'),
-    JvmciJDKDeployedDist('JVMCI_API'),
-    JvmciJDKDeployedDist('JVMCI_HOTSPOT'),
+    LibJDKDeployedDist('JVMCI_SERVICE', partOfHotSpot=True),
+    JvmciJDKDeployedDist('JVMCI_API', partOfHotSpot=True),
+    JvmciJDKDeployedDist('JVMCI_HOTSPOT', partOfHotSpot=True),
     HotSpotVMJDKDeployedDist('JVM_<vmbuild>_<vm>'),
 ]
 
--- a/mx.jvmci/mx_jvmci_makefile.py	Thu Jul 23 13:06:35 2015 +0200
+++ b/mx.jvmci/mx_jvmci_makefile.py	Thu Jul 23 15:21:13 2015 +0200
@@ -53,7 +53,9 @@
     opts = parser.parse_args(args)
 
     if not opts.selectedDists:
-        opts.selectedDists = [d.name for d in mx_jvmci.jdkDeployedDists if d.partOfHotSpot]
+        opts.selectedDists = [d.dist() for d in mx_jvmci.jdkDeployedDists if isinstance(d, mx_jvmci.JarJDKDeployedDist) and d.partOfHotSpot]
+    else:
+        opts.selectedDists = [mx.distribution(name) for name in opts.selectedDists]
     mf = Makefile()
     if do_build_makefile(mf, opts.selectedDists):
         contents = mf.generate()
@@ -65,7 +67,7 @@
     return 0
 
 def get_jdk_deployed_dists():
-    return [d.name for d in mx_jvmci.jdkDeployedDists]
+    return [d.dist() for d in mx_jvmci.jdkDeployedDists]
 
 def make_dist_rule(dist, mf):
     def path_dist_relative(p):
@@ -102,7 +104,7 @@
         apPaths.append(path_dist_relative(apd.path))
         apDistNames.append(apd.name)
         apDistVariableNames.append("$(" + apd.name + "_JAR)")
-    shouldExport = dist.name in jdkDeployedDists
+    shouldExport = dist in jdkDeployedDists
     props = {
            "name": dist.name,
            "jarName": targetPathPrefix + jarName,