Mercurial > hg > graal-jvmci-8
comparison mx/commands.py @ 8885:4877c7dfe6d6
Fix jdk creation check if db an man exist in source jdk not in the one we are creating
author | Gilles Duboscq <duboscq@ssw.jku.at> |
---|---|
date | Sun, 07 Apr 2013 13:26:16 +0200 |
parents | 51a8368d0231 |
children | 34d13df4165b |
comparison
equal
deleted
inserted
replaced
8884:51a8368d0231 | 8885:4877c7dfe6d6 |
---|---|
294 def _jdk(build='product', vmToCheck=None, create=False): | 294 def _jdk(build='product', vmToCheck=None, create=False): |
295 """ | 295 """ |
296 Get the JDK into which Graal is installed, creating it first if necessary. | 296 Get the JDK into which Graal is installed, creating it first if necessary. |
297 """ | 297 """ |
298 jdk = join(_graal_home, 'jdk' + str(mx.java().version), build) | 298 jdk = join(_graal_home, 'jdk' + str(mx.java().version), build) |
299 srcJdk = mx.java().jdk | |
299 jdkContents = ['bin', 'include', 'jre', 'lib'] | 300 jdkContents = ['bin', 'include', 'jre', 'lib'] |
300 if exists(join(jdk, 'db')): | 301 if exists(join(srcJdk, 'db')): |
301 jdkContents.append('db') | 302 jdkContents.append('db') |
302 if mx.get_os() != 'windows' and exists(join(jdk, 'man')): | 303 if mx.get_os() != 'windows' and exists(join(srcJdk, 'man')): |
303 jdkContents.append('man') | 304 jdkContents.append('man') |
304 if create: | 305 if create: |
305 if not exists(jdk): | 306 if not exists(jdk): |
306 srcJdk = mx.java().jdk | |
307 mx.log('Creating ' + jdk + ' from ' + srcJdk) | 307 mx.log('Creating ' + jdk + ' from ' + srcJdk) |
308 os.makedirs(jdk) | 308 os.makedirs(jdk) |
309 for d in jdkContents: | 309 for d in jdkContents: |
310 src = join(srcJdk, d) | 310 src = join(srcJdk, d) |
311 dst = join(jdk, d) | 311 dst = join(jdk, d) |