diff options
author | Jake Petroules <jake.petroules@petroules.com> | 2015-06-24 02:38:44 -0700 |
---|---|---|
committer | Jake Petroules <jake.petroules@petroules.com> | 2015-06-25 04:12:03 +0000 |
commit | 69eaf2d6fd1c6ded5b2483f8903f4d6512c1d93d (patch) | |
tree | 79b859b13931960cc3b310ee160c1e8dc6aa3d82 | |
parent | 28400aa9601e01e07010ec70e919a4b65b459321 (diff) | |
download | qbs-69eaf2d6fd1c6ded5b2483f8903f4d6512c1d93d.tar.gz |
Make java.jdkPath actually refer to what the name suggests.
The JDK path (i.e. $JAVA_HOME) should be the base path of the JDK,
rather than the bin directory within it. The JDK has a well-defined
layout, which allows meaningful path concatenations to be performed in
order to locate resources within it.
Change-Id: I8274e975322cda6bc2b3e3143ae6c80963f368b5
Reviewed-by: Christian Kandeler <christian.kandeler@theqtcompany.com>
-rw-r--r-- | share/qbs/modules/java/JavaModule.qbs | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/share/qbs/modules/java/JavaModule.qbs b/share/qbs/modules/java/JavaModule.qbs index e911597a2..95057583c 100644 --- a/share/qbs/modules/java/JavaModule.qbs +++ b/share/qbs/modules/java/JavaModule.qbs @@ -40,12 +40,12 @@ Module { property stringList additionalCompilerFlags property stringList additionalJarFlags property stringList bootClassPaths - property string compilerFilePath: FileInfo.joinPaths(jdkPath, compilerName) + property string compilerFilePath: FileInfo.joinPaths(jdkPath, "bin", compilerName) property string compilerName: "javac" property bool enableWarnings: true - property string interpreterFilePath : FileInfo.joinPaths(jdkPath, interpreterName) + property string interpreterFilePath : FileInfo.joinPaths(jdkPath, "bin", interpreterName) property string interpreterName: "java" - property string jarFilePath: FileInfo.joinPaths(jdkPath, jarName) + property string jarFilePath: FileInfo.joinPaths(jdkPath, "bin", jarName) property string jarName: "jar" property path jdkPath @@ -89,6 +89,7 @@ Module { validate: { var validator = new ModUtils.PropertyValidator("java"); + validator.setRequiredProperty("jdkPath", jdkPath); validator.setRequiredProperty("compilerVersion", compilerVersion); validator.setRequiredProperty("compilerVersionParts", compilerVersionParts); validator.setRequiredProperty("compilerVersionMajor", compilerVersionMajor); |