From 7807ee212170e258c380246c9af1ec6edf0680d6 Mon Sep 17 00:00:00 2001 From: Issac Lin Date: Mon, 30 May 2022 17:30:21 +0800 Subject: [PATCH] kotlin-native@1.6.21-349.1: Fix installation and autoupdate fixes #3630 --- bucket/kotlin-native.json | 26 ++++++++++++++++---------- 1 file changed, 16 insertions(+), 10 deletions(-) diff --git a/bucket/kotlin-native.json b/bucket/kotlin-native.json index 788cc2034a..cb5a5745c5 100644 --- a/bucket/kotlin-native.json +++ b/bucket/kotlin-native.json @@ -1,5 +1,5 @@ { - "version": "1.6.21", + "version": "1.6.21-349.1", "description": "An LLVM backend for the Kotlin compiler, runtime implementation, and native code generation facility using the LLVM toolchain for native binaries runnable without a virtual machine.", "homepage": "https://kotlinlang.org", "license": "Apache-2.0", @@ -9,11 +9,18 @@ }, "architecture": { "64bit": { - "url": "https://github.com/JetBrains/kotlin/releases/download/v1.6.21/kotlin-native-windows-x86_64-1.6.21.zip", - "hash": "ac520bf2f66197fec1ff6c666432cb908bf49e39b9266dd6979fa6e2c0294206", - "extract_dir": "kotlin-native-windows-x86_64-1.6.21" + "url": "https://github.com/JetBrains/kotlin/releases/download/v1.6.21/kotlin-native-windows-x86_64-1.6.21-349.1.zip#/dl.zip_", + "hash": "9327eb3317ce636c0652b419836c4fffa0654c2bded71aff70c90635d4be4ab7" } }, + "pre_install": [ + "# Manually extract because archive name and directory name sometimes does not match.", + "# e.g. archive is named 'kotlin-native-windows-x86_64-1.6.21-349.1', but contains folder 'kotlin-native-windows-x86_64-1.6.21-349'", + "Expand-7zipArchive \"$dir\\dl.zip_\" \"$dir\" -Removal | Out-Null", + "$folder = Get-ChildItem \"$dir\\kotlin-native-windows-x86_64-*\" | Select -First 1 -ExpandProperty FullName", + "Move-Item \"$folder\\*\" \"$dir\\\"", + "Remove-Item \"$folder\" -Force -Recurse" + ], "bin": [ "bin\\cinterop.bat", "bin\\jsinterop.bat", @@ -25,19 +32,18 @@ ], "env_add_path": "bin", "checkver": { - "url": "https://kotlinlang.org/docs/releases.html", - "regex": ">([\\d.]+)$sha256