OSDN Git Service

[add] : Added packages
[alterlinux/hayao-aur-packages.git] / 2048.c-git / PKGBUILD
1 # Maintainer: Gaetan Bisson <bisson@archlinux.org>
2 # Contributor: sekret
3
4 _pkgname=2048.c
5 pkgname=${_pkgname}-git
6 pkgver=20191210.9b387c3
7 pkgrel=1
8 pkgdesc='Console version of the game "2048" for GNU/Linux'
9 url='https://github.com/mevdschee/2048.c'
10 arch=('i686' 'x86_64' 'armv7h' 'armv6h')
11 license=('custom:MIT')
12 makedepends=('git')
13 source=("${_pkgname}::git+https://github.com/mevdschee/2048.c.git")
14 sha1sums=('SKIP')
15
16 provides=("${_pkgname}")
17 conflicts=("${_pkgname}")
18
19 pkgver() {
20         cd "${srcdir}/${_pkgname}"
21         git log -1 --format='%cd.%h' --date=short | tr -d -
22 }
23
24 build() {
25         cd "${srcdir}/${_pkgname}"
26         make
27 }
28
29 check() {
30         cd "${srcdir}/${_pkgname}"
31         ./2048 test
32 }
33
34 package() {
35         cd "${srcdir}/${_pkgname}"
36         install -Dm755 2048 "${pkgdir}/usr/bin/2048"
37         install -Dm644 LICENSE "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
38 }