summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 85eb51ce18504af5a6ecd918e59d247a7e1417ab (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
# Maintainer: Nnisarg Gada <contact@nnisarg.in>
pkgname=cpig-git
pkgver=1.0.r14.fd38047
pkgrel=1
pkgdesc="CPIG: Color Palette Inference Generator is a simple C-based program that generates a color palette from an image file using K-means clustering."
arch=('x86_64' 'aarch64' 'armv7h')
url="https://github.com/nnisarggada/cpig"
license=('GPL3')
groups=()
depends=('gcc')
makedepends=('git' 'make')
optdepends=()
provides=('cpig')
conflicts=('cpig')
install=
changelog=
source=("git+$url")
sha256sums=('SKIP')

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

build() {
	cd "$srcdir/cpig"
	make
}

package() {
	cd "$srcdir/cpig"
	mkdir -p "$pkgdir/opt/$pkgname"
	cp -rf * "$pkgdir/opt/$pkgname"
	make DESTDIR="$pkgdir" install
	install -Dm644 LICENSE "$pkgdir/usr/share/licenses/$pkgname/LICENSE"
	install -Dm644 README.md "$pkgdir/usr/share/doc/$pkgname/README.md"
}