Mercurial > hg > graal-jvmci-8
comparison mxtool/mx.py @ 20102:6e5df2d60fbd
mx: fix compliance check for EXTRA_JAVA_HOMES, add maximum JAVA_HOME version in mx_graal
author | Gilles Duboscq <gilles.m.duboscq@oracle.com> |
---|---|
date | Tue, 31 Mar 2015 14:35:17 +0200 |
parents | ea280aa54d58 |
children | 02a9b5d77964 |
comparison
equal
deleted
inserted
replaced
20101:178814b064a7 | 20102:6e5df2d60fbd |
---|---|
1658 base = '/Library/Java/JavaVirtualMachines' | 1658 base = '/Library/Java/JavaVirtualMachines' |
1659 candidateJdks = [join(base, n, 'Contents/Home') for n in os.listdir(base) if exists(join(base, n, 'Contents/Home'))] | 1659 candidateJdks = [join(base, n, 'Contents/Home') for n in os.listdir(base) if exists(join(base, n, 'Contents/Home'))] |
1660 elif get_os() == 'linux': | 1660 elif get_os() == 'linux': |
1661 base = '/usr/lib/jvm' | 1661 base = '/usr/lib/jvm' |
1662 candidateJdks = [join(base, n) for n in os.listdir(base) if exists(join(base, n, 'jre/lib/rt.jar'))] | 1662 candidateJdks = [join(base, n) for n in os.listdir(base) if exists(join(base, n, 'jre/lib/rt.jar'))] |
1663 base = '/usr/java' | |
1664 candidateJdks += [join(base, n) for n in os.listdir(base) if exists(join(base, n, 'jre/lib/rt.jar'))] | |
1663 elif get_os() == 'solaris': | 1665 elif get_os() == 'solaris': |
1664 base = '/usr/jdk/instances' | 1666 base = '/usr/jdk/instances' |
1665 candidateJdks = [join(base, n) for n in os.listdir(base) if exists(join(base, n, 'jre/lib/rt.jar'))] | 1667 candidateJdks = [join(base, n) for n in os.listdir(base) if exists(join(base, n, 'jre/lib/rt.jar'))] |
1666 elif get_os() == 'windows': | 1668 elif get_os() == 'windows': |
1667 base = r'C:\Program Files\Java' | 1669 base = r'C:\Program Files\Java' |
5329 defaultJdk = JavaConfig(opts.java_home, opts.java_dbg_port) | 5331 defaultJdk = JavaConfig(opts.java_home, opts.java_dbg_port) |
5330 _java_homes = [defaultJdk] | 5332 _java_homes = [defaultJdk] |
5331 if opts.extra_java_homes: | 5333 if opts.extra_java_homes: |
5332 for java_home in opts.extra_java_homes.split(os.pathsep): | 5334 for java_home in opts.extra_java_homes.split(os.pathsep): |
5333 extraJdk = JavaConfig(java_home, opts.java_dbg_port) | 5335 extraJdk = JavaConfig(java_home, opts.java_dbg_port) |
5334 if extraJdk > defaultJdk: | 5336 if extraJdk.javaCompliance > defaultJdk.javaCompliance: |
5335 abort('Secondary JDK ' + extraJdk.jdk + ' has higher compliance level than default JDK ' + defaultJdk.jdk) | 5337 abort('Secondary JDK ' + extraJdk.jdk + ' has higher compliance level than default JDK ' + defaultJdk.jdk) |
5336 _java_homes.append(extraJdk) | 5338 _java_homes.append(extraJdk) |
5337 | 5339 |
5338 for s in suites(): | 5340 for s in suites(): |
5339 s._post_init(opts) | 5341 s._post_init(opts) |