summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 7f1a6ec5bc8c8a8b8e65cdf68e2fddb86bdad5da (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
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
# Maintainer: Jasmin <theblazehen@gmail.com>
# Contributor: Dvd-Znf <email@dvdznf.xyz>
# Contributor: Pellegrino Prevete <pellegrinoprevete@gmail.com>
# Contributor: Truocolo <truocolo@aol.com>
# Contributor: Julian Mac Kenzie <jukiangm@gmail.com>
# Contributor: Kenneth Endfinger <kaendfinger@gmail.com>
# Contributor: Christian Hesse <mail@eworm.de>
# Contributor: Anatol Pomozov <anatol.pomozov@gmail.com>
# Contributor: Vladimir Panteleev (CyberShadow) <archlinux@cy.md>

# shellcheck disable=SC2034
_py="python"
pkgname="blivet-gui"
pkgver=2.6.0
pkgrel=3
pkgdesc='GUI tool for storage configuration'
arch=('any')
license=('GPL-2.0-or-later')
url="https://github.com/storaged-project/${pkgname}"
depends=(
  'libblockdev-btrfs'
  'libblockdev-crypto'
  'libblockdev-dm'
  'libblockdev-fs'
  'libblockdev-loop'
  'libblockdev-lvm'
  'libblockdev-mdraid'
  'libblockdev-mpath'
  'libblockdev-nvme'
  'libblockdev-part'
  'libblockdev-swap'
  "${_py}"
  "${_py}-blivet"
  "${_py}-cairo"
  "${_py}-dasbus"
  "${_py}-libblockdev"
  "${_py}-gobject"
  "${_py}-pid"
  'adwaita-icon-theme')
makedepends=(
  'gettext'
  "${_py}-setuptools")
source=(
  "${pkgname}-${pkgver}.tar.gz::${url}/archive/refs/tags/${pkgver}.tar.gz")
sha256sums=('5fba88e535012357b10f8a62bb5dd3379a981f0e9ad1c9292ae226f6d4ff0112')

build() {
  cd \
    "${pkgname}-${pkgver}" || \
    exit
  # Build .mo files directly - skip update-po which requires translation-canary
  # submodule (not in release tarball) and xgettext_werror.sh that fails on
  # embedded URL warnings in upstream code
  for po in po/*.po; do
    lang="${po%.po}"
    lang="${lang#po/}"
    msgfmt -o "po/${lang}.mo" "$po"
  done
}

# shellcheck disable=SC2154
package() {
  cd \
    "${pkgname}-${pkgver}" || \
    exit
  make \
    DESTDIR="${pkgdir}" \
    RPM_BUILD_ROOT="${pkgdir}" \
    install
}