add LICENSE

This commit is contained in:
Noel Jacob
2024-02-06 13:44:13 +05:30
parent 4a49524f38
commit d1b8ae9d83
3 changed files with 45 additions and 6 deletions

View File

@@ -11,16 +11,28 @@ url="https://github.com/oven-sh/bun"
license=('MIT')
provides=('bun')
conflicts=('bun')
sha256sums_x86_64=('99655ef01146497289627af641765a8755d87e2af9ccde7edb04381df81d3b21')
sha256sums_aarch64=('1fe8666d97512a3963b24c0d89c2de160ba8e524d9f1f23193b147bce7a7b917')
sha256sums_x86_64=(
'99655ef01146497289627af641765a8755d87e2af9ccde7edb04381df81d3b21'
'002c2696d92b5c8cf956c11072baa58eaf9f6ade995c031ea635c6a1ee342ad1'
)
sha256sums_aarch64=(
'1fe8666d97512a3963b24c0d89c2de160ba8e524d9f1f23193b147bce7a7b917'
'002c2696d92b5c8cf956c11072baa58eaf9f6ade995c031ea635c6a1ee342ad1'
)
_baseline=''
_baseline_sha256sums='fd53f49801b6ae09377578014cad79380ea53a73ed460cd741b7e0dd03dbac9b'
if [[ $CARCH == 'x86_64' && $(cat /proc/cpuinfo | grep avx2) = '' ]];then
_baseline='-baseline'
sha256sums_x86_64=($_baseline_sha256sums)
fi
source_x86_64=("bun-x64-${pkgver}.zip::https://github.com/oven-sh/bun/releases/download/bun-v${pkgver}/bun-linux-x64${_baseline}.zip")
source_aarch64=("bun-aarch64-${pkgver}.zip::https://github.com/oven-sh/bun/releases/download/bun-v${pkgver}/bun-linux-aarch64.zip")
source_x86_64=(
"bun-x64-${pkgver}.zip::https://github.com/oven-sh/bun/releases/download/bun-v${pkgver}/bun-linux-x64${_baseline}.zip"
"LICENSE"
)
source_aarch64=(
"bun-aarch64-${pkgver}.zip::https://github.com/oven-sh/bun/releases/download/bun-v${pkgver}/bun-linux-aarch64.zip"
"LICENSE"
)
build() {
if [ "${CARCH}" == "aarch64" ]; then
cd "bun-linux-aarch64"
@@ -42,6 +54,8 @@ package() {
fi
# simlink as bunx as in the official install.sh
ln -s bun "${pkgdir}/usr/bin/bunx"
install -Dm644 "${srcdir}/LICENSE" "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
install -Dm644 completions/bun.zsh "${pkgdir}/usr/share/zsh/site-functions/_bun"
install -Dm644 completions/bun.bash "${pkgdir}/usr/share/bash-completion/completions/bun"