diff options
author | AkiraFukushima | 2021-09-06 01:44:34 +0900 |
---|---|---|
committer | AkiraFukushima | 2021-09-06 01:44:34 +0900 |
commit | bc0b3fded001decef6813e80f3e213e87f19d3a0 (patch) | |
tree | 4542c69d3f46df70ae8cccd90e11c9f577120649 /PKGBUILD | |
parent | 50dba6af23c6c6e693db9768e4f63b4adb1d0ae6 (diff) | |
download | aur-bc0b3fded001decef6813e80f3e213e87f19d3a0.tar.gz |
Build whalebird from source code
Diffstat (limited to 'PKGBUILD')
-rw-r--r-- | PKGBUILD | 38 |
1 files changed, 31 insertions, 7 deletions
@@ -6,18 +6,42 @@ pkgdesc="An Electron based Mastodon, Pleroma and Misskey client" arch=('x86_64') url="https://whalebird.social" license=('MIT') -depends=('c-ares' 'ffmpeg' 'gtk3' 'http-parser' 'libevent' 'libxslt' 'libxss' 'minizip' 'nss' 'snappy' 're2' 'libnotify' 'libvpx') -makedepends=('tar') +depends=('c-ares' 'ffmpeg' 'gtk3' 'libevent' 'libnghttp2' 'libxslt' 'minizip' + 'nss' 're2' 'snappy' 'libnotify') +makedepends=('yarn' 'tar' 'nodejs>=14.15') provides=('whalebird') -source=("https://github.com/h3poteto/whalebird-desktop/releases/download/$pkgver/Whalebird-$pkgver-linux-x64.tar.bz2" - whalebird.desktop) -md5sums=('8d44fd675876e684cc9de09474289060' - '2cf7ef689d208d2fa41ce3622dce3545') +source=("https://github.com/h3poteto/whalebird-desktop/archive/refs/tags/$pkgver.tar.gz" + whalebird.desktop + electron-builder.yml) +md5sums=('d30be4e5073b82e70eb8151fe90ecf97' + '2cf7ef689d208d2fa41ce3622dce3545' + '68af72623ba3763c9a1ea440b72a253d') + +prepare() { + cd "whalebird-desktop-${pkgver}" + rm -f electron-builder.json +} + +build() { + cd "whalebird-desktop-${pkgver}" + make build + yarn exec electron-builder --linux --dir --config electron-builder.yml + +} package() { mkdir -p "${pkgdir}/usr/bin" mkdir -p "${pkgdir}/usr/share" - mv "Whalebird-${pkgver}-linux-x64" "${pkgdir}/usr/share/${pkgname}" + mv "whalebird-desktop-${pkgver}/build/linux-unpacked" "${pkgdir}/usr/share/${pkgname}" ln -sf "/usr/share/${pkgname}/whalebird" "${pkgdir}/usr/bin/whalebird" + + for i in 16 32 128 256 512; do + install -Dm 644 "whalebird-desktop-${pkgver}/build/icons/icon.iconset/icon_${i}x${i}.png" \ + "${pkgdir}/usr/share/icons/hicolor/${i}x${i}/apps/whalebird.png" + done + install -Dm 644 "whalebird-desktop-${pkgver}/build/icons/icon.iconset/icon_32x32@2x.png" \ + "${pkgdir}/usr/share/icons/hicolor/64x64/apps/whalebird.png" + install -Dm644 -t "${pkgdir}/usr/share/applications" whalebird.desktop + install -Dm 644 "whalebird-desktop-${pkgver}/LICENSE.txt" -t "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE" } |