summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: a12912e69d663e62ac69dbb9d0c8058d20999b90 (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
# Maintainer: Julien Virey <julien.virey+aur@gmail.com>
# Contributor: Jakub SzymaƄski <jakubmateusz@poczta.onet.pl>

pkgname=woeusb-ng
pkgver=0.2.12
pkgrel=4
pkgdesc="Simple tool that enable you to create your own usb stick with Windows installer."
arch=('any')
url="https://github.com/WoeUSB/WoeUSB-ng"
license=('GPL-3.0-only')
depends=(
  'parted'
  'dosfstools'
  'ntfsprogs'
  'grub'
  'p7zip'
  'python'
  'python-pip'
  'python-wxpython'
  'xdg-utils'
  'python-termcolor'
)

makedepends=(
  'python-build'
  'python-installer'
  'python-wheel'
  'python-setuptools'
)

provides=('woeusb')

conflicts=(
  'woeusb'
  'woeusb-git'
)

source=(
  "$pkgname-$pkgver.tar.gz::https://github.com/WoeUSB/WoeUSB-ng/archive/v$pkgver.tar.gz"
  pr79.patch
  pr134.patch
)

sha256sums=('64b9346490e88c627f0034973771620474acb9482bb6a5045c27e52d23987779'
  '848e56d1b377a46bba6f8c400f7b7aea18aba263f6c795158e219fbad9c87ed6'
  'aab89f72abf4965fe54d063e613fd42f733e280e773b408fc18a467c1da0d163')

prepare() {
  cd WoeUSB-ng-$pkgver
  patch --forward --strip=1 --input="${srcdir}/pr79.patch"
  patch --forward --strip=1 --input="${srcdir}/pr134.patch"
}

build() {
  cd WoeUSB-ng-$pkgver
  python -m build --wheel --no-isolation
}

package() {
  cd WoeUSB-ng-$pkgver
  python -m installer --destdir="$pkgdir" dist/*.whl
  # shortcut
  cp miscellaneous/WoeUSB-ng.desktop $pkgdir/usr/share/applications/WoeUSB-ng.desktop
  chmod 755 $pkgdir/usr/share/applications/WoeUSB-ng.desktop

  # policy
  cp miscellaneous/com.github.woeusb.woeusb-ng.policy $pkgdir/usr/share/polkit-1/actions/com.github.woeusb.woeusb-ng.policy
}