diff options
author | Serge K | 2023-05-10 17:33:07 +0700 |
---|---|---|
committer | Serge K | 2023-05-10 17:33:07 +0700 |
commit | 46c495b0cc4717bef17b30cfd1b0d042a8c60dc5 (patch) | |
tree | 951e4d87b34a67fb7c70370a5adf1eccb6ccf4a2 /PKGBUILD | |
parent | 1a2ec0b382c13237a465210266bf709dcabf35e4 (diff) | |
download | aur-46c495b0cc4717bef17b30cfd1b0d042a8c60dc5.tar.gz |
feat(ledger-live-git): use proto toolchain manager
Diffstat (limited to 'PKGBUILD')
-rw-r--r-- | PKGBUILD | 41 |
1 files changed, 14 insertions, 27 deletions
@@ -5,15 +5,15 @@ _pkgbin=ledger-live-desktop _pkgname=ledger-live -pkgname=${_pkgname}-git +pkgname="${_pkgname}-git" pkgdesc="Ledger Live - Desktop (git-main)" -pkgver=2.57.0.r0.g76dda1b +pkgver=2.58.0.r0.ga1089ae pkgrel=1 arch=('x86_64') url='https://github.com/LedgerHQ/ledger-live' license=('MIT') depends=('ledger-udev' 'electron23') -makedepends=('git' 'python>=3.5' 'node-gyp' 'fnm' 'pnpm') +makedepends=('git' 'node-gyp' 'proto') provides=("${_pkgname}") conflicts=("${_pkgname}") source=("${pkgname}::git+${url}#branch=main" @@ -21,27 +21,16 @@ source=("${pkgname}::git+${url}#branch=main" sha512sums=('SKIP' '15f6703121d1f2df2dab494efd645ef27830b5cff41184483c75a21545d79b183ababb47bebc8571c7f77e562497efc2453c3e41b59e40ad03be2baacf20148e') -_fnm_use() { - export FNM_DIR="${srcdir}/.fnm" - eval "$(fnm env --shell bash)" - fnm use --install-if-missing -} - -_check_nodejs() { - exp_ver=$(cat .nvmrc) - use_ver=$(node -v) - if [[ "${exp_ver}" != "${use_ver}" ]] - then - echo "Using the wrong version of NodeJS! Expected [${exp_ver}] but using [${use_ver}]." - exit 1 - fi +_proto_use() { + export PROTO_ROOT="${srcdir}/.proto" + export PATH="${PROTO_ROOT}/bin:${PATH}" + proto use } build() { cd "${pkgname}" - _fnm_use - _check_nodejs + _proto_use pnpm i --filter="ledger-live-desktop..." --filter="ledger-live" --frozen-lockfile --unsafe-perm pnpm build:lld @@ -52,21 +41,19 @@ build() { } package() { - install -Dm755 "${_pkgbin}.sh" "${pkgdir}/usr/bin/${_pkgbin}" + install -Dm 755 "${_pkgbin}.sh" "${pkgdir}/usr/bin/${_pkgbin}" cd "${pkgname}/apps/${_pkgbin}" - install -Dm644 "dist/__appImage-x64/${_pkgbin}.desktop" "${pkgdir}/usr/share/applications/${_pkgbin}.desktop" - - install -dm755 "${pkgdir}/usr/lib/${_pkgbin}" - cp -r "dist/linux-unpacked/resources/app.asar" "${pkgdir}/usr/lib/${_pkgbin}" + install -Dm 644 "dist/__appImage-x64/${_pkgbin}.desktop" "${pkgdir}/usr/share/applications/${_pkgbin}.desktop" + install -Dm 755 "dist/linux-unpacked/resources/app.asar" -t "${pkgdir}/usr/lib/${_pkgbin}" - install -Dm644 "build/icons/icon.png" "${pkgdir}/usr/share/icons/hicolor/64x64/apps/${_pkgbin}.png" + install -Dm 644 "build/icons/icon.png" "${pkgdir}/usr/share/icons/hicolor/64x64/apps/${_pkgbin}.png" for i in 128 256 512 1024; do - install -Dm644 "build/icons/icon@${i}x${i}.png" "${pkgdir}/usr/share/icons/hicolor/${i}x${i}/apps/${_pkgbin}.png" + install -Dm 644 "build/icons/icon@${i}x${i}.png" "${pkgdir}/usr/share/icons/hicolor/${i}x${i}/apps/${_pkgbin}.png" done - install -Dm644 LICENSE "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE" + install -Dm 644 "LICENSE" "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE" } pkgver() { |