summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 3cd2b051309cf49ed69ba72056c1465385116096 (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
# Maintainer: jtmb <packaging at technologicalwizardry dot com>
_pkgname=pkhex
pkgname=${_pkgname}-git
pkgver=r5246.7a021781
pkgrel=1
pkgdesc="Pokémon core series save editor, programmed in C#."
arch=(any)
url="https://github.com/kwsch/PKHeX"
license=('GPL')
depends=(mono)
makedepends=(git msbuild-stable)
provides=(pkhex)
conflicts=(pkhex)
options=('!strip')
source=("${pkgname}::git+https://github.com/kwsch/PKHeX#branch=master"
		"PKHeX.sh"
		"pkhex.desktop"
		"pkhex.png")
md5sums=('SKIP'
         '8bd71d319e130750a39f15d56b5636e1'
         'bb570ade3acf94f25d43cfa69db17c2f'
         'ceb97fc5efcf4548ca4572b5116f5875')


pkgver() {
  cd ${pkgname}
  printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
}

build() {
  cd "$pkgname"

  msbuild PKHeX.sln /t:restore /t:build /p:Configuration=Mono-Release
  
}

package() {

  install -Dm644 "$_pkgname.desktop" "$pkgdir/usr/share/applications/$_pkgname.desktop"
  install -Dm644 "$_pkgname.png" "$pkgdir/usr/share/pixmaps/$_pkgname.png"
  install -Dm755 -- PKHeX.sh "$pkgdir/usr/bin/PKHeX"
  cd "$pkgname"

  install -Dm755 -- PKHeX.WinForms/bin/Mono-Release/PKHeX.exe "$pkgdir/opt/${_pkgname}/PKHeX.exe"
  install -Dm644 -- PKHeX.WinForms/bin/Mono-Release/PKHeX.exe.config "$pkgdir/opt/${_pkgname}/PKHeX.exe.config"
  install -Dm755 -- PKHeX.WinForms/bin/Mono-Release/PKHeX.Core.dll "$pkgdir/opt/${_pkgname}/PKHeX.Core.dll"
  install -Dm644 -- PKHeX.WinForms/bin/Mono-Release/PKHeX.Core.dll.config "$pkgdir/opt/${_pkgname}/PKHeX.Core.dll.config"
  mkdir -p -- "$pkgdir/opt/${_pkgname}/bak"
  mkdir -p -- "$pkgdir/opt/${_pkgname}/pkmdb"
  chmod 777 -- "$pkgdir/opt/${_pkgname}/bak"
  chmod 777 -- "$pkgdir/opt/${_pkgname}/pkmdb"
  
}