summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 8a0c1882fa1a84032b795d82a43da3609217e69f (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
# Package build for libnoise2d from git (https://github.com/planeworld/libnoise2d)
# Maintainer: Sven Klomp <mail at klomp dot eu>

pkgdesc='Noise library for 2D data'
_gitname=('libnoise2d')
pkgname=('libnoise2d-git')
provides=('libnoise2d')
conflicts=('libnoise2d')
pkgver=0.18.ecc6d2f
pkgrel=1
arch=('i686' 'x86_64')
license=('GPL')
url="https://github.com/planeworld/libnoise2d"
depends=('gcc-libs')
makedepends=('gcc-libs' 'git' 'cmake')
source=("git+https://github.com/planeworld/libnoise2d.git")
md5sums=('SKIP')

pkgver() {
	cd "$srcdir"/${_gitname}
	echo "0.$(git rev-list --count HEAD).$(git describe --always)"
}


prepare() {
	cd "${srcdir}/${_gitname}"
}

build() {
	cd "${srcdir}/${_gitname}"
	
	if [ ! -d "${srcdir}/build" ]; then
		mkdir -p "${srcdir}/build"
	fi

	cd "${srcdir}/build"

	cmake -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX:PATH=/usr "../${_gitname}"

	make
	
}

package() {
	cd "${srcdir}/build"
	make DESTDIR="${pkgdir}/" install	

}