diff options
Diffstat (limited to 'share/qbs/modules')
-rw-r--r-- | share/qbs/modules/Android/sdk/sdk.qbs | 4 | ||||
-rw-r--r-- | share/qbs/modules/Android/sdk/utils.js | 17 |
2 files changed, 18 insertions, 3 deletions
diff --git a/share/qbs/modules/Android/sdk/sdk.qbs b/share/qbs/modules/Android/sdk/sdk.qbs index b284c1f8f..c52b54664 100644 --- a/share/qbs/modules/Android/sdk/sdk.qbs +++ b/share/qbs/modules/Android/sdk/sdk.qbs @@ -55,7 +55,9 @@ Module { platformSearchPaths: [Android.sdk.sdkDir] names: ["bundletool-all"] nameSuffixes: ["-0.11.0.jar", "-0.12.0.jar", "-0.13.0.jar", "-0.13.3.jar", "-0.13.4.jar", - "-0.14.0.jar", "-0.15.0.jar", "-1.0.0.jar", "-1.1.0.jar", "-1.2.0.jar", "-1.3.0.jar"] + "-0.14.0.jar", "-0.15.0.jar", "-1.0.0.jar", "-1.1.0.jar", "-1.2.0.jar", "-1.3.0.jar", + "-1.4.0.jar", "-1.5.0.jar", "-1.6.0.jar", "-1.6.1.jar", "-1.7.0.jar", "-1.7.1.jar", + "-1.8.0.jar"] } property path sdkDir: sdkProbe.path diff --git a/share/qbs/modules/Android/sdk/utils.js b/share/qbs/modules/Android/sdk/utils.js index 36a88ddbb..d217d113b 100644 --- a/share/qbs/modules/Android/sdk/utils.js +++ b/share/qbs/modules/Android/sdk/utils.js @@ -389,12 +389,25 @@ function prepareBundletoolPackage(project, product, inputs, outputs, input, outp } cmds.push(removeCmd); + var bundleConfigFilePath = FileInfo.joinPaths(product.buildDirectory, "BundleConfig.json"); + var createBundleConfigCmd = new JavaScriptCommand(); + createBundleConfigCmd.description = "create BundleConfig.json"; + createBundleConfigCmd.filePath = bundleConfigFilePath; + createBundleConfigCmd.sourceCode = function() { + var bc = new TextFile(filePath, TextFile.WriteOnly); + bc.writeLine('{"optimizations": {'); + bc.writeLine('"uncompress_native_libraries": {'); + bc.writeLine('"enabled": false'); + bc.writeLine('}}}'); + } + cmds.push(createBundleConfigCmd); + var args = ["-jar", product.Android.sdk.bundletoolFilePath, "build-bundle"]; args.push("--modules=" + baseFilePath); args.push("--output=" + aabFilePath); + args.push("--config=" + bundleConfigFilePath); var cmd = new Command(product.java.interpreterFilePath, args); - var aabFileName = outputs["android.package_unsigned"][0].fileName; - cmd.description = "generating " + aabFileName; + cmd.description = "generating " + aabFilePath.fileName; cmds.push(cmd); return cmds; |