blob: 6015206c77f2a5529bfc254353df88265b6803b3 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
|
# Maintainer: PersonWhoExists <Landon.kuehner@proton.me>
# Maintainer: LordDemecrius83 <lorddemecrius83@proton.me>
# Maintainer: Kaizhao Zhang <zhangkaizhao@gmail.com>
pkgname=kotlin-native-bin
pkgver=2.0.20
pkgrel=1
pkgdesc="An LLVM based backend for the Kotlin compiler and native implementation of the Kotlin standard library"
arch=('x86_64')
url="https://kotlinlang.org/"
license=('Apache')
options=('staticlibs' 'libtool' '!strip')
# 1. For 'java-environment>=8':
# https://kotlinlang.org/docs/native-command-line-compiler.html
# > While the output of the compiler does not have any dependencies or virtual
# > machine requirements, the compiler itself requires
# > [Java 1.8 or higher runtime](https://jdk.java.net/11/).
depends=('java-environment>=8')
optdepends=(
'lldb: for konan-lldb'
)
provides=('kotlin-native')
conflicts=('kotlin-native' 'kotlin-native-git')
source=(
"https://github.com/JetBrains/kotlin/releases/download/v${pkgver}/kotlin-native-prebuilt-linux-x86_64-${pkgver}.tar.gz"
)
sha256sums=(
'52a5445377880b638a0e94691b266766c333b58224d085fbb02768fe2395eda5'
)
package() {
install -d "${pkgdir}/usr/bin"
install -d "${pkgdir}/usr/lib"
cp -r "kotlin-native-prebuilt-linux-x86_64-${pkgver}" "${pkgdir}/usr/lib/kotlin-native"
# Fix permissions for some files, e.g. /usr/lib/kotlin-native/klib/common/stdlib/ir/ir_tables/*.knt
chmod -R +r "${pkgdir}/usr/lib/kotlin-native"
# Fix per user cache not working
mkdir -p "${pkgdir}/usr/lib/kotlin-native/klib/cache/linux_x64STATIC-pl"
ln -s /usr/lib/kotlin-native/bin/kotlinc-native "${pkgdir}/usr/bin/kotlinc-native"
ln -s /usr/lib/kotlin-native/bin/konanc "${pkgdir}/usr/bin/konanc"
ln -s /usr/lib/kotlin-native/bin/konan-lldb "${pkgdir}/usr/bin/konan-lldb"
ln -s /usr/lib/kotlin-native/bin/klib "${pkgdir}/usr/bin/klib"
ln -s /usr/lib/kotlin-native/bin/cinterop "${pkgdir}/usr/bin/cinterop"
ln -s /usr/lib/kotlin-native/bin/jsinterop "${pkgdir}/usr/bin/jsinterop"
ln -s /usr/lib/kotlin-native/bin/run_konan "${pkgdir}/usr/bin/run_konan"
ln -s /usr/lib/kotlin-native/bin/generate-platform "${pkgdir}/usr/bin/generate-platform"
}
|