summarylogtreecommitdiffstats
path: root/PKGBUILD
diff options
context:
space:
mode:
Diffstat (limited to 'PKGBUILD')
-rw-r--r--PKGBUILD51
1 files changed, 24 insertions, 27 deletions
diff --git a/PKGBUILD b/PKGBUILD
index 6e46a903f16..31057998e49 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -1,43 +1,40 @@
# Maintainer: wtzb <>
pkgname=mycrypto-bin
-_pkgname=mycrypto
-pkgver=1.5.6
-pkgrel=2
+pkgbin=mycrypto
+pkgver=1.6.0
+pkgrel=1
pkgdesc='Open-source, client-side tool for generating Ether Wallets, handling ERC-20 tokens, and interacting with the blockchain more easily'
+package="linux-x86-64_${pkgver}_MyCrypto.AppImage"
arch=('x86_64')
provides=('mycrypto')
conflicts=('mycrypto')
url='https://github.com/MyCryptoHQ/MyCrypto'
license=('MIT')
-source=("${url}/releases/download/${pkgver}/linux-x86-64_${pkgver}_MyCrypto.AppImage"
+source=("${url}/releases/download/${pkgver}/${package}"
'LICENSE')
-sha256sums=('b07ab5535da05c42d251c62225115459a0ab5e1e2e6cc3003a6efbb56e5f4214'
+sha256sums=('fa624f4331ffc4f56baf90b7a78f1e502bbfc2ff88d1786607487219b1930e4a'
'1b0a4ebe6200441fe008bba2b60bb227b944cd77427b3f9c60f6f7e32120a65d')
-prepare() {
- # Extract AppImage
- chmod +x linux-x86-64_${pkgver}_MyCrypto.AppImage
- ./linux-x86-64_${pkgver}_MyCrypto.AppImage --appimage-extract &>/dev/null
- mv squashfs-root $_pkgname-$pkgver
-}
-
package() {
- cd $_pkgname-$pkgver
+ # Extract files
+ chmod +x "$srcdir/$package"
+ `$srcdir/$package --appimage-extract`
+ # Clean old build dir files
+ rm -rf $srcdir/$pkgbin
+ mv -f "$srcdir/squashfs-root" "$srcdir/$pkgbin"
+
+ # Install Icon
+ install -Dm644 "$srcdir/$pkgbin/usr/share/icons/hicolor/0x0/apps/$pkgbin.png" -t "$pkgdir/usr/share/icons/hicolor/256x256/apps/"
+
+ install -d "$pkgdir/opt/$pkgbin"
+ cp -a "$srcdir/$pkgbin/." "$pkgdir/opt/$pkgbin/"
+ chmod -R +rx "$pkgdir/opt/$pkgbin"
- # Executable
- mkdir -p "$pkgdir"/usr/share/$_pkgname
- mkdir -p "$pkgdir"/usr/bin
- mv ./app/* "$pkgdir"/usr/share/$_pkgname
- chmod 755 "$pkgdir"/usr/share/$_pkgname
- ln -s "$pkgdir"/usr/share/$_pkgname/$_pkgname "$pkgdir"/usr/bin/$_pkgname
- # Desktop entry
- sed -i s/AppRun/$_pkgname/ mycrypto.desktop
- install -Dm644 mycrypto.desktop -t "$pkgdir"/usr/share/applications/
- # Icon
- install -Dm644 usr/share/icons/hicolor/0x0/apps/mycrypto.png \
- -t "$pkgdir"/usr/share/icons/hicolor/256x256/apps/
- # License
- install -Dm644 "$srcdir"/LICENSE -t "$pkgdir"/usr/share/licenses/$_pkgname/
+ install -d "$pkgdir/usr/bin"
+ ln -s "/opt/$pkgbin/app/$pkgbin" "$pkgdir/usr/bin/$pkgbin"
+ # Provided .desktop file tries to run "AppRun" instead of mycrypto
+ sed -e "s/AppRun/$pkgbin/g" -i $srcdir/$pkgbin/$pkgbin.desktop
+ install -Dm644 "$srcdir/$pkgbin/$pkgbin.desktop" "$pkgdir/usr/share/applications/$pkgbin.desktop"
}